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

Create app.py instead of hello.py in uv init #10369

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

Conversation

Gankra
Copy link
Contributor

@Gankra Gankra commented Jan 7, 2025

From the discussion, it seems like app.py maybe has one benefit (at least one tool seems to autodetect it) and main.py maybe has one downside (__main__ is already a thing and people might think this is related or get confused). So on balance if we have to pick one, app.py seems a bit better.

Fixes #7782

From the discussion, it seems like app.py maybe has one benefit (at least one tool seems to autodetect it) and main.py maybe has one downside (__main__ is already a thing and people might think this is related or get confused). So on balance if we have to pick one, app.py seems a bit better.
@Gankra
Copy link
Contributor Author

Gankra commented Jan 7, 2025

The only concern I have with this is it changes intro docs, so there will be an awkward period where people have older versions of uv that make hello.py but the guide says they make app.py. Dunno if we want to make the docs hedge for a bit or what.

@zanieb
Copy link
Member

zanieb commented Jan 7, 2025

The only concern I have with this is it changes intro docs, so there will be an awkward period where people have older versions of uv that make hello.py but the guide says they make app.py. Dunno if we want to make the docs hedge for a bit or what.

I'd just go for it — you could add an admonition about older versions if you want though.

@zanieb zanieb added the enhancement New feature or improvement to existing functionality label Jan 7, 2025
@zanieb
Copy link
Member

zanieb commented Jan 7, 2025

Arguably this is sort of breaking, though I'm not sure we consider uv init to be a typical programmatic interface. @charliermarsh thoughts?

If we decide it's breaking, we'll just hold it until 0.6.0 (for which there is a milestone to track other breaking changes).

@Gankra Gankra changed the title rename hello.py to app.py Create app.py instead of hello.py in uv init Jan 7, 2025
@charliermarsh
Copy link
Member

It probably makes sense to defer this to v0.6. We could do a v0.6 in the near future though.

@zanieb zanieb added this to the v0.6.0 milestone Jan 7, 2025
@zanieb zanieb added the breaking A breaking change label Jan 7, 2025
@zanieb
Copy link
Member

zanieb commented Jan 7, 2025

Sorry for giving you an unmergable task!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking A breaking change enhancement New feature or improvement to existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

FR: uv init option to specify alternative filename to hello.py
3 participants