Skip to content
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

Allow to omit collection in bulk insertions #113

Merged

Conversation

constantinius
Copy link
Contributor

@constantinius constantinius commented May 2, 2024

Related Issue(s):

Description:

Currently, each item in a bulk insertion must match the collection on which it is executed. This is different for single item insertions. Additionally, no check for the items ID and collection ID was performed, which is now rectified.

PR Checklist:

  • pre-commit hooks pass locally
  • Tests pass (run make test)
  • Documentation has been updated to reflect changes, if applicable, and docs build successfully (run make docs)
  • Changes are added to the CHANGELOG.

@constantinius
Copy link
Contributor Author

Can't run tests locally, because I get this error in the docker build:

Step 8/8 : RUN python -m pip install -e .[dev,server] --user
 ---> Running in eec7acdacb2d
Obtaining file:///app
  Installing build dependencies: started
  Installing build dependencies: finished with status 'done'
  Checking if build backend supports build_editable: started
  Checking if build backend supports build_editable: finished with status 'done'
  Getting requirements to build editable: started
  Getting requirements to build editable: finished with status 'error'
  error: subprocess-exited-with-error
  
  × Getting requirements to build editable did not run successfully.
  │ exit code: 1
  ╰─> [3 lines of output]
      No `name` configuration, performing automatic discovery
      running egg_info
      error: Cannot update time stamp of directory 'stac_fastapi.pgstac.egg-info'
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

@jonhealy1
Copy link
Collaborator

Linting error in gh actions. I'm not sure why you are getting that error?

@vincentsarago
Copy link
Member

I'm pretty sure the error is due to some permission error if you use Docker, I would make sure there is no stac_fastapi.pgstac.egg-info previously created somewhere

@constantinius constantinius marked this pull request as ready for review May 6, 2024 09:23
@vincentsarago
Copy link
Member

after talking with @ emmanuelmathot we agree that the collection_id is not needed for the items when submitting to the bulk items ingest endpoint 👍

thanks for the pr @constantinius 🙏

@vincentsarago vincentsarago merged commit cb08b0f into stac-utils:main Aug 2, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants