Skip to content

feat: Initial project setup, assets, and dev notes#4

Merged
TheRealFREDP3D merged 1 commit intomainfrom
initial
Jun 8, 2025
Merged

feat: Initial project setup, assets, and dev notes#4
TheRealFREDP3D merged 1 commit intomainfrom
initial

Conversation

@TheRealFREDP3D
Copy link
Copy Markdown
Owner

@TheRealFREDP3D TheRealFREDP3D commented Jun 8, 2025

This commit introduces the initial project structure, including:

  • Project assets (images)
  • Development notes for review and PyPI preparation
  • Updates to .gitignore
  • Removal of .env.sample
  • Addition of pyproject.toml and uv.lock for dependency management
  • Updates to PullPal.py and header.md with minor adjustments.

Summary by Sourcery

Set up the initial project skeleton with dependency management, developer notes, and minor CLI refinements.

Enhancements:

  • Update CLI header banner, default repository owner/name, and adjust loading bar behavior.

Build:

  • Add pyproject.toml and uv.lock for packaging and dependency management.

Documentation:

  • Include developer notes for PyPI publishing, project review, and release planning in _DEV_NOTES.

Chores:

  • Establish initial project structure with assets, update .gitignore, and remove obsolete .env.sample.

This commit introduces the initial project structure, including:

- Project assets (images)
- Development notes for review and PyPI preparation
- Updates to `.gitignore`
- Removal of `.env.sample`
- Addition of `pyproject.toml` and `uv.lock` for dependency management
- Updates to `PullPal.py` and `header.md` with minor adjustments.
@sourcery-ai
Copy link
Copy Markdown

sourcery-ai bot commented Jun 8, 2025

Reviewer's Guide

The PR establishes the initial project scaffolding: it refreshes UI elements, tunes core defaults, configures packaging and VCS settings, and adds developer-centric documentation and lock files.

Class Diagram: Updates to PullPal.py Module

classDiagram
    direction LR
    class PullPalModule {
        <<Module>>
        +DEFAULT_REPO_OWNER: string = "therealfredp3d"
        +DEFAULT_REPO_NAME: string = "pullpal"
        +display_loading_bar(duration: int = 2, width: int = 80) None
    }
Loading

File-Level Changes

Change Details Files
Refreshed project header ASCII art
  • Removed legacy PullPal ASCII banner
  • Inserted new stylized ASCII logo
pullpal/header.md
Adjusted application defaults and UI behavior
  • Updated DEFAULT_REPO_OWNER and DEFAULT_REPO_NAME constants
  • Changed display_loading_bar default duration from 5 to 2 and width from 50 to 80
pullpal/PullPal.py
Updated version control ignores and removed sample environment file
  • Modified .gitignore to reflect new directories and files
  • Deleted .env.sample from the repository
.gitignore
.env.sample
Added packaging configuration and lock file
  • Created pyproject.toml with project metadata and dependencies
  • Introduced uv.lock for deterministic dependency locking
pyproject.toml
uv.lock
Added developer notes and publishing guides
  • Created pypi-publishing.md with PyPI preparation steps
  • Added Full-review.md for deep-dive project feedback
  • Introduced Pypi-prepare-plan.md outlining release plan
_DEV_NOTES/pypi-publishing.md
_DEV_NOTES/Full-review.md
_DEV_NOTES/Pypi-prepare-plan.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Hello @TheRealFREDP3D, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

Summary of Changes

Hello! gemini-code-assist here, providing a summary of this pull request. This PR, titled "feat: Initial project setup, assets, and dev notes", focuses on establishing the foundational structure for the PullPal project. It includes adding initial project assets (images), incorporating development notes covering a project review and PyPI preparation steps, updating the .gitignore file, removing an old .env.sample, and introducing modern Python dependency management with pyproject.toml and uv.lock. Additionally, minor adjustments were made to the main PullPal.py script and the header.md file.

