Skip to content

NH-14860 refactor setuptools config#25

Merged
tammy-baylis-swi merged 6 commits intoNH-14368-add-metrics-span-processorfrom
NH-14860-refactor-setuptools-config
Jul 6, 2022
Merged

NH-14860 refactor setuptools config#25
tammy-baylis-swi merged 6 commits intoNH-14368-add-metrics-span-processorfrom
NH-14860-refactor-setuptools-config

Conversation

@tammy-baylis-swi
Copy link
Copy Markdown
Contributor

Moves as much of the build configs as possible out of setup.py and into setup.cfg, because setup.py is deprecated for this purpose. I also added pyproject.toml with [build-system] metadata that doesn't actually seem to be needed, but I figured we'd make like OTel Python and just say we have such a file. More background info here as you've already seen: https://swicloud.atlassian.net/wiki/spaces/NIT/pages/3137996006/NH+Python+packaging+and+distribution

I did a quick manual test similar to the last PR, doing a Python 3.6 build step by step: https://swicloud.atlassian.net/wiki/spaces/NIT/pages/3140551795/2022-07-04+sdist+generation+with+setup.cfg

This PR also addresses two comments on the last PR:

  1. Fixes the Python 3.6 lower boundary, per this comment.
  2. Re-adds setup.py logging after switch to vanilla logging, per this comment. But it is a bit noisy because it adds -v to the pip wheel call.

Please let me know what you think!

@tammy-baylis-swi tammy-baylis-swi requested a review from cheempz July 4, 2022 23:55
Copy link
Copy Markdown
Contributor

@cheempz cheempz left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for the revisit and detailed test write up @tammy-baylis-swi! I'm fine with the verbose output during wheel generation, it's usually good to get more info rather than less during package build to help troubleshoot.

My original comment was actually about the logging during an sdist install, where our custom extension compile (and all that mucking with platform determination + symlinking) in the setup.py is happening on the customer's host. It's still not getting the log messages, but it's also a minor use case so let's set it aside for now -- ideally most customer installs are on platforms supported by our wheels so having to install sdist and go through the compile step may not occur too often.

@tammy-baylis-swi
Copy link
Copy Markdown
Contributor Author

My original comment was actually about the logging during an sdist install, where our custom extension compile (and all that mucking with platform determination + symlinking) in the setup.py is happening on the customer's host.

Oh oops!

It's still not getting the log messages, but it's also a minor use case so let's set it aside for now

Ok sounds good. Thanks Lin!

@tammy-baylis-swi tammy-baylis-swi merged commit 9ee5a58 into NH-14368-add-metrics-span-processor Jul 6, 2022
@tammy-baylis-swi tammy-baylis-swi deleted the NH-14860-refactor-setuptools-config branch July 6, 2022 00:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants