-
Notifications
You must be signed in to change notification settings - Fork 127
Closed
Labels
bugThings which are brokenThings which are broken
Milestone
Description
When doing catalog.save(), referenced external catalogs are pulled in and are saved next to the save location with a weird path.
Consider the following example catalog.json referencing an external collection:
{
"id": "test",
"type": "Catalog",
"stac_extensions": [],
"stac_version": "1.0.0",
"description": "test",
"title": "test",
"links": [
{
"rel": "child",
"href": "https://raw.githubusercontent.com/radiantearth/stac-spec/v1.0.0/examples/collection.json",
"type": "application/json"
}
]
}Now consider the following usage in Python:
>>> catalog = pystac.read_file("catalog.json")
>>> list(catalog.get_children())
[<Collection id=simple-collection>]
>>> catalog.save(pystac.CatalogType.SELF_CONTAINED, dest_href="out/catalog.json")Now the directory contents are similar to as following tree:
.
├── https:
│ └── raw.githubusercontent.com
│ └── radiantearth
│ └── stac-spec
│ └── v1.0.0
│ └── collection.json
├── out
│ └── catalog.json
└── test.json
gadomski
Metadata
Metadata
Assignees
Labels
bugThings which are brokenThings which are broken