Highlights

  • Project Structure & Assets: The PR lays down the initial directory structure and includes necessary project assets.
  • Development Notes Added: Two new markdown files (Full-review.md and Pypi-prepare-plan.md) are added under a _DEV_NOTES directory, providing a detailed project review and a plan for publishing to PyPI.
  • Dependency Management Setup: Introduces pyproject.toml for standard project metadata and build configuration (PEP 517/518) and uv.lock for locked dependencies using the uv tool.
  • .gitignore Updates: Adds /PullPal.code-workspace to the .gitignore file to prevent committing IDE workspace settings.
  • Minor Code Adjustments: Updates default repository details and loading bar parameters in PullPal.py and replaces the ASCII art in header.md.

Changelog

Click here to see the changelog
  • .gitignore
    • Added /PullPal.code-workspace to ignore IDE workspace settings.
  • _DEV_NOTES/Full-review.md
    • Added a new file containing a comprehensive review of the PullPal project.
    • Includes sections on project overview, strengths, areas for improvement (packaging, testing, CI/CD, error handling, docs, robustness, versioning), and a suggested roadmap.
  • _DEV_NOTES/Pypi-prepare-plan.md
    • Added a new file outlining a step-by-step plan for publishing PullPal to PyPI.
    • Includes checks for name availability, updating setup.py, creating a PyPI account, installing twine, building the package, uploading, and verification.
    • Contains a mermaid diagram visualizing the publishing process.
  • _DEV_NOTES/pypi-publishing.md
    • Added a new file providing a detailed step-by-step guide for publishing to PyPI.
    • Covers project structure, creating pyproject.toml, adding __init__.py, building with python -m build, uploading with twine, and testing the installation.
    • Includes optional steps for using TestPyPI and extra tips for automation and version management.
  • pullpal/PullPal.py
    • Changed DEFAULT_REPO_OWNER from "octocat" to "therealfredp3d" (L47).
    • Changed DEFAULT_REPO_NAME from "hello-world" to "pullpal" (L48).
    • Adjusted display_loading_bar default duration from 5 to 2 seconds and width from 50 to 80 (L73).
  • pullpal/header.md
    • Replaced the existing ASCII art header with a new one.
  • pyproject.toml
    • Added a new file for project configuration and build system.
    • Defines project name, version, description, readme, license, Python requirements, authors, dependencies (typer[all], requests, rich, python-dotenv), script entry point, and homepage URL.
  • uv.lock
    • Added a new file containing locked versions and hashes for all project dependencies, generated by uv.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in issue comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist is currently in preview and may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments to provide feedback.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@TheRealFREDP3D TheRealFREDP3D merged commit edca9a2 into main Jun 8, 2025
5 checks passed
@TheRealFREDP3D TheRealFREDP3D deleted the initial branch June 8, 2025 16:41
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces foundational project setup elements, including assets, development notes, and pyproject.toml for modern dependency management. This is a great step forward! I've reviewed the changes and have a few suggestions.

Summary of Findings

  • Entry Point Configuration: There's a mismatch in the defined entry point between pyproject.toml (pullpal.main:app) and the existing script structure (pullpal.PullPal:main). This could lead to the installed CLI not functioning correctly. This is a high severity issue.
  • Python Version Consistency: pyproject.toml specifies requires-python = ">=3.8" while setup.py mentions >=3.6. Clarifying the supported Python versions and ensuring consistency is advisable.
  • Development Notes Consistency: Minor inconsistencies in build commands and main script references were found in the development notes. Aligning these would improve clarity.
  • Redundant Dependency (Low Severity - Not commented in-line): In pyproject.toml, rich is listed as a dependency, but typer[all] already includes rich. This is a minor redundancy.

Merge Readiness

