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

Modernize packaging #122

Merged
merged 14 commits into from
Jan 9, 2025
Merged

Modernize packaging #122

merged 14 commits into from
Jan 9, 2025

Conversation

douglatornell
Copy link
Member

@douglatornell douglatornell commented Jan 7, 2025

  • Replace setup.cfg with project metadata in pyproject.toml
  • Move coverage configuration from .coveragerc to pyproject.toml
  • Change build backend from setuptools to hatchling
  • Move version identifier to __about__.py file
  • Remove outdated from __future__ imports
  • Remove redundant UTF-8 encoding declaration
  • Update copyright year range in file comment headers
  • Add release process section to package dev docs

Replaced `setup.py` with `pyproject.toml` to modernize the build system and
align with PEP 517/518 standards. This update simplifies dependency management,
specifies build requirements, and provides project metadata in a standardized
format.
@douglatornell douglatornell added documentation Improvements or additions to documentation SalishSeaTools maintenance Codebase & repo maintenance labels Jan 7, 2025
@douglatornell douglatornell added this to the v24.1 milestone Jan 7, 2025
Copy link

codecov bot commented Jan 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 53.08%. Comparing base (44b3bad) to head (956ddc5).
Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #122      +/-   ##
==========================================
- Coverage   53.32%   53.08%   -0.24%     
==========================================
  Files          29       29              
  Lines        3524     3506      -18     
==========================================
- Hits         1879     1861      -18     
  Misses       1645     1645              
Flag Coverage Δ
unittests 53.08% <ø> (-0.24%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Updated the project name to "SalishSeaTools" for consistency with Python naming
conventions and to align with the repository's standard branding. This change
does not affect functionality but improves clarity and uniformity.
Corrected the GitHub URL for the changelog to point to the SalishSeaCast/tools
repository releases page. Ensures accurate navigation for users accessing
release information.
Relocated the coverage settings from .coveragerc to pyproject.toml for
centralized project configuration. This simplifies project management and
removes the need for a separate .coveragerc file.
The version constraint on the `arrow` dependency has been removed in both
`environment-dev.yaml` and `environment-test.yaml`. arrow=1.0.0 was released
>3 years ago. The version pin is no longer required because environments should
now be guaranteed to install a version that includes the v1.0.0 features we
need.
Add Hatch to environment-dev.yaml for package management and modify
pyproject.toml to use Hatchling for the build system. This change replaces
setuptools with hatchling, aligning the project build process with modern
package management practices.
Move the version identifier from `__pkg_metadata__.py` to a new `__about__.py`
file. The version is now dynamically read from that file to maintain the
consistency of version info. Removed obsolete `__pkg_metadata__.py` symlink.
Change end of range to "present" to reflect ongoing, continuous development of
the package, and to avoid pointless annual updates.
The `from __future__ import division` statement was removed across multiple
files, as it is no longer required in Python 3. This cleanup improves code
readability and aligns with modern Python standards.
Updated copyright notices across multiple files to replace "The Salish Sea
MEOPAR contributors" with "The SalishSeaCast contributors". This change reflects
the current branding of the project.
The `# coding=utf-8` declaration was unnecessary as UTF-8 is the default
encoding in Python 3. This change simplifies the code without altering
functionality.
The development documentation file was renamed to better reflect its purpose as
related to package development. This improves clarity and consistency in naming
conventions within the documentation.
Documented the steps for performing a release of SalishSeaTools, including
version bumping, tagging, creating milestones, and managing issues. This ensures
clarity and consistency in the release workflow.
Refactored the Sphinx configuration file to use a cleaner and more concise
template. Removed unnecessary comments and adjusted the file to focus on
commonly used options. Added a reference link for full documentation.
@douglatornell douglatornell merged commit 5897e82 into main Jan 9, 2025
7 of 8 checks passed
@douglatornell douglatornell deleted the modernize-pkg branch January 9, 2025 17:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation maintenance Codebase & repo maintenance SalishSeaTools
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant