-
Notifications
You must be signed in to change notification settings - Fork 1
Add conda packaging support #17
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?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,193 @@ | ||||||||
| # Publishing protegrity-developer-python to Conda | ||||||||
|
|
||||||||
| This guide provides instructions for building and publishing the `protegrity-developer-python` package to Anaconda.org (conda) under the Protegrity organization. | ||||||||
|
|
||||||||
| ## Prerequisites | ||||||||
|
|
||||||||
| Before you begin, ensure you have the following installed: | ||||||||
|
|
||||||||
| 1. **Anaconda or Miniconda** | ||||||||
| ```bash | ||||||||
| # Download and install from: https://docs.conda.io/en/latest/miniconda.html | ||||||||
| ``` | ||||||||
|
|
||||||||
| 2. **conda-build** | ||||||||
| ```bash | ||||||||
| conda install conda-build | ||||||||
| ``` | ||||||||
|
|
||||||||
| 3. **anaconda-client** (for uploading to Anaconda.org) | ||||||||
| ```bash | ||||||||
| conda install anaconda-client | ||||||||
| ``` | ||||||||
|
|
||||||||
| 4. **Account Setup** | ||||||||
| - Create an account at https://anaconda.org | ||||||||
| - Create or join the "Protegrity" organization on Anaconda.org | ||||||||
| - Get appropriate permissions to publish packages under the organization | ||||||||
|
|
||||||||
| ## Building the Conda Package | ||||||||
|
|
||||||||
| ### Step 1: Navigate to the Project Root | ||||||||
|
|
||||||||
| ```bash | ||||||||
| cd /home/yigalr/projects/pty-dev | ||||||||
| ``` | ||||||||
|
|
||||||||
| ### Step 2: Build the Package | ||||||||
|
|
||||||||
| Build the conda package using the recipe in the `conda-recipe/` directory: | ||||||||
|
|
||||||||
| ```bash | ||||||||
| conda build conda-recipe/ | ||||||||
| ``` | ||||||||
|
|
||||||||
| This will: | ||||||||
| - Download the source from PyPI (or use local source if configured) | ||||||||
|
||||||||
| - Download the source from PyPI (or use local source if configured) | |
| - Use the local source directory to build the package (as configured in meta.yaml) |
Copilot
AI
Nov 11, 2025
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.
The documentation refers to a url line in the source section that needs to be commented out or removed when building from local source. However, the current meta.yaml file only contains path: .. and no url line exists. This instruction is misleading and should be removed or updated to reflect the actual file content.
| 2. Comment out or remove the `url` line | |
| 3. Run the build command from the project root: | |
| 2. Run the build command from the project root: |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| REM Install the package using pip | ||
| %PYTHON% -m pip install . -vv | ||
| if errorlevel 1 exit 1 |
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,4 @@ | ||||||||
| #!/bin/bash | ||||||||
|
||||||||
| #!/bin/bash | |
| #!/bin/bash | |
| set -e |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,53 @@ | ||||||||||||||||||||||
| {% set name = "protegrity-developer-python" %} | ||||||||||||||||||||||
| {% set version = "1.0.0" %} | ||||||||||||||||||||||
|
||||||||||||||||||||||
| {% set version = "1.0.0" %} | |
| {% set version = load_file_regex(pattern='version = "(.*)"', file='../pyproject.toml')[1] %} |
Copilot
AI
Nov 11, 2025
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.
The Python version constraint >=3.12.11 is overly restrictive. Python patch versions (the third number) are typically used for bug fixes within a minor release, and requiring a specific patch version is unusual unless there's a critical security fix or bug that affects the package. Consider using >=3.12 or >=3.12.0 instead to allow any Python 3.12.x version, which is the more common pattern in conda packages and aligns with the README badge that shows "Python 3.12+".
| - python >=3.12.11 | |
| - pip | |
| - setuptools >=61.0 | |
| run: | |
| - python >=3.12.11 | |
| - python >=3.12 | |
| - pip | |
| - setuptools >=61.0 | |
| run: | |
| - python >=3.12 |
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.
This path appears to be a personal/local directory path (
/home/yigalr/projects/pty-dev) that should not be included in documentation. It should be replaced with a generic placeholder likecd /path/to/protegrity-developer-pythonor simply removed since the build command can be run from any location within the project root.