This PR makes good progress on project setup. However, due to the high-severity issue regarding the entry point configuration in pyproject.toml (which could affect the tool's installability and functionality), I recommend addressing this and the medium-severity consistency points before merging. Once these are clarified and potentially adjusted, the PR will be in a much stronger position. As an AI, I am not authorized to approve pull requests; please ensure further review and approval from team members.

Comment thread pyproject.toml
Comment on lines +15 to +16
[project.scripts]
pullpal = "pullpal.main:app"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

high

The [project.scripts] is set to pullpal = "pullpal.main:app". However, the current executable script is pullpal/PullPal.py which contains a main() function and uses argparse. The existing setup.py also points to pullpal.PullPal:main. If pullpal/main.py with a Typer app isn't being introduced, the CLI packaged with this pyproject.toml might not work as expected. Should this be pullpal = "pullpal.PullPal:main" to match the current structure, or is a refactor to use pullpal.main:app planned?

Resolving the entry point is crucial for the package to be installable and executable correctly.

2. **Update `setup.py` with correct information:** Verify that the `setup.py` file contains accurate information, including the project name, version, author, email, description, and dependencies. The version should follow semantic versioning.
3. **Create a PyPI account (if needed):** If you don't already have a PyPI account, you will need to create one at [https://pypi.org/account/register/](https://pypi.org/account/register/).
4. **Install `twine`:** Twine is a tool for securely uploading packages to PyPI. It can be installed using pip: `pip install twine`
5. **Build the distribution package:** Use the `python setup.py sdist bdist_wheel` command to build the source distribution and wheel package.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The build command python setup.py sdist bdist_wheel is an older method. Since pyproject.toml is being introduced with a build backend, should python -m build be used instead for consistency? This is also recommended in _DEV_NOTES/pypi-publishing.md.

Suggested change
5. **Build the distribution package:** Use the `python setup.py sdist bdist_wheel` command to build the source distribution and wheel package.
5. **Build the distribution package:** Use the `python -m build` command to build the source distribution and wheel package.

pullpal/
├── pullpal/ # Your actual package code
│ ├── __init__.py
│ └── main.py
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

This is a helpful guide! There's a slight inconsistency regarding the main script file and entry point.

This note (and line 60) refers to pullpal/main.py and the entry point pullpal.main:app. However, the current primary script is pullpal/PullPal.py (with a main() function), and the existing setup.py points to pullpal.PullPal:main.

Is pullpal/main.py a new file to be introduced, or should the entry point in pyproject.toml and these notes reflect the existing pullpal.PullPal:main for now? Aligning these will prevent confusion during packaging.

Comment thread pyproject.toml
description = "PullPal - GitHub PR Suggestion Archivist CLI Tool"
readme = "README.md"
license = {file = "LICENSE"}
requires-python = ">=3.8"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The requires-python is set to >=3.8 here. The existing setup.py file has python_requires=">=3.6". Is the intention to drop support for Python 3.6 and 3.7? If so, this change is fine, but it's good to be explicit. If Python 3.6/3.7 support is still desired, this might need adjustment.

Copy link
Copy Markdown

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey @TheRealFREDP3D - I've reviewed your changes - here's some feedback:

  • Consider moving the _DEV_NOTES/ folder out of the main package or explicitly excluding it from your pyproject.toml to avoid shipping internal planning docs with the release.
  • Avoid hard-coding DEFAULT_REPO_OWNER and DEFAULT_REPO_NAME—pull them from CLI arguments, environment variables, or your project metadata for greater flexibility.
  • The loading bar’s fixed width of 80 may overflow small terminals—cap it to the current terminal width or make the bar size configurable.
Here's what I looked at during the review
  • 🟡 General issues: 2 issues found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Comment thread pyproject.toml
license = {file = "LICENSE"}
requires-python = ">=3.8"
authors = [{name = "Frederick Pellerin", email = "[email protected]"}]
dependencies = ["typer[all]", "requests", "rich", "python-dotenv"]
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

suggestion: Specify version ranges for dependencies

Adding minimum version constraints (e.g., requests>=2.25) helps avoid issues from incompatible upstream changes.

Suggested change
dependencies = ["typer[all]", "requests", "rich", "python-dotenv"]
dependencies = [
"typer[all]>=0.7.0",
"requests>=2.25.0",
"rich>=10.0.0",
"python-dotenv>=0.19.0"
]

Comment thread _DEV_NOTES/Full-review.md
Comment on lines +28 to +29
4. **Environment variable support for GitHub tokens**
`.env` and CLI override options ensures flexibility and security.
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

issue (typo): Grammatical error: 'ensures' should be 'ensure'.

Since 'options' is plural, use 'ensure' instead of 'ensures'.

Suggested change
4. **Environment variable support for GitHub tokens**
`.env` and CLI override options ensures flexibility and security.
4. **Environment variable support for GitHub tokens**
`.env` and CLI override options ensure flexibility and security.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant