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

Rename version.py files to version/__init__.py #4099

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ocelotl
Copy link
Contributor

@ocelotl ocelotl commented Jul 31, 2024

Fixes #4097

@ocelotl ocelotl added the Skip Changelog PRs that do not require a CHANGELOG.md entry label Jul 31, 2024
@ocelotl ocelotl self-assigned this Jul 31, 2024
@ocelotl ocelotl requested a review from a team July 31, 2024 21:54
@xrmx
Copy link
Contributor

xrmx commented Aug 1, 2024

Wouldn't be simpler doing the other way around? It's not a module that I expect will grow in scope. What do you think?

@ocelotl
Copy link
Contributor Author

ocelotl commented Aug 1, 2024

Wouldn't be simpler doing the other way around? It's not a module that I expect will grow in scope. What do you think?

We want the version being specified in a version/__init__.py file..

@xrmx
Copy link
Contributor

xrmx commented Aug 2, 2024

Wouldn't be simpler doing the other way around? It's not a module that I expect will grow in scope. What do you think?

We want the version being specified in a version/__init__.py file..

Why we want that?

@ocelotl ocelotl changed the title Rename version.py files to version/__init__.py Rename version/__init__.py files to version.py Sep 6, 2024
@ocelotl
Copy link
Contributor Author

ocelotl commented Sep 6, 2024

After some discussion, we agreed that it would be better just to rename the version/__init__.py files to version.py.

@ocelotl ocelotl changed the title Rename version/__init__.py files to version.py Rename version.py files to version/__init__.py Sep 6, 2024
@ocelotl ocelotl marked this pull request as draft September 9, 2024 22:07
@ocelotl
Copy link
Contributor Author

ocelotl commented Sep 9, 2024

Converting to draft to prevent accidental merging

@ocelotl ocelotl marked this pull request as ready for review September 20, 2024 20:46
@ocelotl ocelotl requested a review from a team as a code owner September 20, 2024 20:46
@ocelotl
Copy link
Contributor Author

ocelotl commented Sep 20, 2024

After some discussion, we agreed that it would be better just to rename the version/__init__.py files to version.py.

After even more discussion we agreed to convert all version files to version/__init__.py.

Copy link
Member

@aabmass aabmass left a comment

Choose a reason for hiding this comment

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

LGTM. Can you add some explanation to the PR description or issue of how we decided to go this route?

["tool"]["hatch"]["version"]["path"]
)

with open(version_file_path) as _file:
Copy link
Member

Choose a reason for hiding this comment

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

why not file instead of _file?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Skip Changelog PRs that do not require a CHANGELOG.md entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inconsistent use of version files
4 participants