-
Notifications
You must be signed in to change notification settings - Fork 2.4k
docs: add usage guide for contributors on existing Poetry projects (#8131) #10669
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
base: main
Are you sure you want to change the base?
docs: add usage guide for contributors on existing Poetry projects (#8131) #10669
Conversation
Reviewer's guide (collapsed on small PRs)Reviewer's GuideAdds a new documentation subsection to the basic usage guide that explains how contributors should work with an existing Poetry-managed project, including installing dependencies, using the virtual environment, running commands, and adding dependencies, with links back to project creation docs. Flow diagram for contributor setup workflow with an existing Poetry projectflowchart TD
A[Contributor clones project that uses Poetry] --> B[Navigate to project directory]
B --> C[Run poetry install to create virtualenv and install dependencies]
C --> D{How to work in the environment?}
D --> E[Activate subshell with poetry shell]
D --> F[Run individual commands with poetry run command]
E --> G[Develop, run tests, and tools inside subshell]
F --> G
G --> H{Need new dependency?}
H --> I[Add runtime dependency with poetry add package_name]
H --> J[Add dev dependency to dev group if project uses one]
H --> K[Edit pyproject.toml directly if project guidelines require]
I --> L[Poetry updates pyproject.toml and lock file]
J --> L
K --> L
L --> M[Continue contributing using project environment]
A -.-> N[If goal is a new project, follow Basic Usage project creation docs]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey - I've left some high level feedback:
- The new contributor section is very high-level prose; consider adding a few concrete command examples (e.g.,
poetry install,poetry shell,poetry run pytest,poetry add <package> --group dev) as code blocks to make it immediately actionable for readers. - There is a minor wording/formatting issue in “
pyproject.tomlfile” where a space is missing before “file”; a quick pass for similar small typos in the new section would improve readability.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The new contributor section is very high-level prose; consider adding a few concrete command examples (e.g., `poetry install`, `poetry shell`, `poetry run pytest`, `poetry add <package> --group dev`) as code blocks to make it immediately actionable for readers.
- There is a minor wording/formatting issue in “`pyproject.toml`file” where a space is missing before “file”; a quick pass for similar small typos in the new section would improve readability.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
|
I’ve added the suggested command examples and fixed the minor typo. Ready for review again. |
Hey everyone! 👋
I added a new section to the documentation for people who want to contribute to a project that already uses Poetry.
Right now, the basic usage guide mostly covers creating new projects, which can be a bit confusing if you just want to get started contributing to an existing project.
What’s included:
poetry install)poetry shell)poetry run <command>)poetry add <package-name>or dev dependencies)This change is purely documentation, so it won’t affect how Poetry works—just makes it easier for newcomers to contribute.
Fixes / relates to issue: #8131
Summary by Sourcery
Documentation: