Skip to content

BUG with links in version 2.3.0 #235

Closed
@pedro-cf

Description

@pedro-cf

Describe the bug
In version 2.1.0 of stac-fastapi.core when creating an item this item would automatically be assigned links (although one could not add aditional links) Example:

"links": [
		{
			"rel": "self",
			"type": "application/geo+json",
			"href": "http://localhost:8080/collections/test-collection/items/test-item96"
		},
		{
			"rel": "parent",
			"type": "application/json",
			"href": "http://localhost:8080/collections/test-collection"
		},
		{
			"rel": "collection",
			"type": "application/json",
			"href": "http://localhost:8080/collections/test-collection"
		},
		{
			"rel": "root",
			"type": "application/json",
			"href": "http://localhost:8080/"
		}
	]

But in version 2.3.0 when creating an item links is empty unless the user passes aditional links.

Passing the self root collection parent links has no effect aswell. They are ignored.

To Reproduce
Steps to reproduce the behavior:
Run versions 2.1.0 and 2.3.0 of stac-fastapi-elasticsearch and create 1 test collection and 1 item collection in both environments without providing links.

Expected behavior
Creating an item should auto generate links.

Screenshots
image

image
image

Desktop:

  • OS: WSL2
  • Version: Ubuntu 22

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions