Skip to content

Move library into src/ directory #172

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 1 commit into from
Mar 29, 2022
Merged

Move library into src/ directory #172

merged 1 commit into from
Mar 29, 2022

Conversation

nickjj
Copy link
Contributor

@nickjj nickjj commented Mar 29, 2022

After building this locally I noticed all of the expected files were in
the wheel where as before this patch it was missing a lot of files.

This idea of using a src/ directory is mentioned in the official Python
documentation for packaging files at:

https://packaging.python.org/en/latest/tutorials/packaging-projects/

It's also used in Flask and other large Python projects.

I don't have access to push this to the test PyPi repo to give it a whirl
so I'm not 100% sure if it "really" works.

If this does end up working, I think the order of operations would be:

  • Push it to the test PyPi repo
  • Install the package into a real project
  • Confirm it works
  • Modify the version to be 0.13 instead of 0.13.dev0
  • Build the release
  • Push it to the real PyPi repo
  • Install the package into a real project
  • Confirm it works
  • Update the changelog
  • Git tag the release

After building this locally I noticed all of the expected files were in
the wheel where as before this patch it was missing a lot of files.

This idea of using a src/ directory is mentioned in the official Python
documentation for packaging files at:

https://packaging.python.org/en/latest/tutorials/packaging-projects/

It's also used in Flask and other large Python projects.
@nickjj nickjj requested a review from jeffwidman March 29, 2022 12:26
Copy link
Member

@jeffwidman jeffwidman left a comment

Choose a reason for hiding this comment

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

Yeah, this makes a lot of sense and src is definitely an idiomatic location.

@nickjj nickjj merged commit 4d84f26 into master Mar 29, 2022
@nickjj nickjj deleted the fix-setupcfg branch March 29, 2022 22:08
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants