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

Change the format of the version tracking file #203

Merged
merged 2 commits into from
Dec 6, 2024

Conversation

mcdonnnj
Copy link
Member

@mcdonnnj mcdonnnj commented Dec 6, 2024

🗣 Description

This pull request removes the Python trappings from the version tracking file (src/version.txt). The version tracking file is changed to be a flat text file storing the version. The test configuration is also updated to pull the project version in a fixture instead of in any test using it.

💭 Motivation and context

This mirrors cisagov/skeleton-packer#379 as it has the same rationale. The test configuration change is to DRY out repeated logic.

🧪 Testing

Automated tests pass. I confirmed that the bump-version script worked as expected.

✅ Pre-approval checklist

  • This PR has an informative and human-readable title.
  • Changes are limited to a single goal - eschew scope creep!
  • All relevant type-of-change labels have been added.
  • I have read the CONTRIBUTING document.
  • These code changes follow cisagov code standards.
  • Tests have been added and/or modified to cover the changes in this PR.
  • All new and existing tests pass.

@mcdonnnj mcdonnnj added breaking change This issue or pull request involves changes to existing functionality improvement This issue or pull request will add or improve functionality, maintainability, or ease of use labels Dec 6, 2024
@mcdonnnj mcdonnnj self-assigned this Dec 6, 2024
There is no reason to have any information but the version in the
version tracking file for Docker image projects. The current format
is simply an artifact of mirroring things over from the
cisagov/skeleton-python-library project.
We were previously getting the version in three different tests. It
makes more sense to turn getting the project version into a fixture and
to use that fixture anywhere the project version is needed.
@mcdonnnj mcdonnnj force-pushed the improvement/change_version_file_format branch from 4867f97 to 414efb4 Compare December 6, 2024 15:23
@mcdonnnj mcdonnnj added the test This issue or pull request adds or otherwise modifies test code label Dec 6, 2024
@mcdonnnj mcdonnnj requested review from dav3r and jsf9k December 6, 2024 16:34
Copy link
Member

@dav3r dav3r left a comment

Choose a reason for hiding this comment

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

Love it! 👍

@mcdonnnj mcdonnnj added this pull request to the merge queue Dec 6, 2024
Merged via the queue into develop with commit 7d4071d Dec 6, 2024
17 checks passed
@mcdonnnj mcdonnnj deleted the improvement/change_version_file_format branch December 6, 2024 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change This issue or pull request involves changes to existing functionality improvement This issue or pull request will add or improve functionality, maintainability, or ease of use test This issue or pull request adds or otherwise modifies test code
Projects
Development

Successfully merging this pull request may close these issues.

3 participants