You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I really appreciate the recently added functionality to save a catalog to a target location. I was hoping to use this for the case of a static RELATIVE_PUBLISHED catalog in a github repository, but working on it locally via git clone (but not a full catalog copy as described here #137). To-date, for new catalogs I've accomplished this by 1. writing a version locally, 2. manually changing the self link in the catalog, 3. then publishing by pushing to github.
In pystac=1.1 using catalog.save(pystac.CatalogType.RELATIVE_PUBLISHED, dest_href=local_dir) from #565. cc @duckontheweb@volaya
I've noticed two oddities. 1. subcatalogs or collections get a subfolder for example .collection.json/ which seems a bit odd.
This indeed looks like a bug based on the PySTAC documentation you linked to and the STAC Spec Best Practices regarding Self-contained Catalogs. The root of the problem seems to be a hard-coded include_self_link=True in Catalog.savehere. I'll do a little digging on why that value was hard-coded and see if I can come up with a fix.
I really appreciate the recently added functionality to save a catalog to a target location. I was hoping to use this for the case of a static RELATIVE_PUBLISHED catalog in a github repository, but working on it locally via git clone (but not a full catalog copy as described here #137). To-date, for new catalogs I've accomplished this by 1. writing a version locally, 2. manually changing the self link in the catalog, 3. then publishing by pushing to github.
In pystac=1.1 using catalog.save(pystac.CatalogType.RELATIVE_PUBLISHED, dest_href=local_dir) from #565. cc @duckontheweb @volaya
I've noticed two oddities. 1. subcatalogs or collections get a subfolder for example
.collection.json/
which seems a bit odd.And 2. it seems that items are written with a
self
link, which i believe is unnecessary according to https://pystac.readthedocs.io/en/latest/concepts.html#relative-published-catalogs.A reproducible example is below modified from #90
The text was updated successfully, but these errors were encountered: