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

Add package stubs and structure #48

Merged
merged 3 commits into from
Nov 30, 2022
Merged

Conversation

goanpeca
Copy link
Collaborator

@goanpeca goanpeca commented Nov 29, 2022

Add package structure for CLI and API to simplify review of #34 and #46

@goanpeca goanpeca self-assigned this Nov 29, 2022
@goanpeca goanpeca force-pushed the package-stubs branch 2 times, most recently from 5895e95 to c722fee Compare November 29, 2022 20:42
@goanpeca goanpeca requested a review from liu-ziyang November 29, 2022 22:33
@goanpeca goanpeca marked this pull request as ready for review November 29, 2022 22:33
@liu-ziyang
Copy link
Contributor

cc @aganders3 to review

@liu-ziyang
Copy link
Contributor

the packaging workflow is failing: https://github.com/napari/packaging/actions/runs/3577842461/jobs/6017466411

I assume this is some GitHub action specific issue we have to fix to ship binary to QA testing?

Copy link
Contributor

@aganders3 aganders3 left a comment

Choose a reason for hiding this comment

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

I see the intent here and overall this looks good to me. I just have a few nitpicks but the I'm sure everything can be cleaned up with #34 and #46.

For what it's worth I checked out this branch and was able to install both packages as well as run the stub tests locally.

.github/workflows/tests.yml Outdated Show resolved Hide resolved
.github/workflows/tests.yml Outdated Show resolved Hide resolved
.gitignore Show resolved Hide resolved
constructor-manager/setup.cfg Show resolved Hide resolved
@goanpeca goanpeca requested a review from aganders3 November 30, 2022 16:22
@goanpeca
Copy link
Collaborator Author

Thanks for the comments @aganders3, added fixes :)

python_requires = >=3.8
include_package_data = True
package_dir =
=src
Copy link
Contributor

Choose a reason for hiding this comment

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

is this a typo or intended?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Intended the foldert structure for the pakcages is

package-name/src/module_name

Copy link
Contributor

Choose a reason for hiding this comment

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

I think @potating-potato was referring to the =src. The syntax in setup.cfg here is confusing (bad) but this is not a typo. This gets parsed into a dictionary and that line will have an empty key: https://setuptools.pypa.io/en/latest/userguide/declarative_config.html#specifying-values

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ahhh got it, yes the syntax is weird. We can eventually migrate to a pyproject toml only and use hatch as the build system https://github.com/pypa/hatch

Copy link
Contributor

Choose a reason for hiding this comment

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

thanks for confirming! I indeed never seen this syntax before

@goanpeca goanpeca requested review from liu-ziyang and aganders3 and removed request for aganders3 November 30, 2022 19:47
@liu-ziyang
Copy link
Contributor

No objection merging this, I give it a first pass and we can iterate on this quickly

@goanpeca
Copy link
Collaborator Author

Thanks for the reviews! Merging :)

@goanpeca goanpeca merged commit 5cac7c4 into napari:main Nov 30, 2022
@goanpeca goanpeca deleted the package-stubs branch November 30, 2022 22:10
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