Skip to content

Package and dependency migration to poetry - #6

Merged
ni-jfitzger merged 7 commits into
ni:mainfrom
sourabhutaniCG:nisyscfg-python-poetry-migration
Oct 12, 2026
Merged

ni-jfitzger merged 7 commits into
ni:mainfrom
sourabhutaniCG:nisyscfg-python-poetry-migration

Conversation

@sourabhutaniCG

Copy link
Copy Markdown

What does this Pull Request accomplish?

  • Migrates project packaging and dependency management from setup.py and tox.ini to Poetry.
  • Establishes pyproject.toml as the single source of truth for project metadata and tool configuration.
  • Generates and commits poetry.lock to ensure deterministic dependency resolution.
  • Updates development and CI workflows to use Poetry commands.
  • Removes legacy configuration files that are fully replaced by Poetry.

Why should this Pull Request be merged?

  • Simplifies project configuration by consolidating settings into a single file.
  • Improves dependency reproducibility through a committed lock file.
  • Modernizes the project's packaging and dependency management workflow.

What testing has been done?

  • Verified dependency installation using poetry install
  • Executed unit tests using poetry run pytest
  • Executed linting checks using poetry run flake8
  • Verified package build creation using poetry build
  • Validated CI workflow updates and confirmed existing workflows continue to function as expected.

@sourabhutaniCG

Copy link
Copy Markdown
Author

Hi @ni-jfitzger , Please review the PR with below mentioned scope of work and share your feedback.

  • Migrate the repository’s package and dependency management to Poetry, using pyproject.toml as the single source of truth for project configuration. Create and maintain poetry.lock file to provide deterministic dependency versions across environments and update CI workflows to use Poetry for dependency installation, package build, linting, and test execution, ensuring existing automation continues to function as expected.

@sourabhutaniCG
sourabhutaniCG marked this pull request as ready for review October 12, 2026 11:27
Comment thread pyproject.toml Outdated
Comment thread pyproject.toml
@ni-jfitzger

Copy link
Copy Markdown
Collaborator

We're still triggering the Publish workflow off of changes to the VERSION file, even though pyproject.toml isn't using it.
We should update the publish workflow to trigger on release: (types: [published]) like the example repo and nidaqmx-python.
https://github.com/ni/nidaqmx-python/blob/a4071cf78ef3edcaa2bdc1a5a7c263ba87601b81/.github/workflows/publish.yml#L3

Don't worry about adding a workflow_dispatch trigger. That can be done with the rest of the workflow changes that will come later.

And we should be able to delete the VERSION file, as well.

@sourabhutaniCG

Copy link
Copy Markdown
Author

We're still triggering the Publish workflow off of changes to the VERSION file, even though pyproject.toml isn't using it. We should update the publish workflow to trigger on release: (types: [published]) like the example repo and nidaqmx-python. https://github.com/ni/nidaqmx-python/blob/a4071cf78ef3edcaa2bdc1a5a7c263ba87601b81/.github/workflows/publish.yml#L3

Don't worry about adding a workflow_dispatch trigger. That can be done with the rest of the workflow changes that will come later.

And we should be able to delete the VERSION file, as well.

Thanks for the suggestion. I've updated the publish workflow to trigger on release.published, removed the dependency on the VERSION file, and removed the unused VERSION file. I'll leave the additional workflow modernization (workflow_dispatch) which doesn't fit for this PR scope, in later workflow/pypi publishing PR.

@ni-jfitzger
ni-jfitzger merged commit bfd2b8b into ni:main Oct 12, 2026
6 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.

2 participants