title: "Spectomate - Python Package Management Format Converter" description: "A tool for converting projects between different Python package management formats (pip, conda, poetry)" author: "Tom Sapletta" keywords: "python, package management, pip, conda, poetry, converter, requirements.txt, environment.yml, pyproject.toml" lang: "en" image: "https://github.com/spectomate/python/raw/main/docs/diagrams/logo.png"
Spectomate
Spectomate is a tool for converting projects between different Python package management formats (pip, conda, poetry).
Key Features of Spectomate:
- Modular architecture - each converter is a separate module implementing a common interface
- Support for existing tools - ability to integrate with external conversion tools
- Flexible extension system - easy addition of new converters without modifying the base code
- Comprehensive format support:
- pip (requirements.txt)
- conda (environment.yml)
- poetry (pyproject.toml)
- Project management tools:
- Package version updating
- Testing and linting automation
- Publication to PyPI
Installation
# Basic installation
pip install spectomate
How to Use Spectomate:
Command Line Interface (CLI)
Format Conversion
# Display available converters
spectomate --list
# Convert from pip to conda
spectomate -s pip -t conda -i requirements.txt -o environment.yml --env-name myproject
# Convert from conda to pip
spectomate -s conda -t pip -i environment.yml -o requirements.txt
# Convert from pip to poetry
spectomate -s pip -t poetry -i requirements.txt -o pyproject.toml --project-name "my-project" --version "0.1.0"
Package Update and Management
# Full package update with publication
spectomate update
# Interactive update with project analysis
spectomate update --interactive
# Only analyze project without updating
spectomate update --analyze-only
# Update without publishing to PyPI
spectomate update --no-publish
# Update without type checking
spectomate update --no-mypy
# Update without running tests
spectomate update --no-test
# Update without linting
spectomate update --no-lint
# Update without checking Git submodules
spectomate update --no-submodules
# Update with verbose output
spectomate update --verbose
Programmatic Usage
from spectomate.converters.pip_to_conda import PipToCondaConverter
# Convert from pip to conda
converter = PipToCondaConverter(
source_file="requirements.txt",
target_file="environment.yml",
options={"env_name": "myproject"}
)
result_path = converter.execute()
print(f"Output file: {result_path}")
Project Structure
spectomate/
├── __init__.py # Package initialization
├── cli.py # Command line interface
├── core/ # Core components
│ ├── __init__.py
│ ├── base_converter.py # Base class for converters
│ ├── registry.py # Converter registration system
│ └── utils.py # Helper functions
├── converters/ # Converter implementations
│ ├── __init__.py
│ ├── conda_to_pip.py # Converter from conda to pip
│ ├── pip_to_conda.py # Converter from pip to conda
│ ├── pip_to_poetry.py # Converter from pip to poetry
│ └── ...
└── schemas/ # Data schemas for formats
├── __init__.py
├── conda_schema.py # Schema for conda format
├── pip_schema.py # Schema for pip format
├── poetry_schema.py # Schema for poetry format
└── ...
Documentation
Detailed documentation is available in the docs/ directory:
- Architecture - description of the system architecture
- Converters - description of available converters and their implementation
- Schemas - description of data schemas for different formats
Diagrams
Visual documentation in the form of Mermaid diagrams:
- Architecture Diagram - class structure and relationships between components
- Data Flow Diagram - data flow during the conversion process
- Sequence Diagram - interactions between components during conversion
- Extension Diagram - process of adding new converters and formats
Note: Polish documentation is available in the docs/pl/ directory.
Extending Spectomate
Spectomate is designed as a modular system that can be easily extended with new formats and converters. To add a new converter:
- Create a new converter class inheriting from
BaseConverter - Implement the required abstract methods:
get_source_format()- returns the source format identifierget_target_format()- returns the target format identifierread_source()- reads the source fileconvert()- converts the datawrite_target()- writes the data to the target file
- Register the converter using the
@register_converterdecorator
Detailed information on creating custom converters can be found in the converters documentation.
License
This project is licensed under the Apache 2 License
Metadata
Release files for spectomate 0.1.66
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| spectomate-0.1.66.tar.gz | 41.7 kB | Without provenance | Details for spectomate-0.1.66.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| spectomate-0.1.66-py3-none-any.whl | Python 3 | none | any | Details for spectomate-0.1.66-py3-none-any.whl |
Total release size: 90.1 kB
Release files / spectomate-0.1.66.tar.gz
| Download URL | spectomate-0.1.66.tar.gz |
|---|---|
| Size | 41.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
376367d7a0a39442cdb986a1a08b0ee47820153b0be35f2ee41d962d23d25e98
|
|
BLAKE2b-256 checksum How to use checksums |
4cd7ab992cd76ec8865941b3b4f16db29edbb7b482bc5d024b209612bd898277
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Release files / spectomate-0.1.66-py3-none-any.whl
| Download URL | spectomate-0.1.66-py3-none-any.whl |
|---|---|
| Size | 48.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
adf5825e6f44b00d1abe2c7d0c4f887711751fe09ad0083ff4850493ea2f0b50
|
|
BLAKE2b-256 checksum How to use checksums |
5cd2fb2f9fc144851414dadc4decb6afc08936d31a18543bc435503aeb32b9bd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Security for spectomate 0.1.66
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.