-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
STAC 1.0.0-beta.1 support #116
Conversation
@@ -13,10 +13,10 @@ object AssetCollectionExtension { | |||
|
|||
implicit val encAssetCollectionExtension: Encoder.AsObject[AssetCollectionExtension] = Encoder | |||
.AsObject[Map[String, Json]] | |||
.contramapObject((extensionFields: AssetCollectionExtension) => Map("assets" -> extensionFields.assets.asJson)) | |||
.contramapObject((extensionFields: AssetCollectionExtension) => Map("item_assets" -> extensionFields.assets.asJson)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change #1 assets
=> item_assets
centerWavelength: Option[PosDouble], | ||
fullWidthHalfMax: Option[PosDouble] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change #2
: wavelengths are Doubles
@@ -8,7 +8,6 @@ import io.circe.syntax._ | |||
import com.azavea.stac4s.extensions.ItemExtension | |||
|
|||
case class EOItemExtension( | |||
gsd: Double, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change #3
: gsd
is no longer a part of the extension, it is a part of item.properties
type Percentage = Int Refined Interval.Closed[W.`0`.T, W.`100`.T] | ||
object Percentage extends RefinedTypeOps[Percentage, Int] | ||
|
||
type BandRange = PosInt |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change #4
: we don't need BadRange
in assets anymore, it is a List[Band]
now.
import io.circe.syntax._ | ||
|
||
case class EOAssetExtension( | ||
bands: NonEmptyList[BandRange] | ||
bands: NonEmptyList[Band] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change #4
(2): we don't need BadRange
in assets anymore, it is a List[Band]
now.
0f927cf
to
095ce9a
Compare
This looks good to me. One follow up I think is that maybe we need to get rid of |
@notthatbreezy tbh I thought about it during this refactor. There is common metadata spec so we can at least cover extraction and validation of fields that are described here. Definitely sounds like a separate issue for me. |
@notthatbreezy @jisantuc I created an issue to discuss it so we won't loose it. |
Overview
This PR updates the codebase to support STAC 1.0
Checklist
Notes
This PR also updates the test catalog (wich was incredibly useful for testing purposes but took some time). I'll remove them in a follow up PR (anyway I had to update and validate them somehow to support the STAC Layer extension description) and it will be done in terms of https://github.com/azavea/geotrellis/issues/260 later this sprint.
Closes #114