Skip to content

Include typing information during packaging #579

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

Merged
merged 4 commits into from
Jul 27, 2021

Conversation

cuttlefish
Copy link
Contributor

@cuttlefish cuttlefish commented Jul 27, 2021

Related Issue(s):
stac-utils/stactools#155

Description:
This includes type information in the packages so that users of pystac can utilize it. This is particularly useful if the downstream project uses mypy or any of its competitors.

PR Checklist:

  • Code is formatted (run pre-commit run --all-files)
  • Tests pass (run scripts/test)
  • [ ] Documentation has been updated to reflect changes, if applicable
  • This PR maintains or improves overall codebase code coverage.
  • Changes are added to the CHANGELOG. See the docs for information about adding to the changelog.

@cuttlefish cuttlefish mentioned this pull request Jul 27, 2021
4 tasks
cuttlefish added a commit to stac-utils/stactools that referenced this pull request Jul 27, 2021
@cuttlefish
Copy link
Contributor Author

cuttlefish commented Jul 27, 2021

@duckontheweb Python packaging is not my forte, but this seems to work based on my testing.
I'm hoping to use it in stac-utils/stactools#182

gadomski pushed a commit to stac-utils/stactools that referenced this pull request Jul 27, 2021
Copy link
Contributor

@duckontheweb duckontheweb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this @cuttlefish!

Based on past experience and brushing up on the Data Files Support docs I think it might be best to just use package_data and not include_package_data (see specific comments below). Let me know what you think.

@cuttlefish
Copy link
Contributor Author

Thanks so much @duckontheweb! You're right about include_package_data. Just specifying package_data seems to do the trick.
I've also pulled in @gadomski's build fix, so hopefully the CI passes.

Copy link
Contributor

@duckontheweb duckontheweb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻

@duckontheweb duckontheweb merged commit c6f9a6b into stac-utils:main Jul 27, 2021
@cuttlefish cuttlefish deleted the feature/mypy-export branch July 27, 2021 22:06
cuttlefish added a commit to stac-utils/stactools that referenced this pull request Jul 28, 2021
cuttlefish added a commit to stac-utils/stactools that referenced this pull request Jul 28, 2021
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.

2 participants