enumplus 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- enumplus-1.0.0/.github/FUNDING.yml +3 -0
- enumplus-1.0.0/.github/ISSUE_TEMPLATE/bug_report.md +39 -0
- enumplus-1.0.0/.github/ISSUE_TEMPLATE/config.yml +8 -0
- enumplus-1.0.0/.github/ISSUE_TEMPLATE/feature_request.md +25 -0
- enumplus-1.0.0/.github/PULL_REQUEST_TEMPLATE.md +23 -0
- enumplus-1.0.0/.github/workflows/ci.yml +36 -0
- enumplus-1.0.0/.github/workflows/release.yml +124 -0
- enumplus-1.0.0/.gitignore +39 -0
- enumplus-1.0.0/CODE_OF_CONDUCT.md +133 -0
- enumplus-1.0.0/CONTRIBUTING.md +68 -0
- enumplus-1.0.0/LICENSE +21 -0
- enumplus-1.0.0/PKG-INFO +300 -0
- enumplus-1.0.0/README.md +283 -0
- enumplus-1.0.0/SECURITY.md +24 -0
- enumplus-1.0.0/SUPPORT.md +26 -0
- enumplus-1.0.0/enumplus/__init__.py +6 -0
- enumplus-1.0.0/enumplus/enum.py +206 -0
- enumplus-1.0.0/enumplus/pydantic.py +29 -0
- enumplus-1.0.0/enumplus/serialize.py +38 -0
- enumplus-1.0.0/pyproject.toml +32 -0
- enumplus-1.0.0/tests/__init__.py +0 -0
- enumplus-1.0.0/tests/test_compatibility.py +109 -0
- enumplus-1.0.0/tests/test_enum.py +545 -0
- enumplus-1.0.0/tests/test_metadata_unpacking.py +48 -0
- enumplus-1.0.0/tests/test_ordered.py +79 -0
- enumplus-1.0.0/tests/test_public_api.py +18 -0
- enumplus-1.0.0/tests/test_pydantic.py +43 -0
- enumplus-1.0.0/tests/test_serialize.py +108 -0
- enumplus-1.0.0/tests/test_type_hints.py +18 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Bug report
|
|
3
|
+
about: Create a report to help us improve
|
|
4
|
+
title: "[BUG] "
|
|
5
|
+
labels: bug
|
|
6
|
+
assignees: ""
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Describe the bug
|
|
10
|
+
|
|
11
|
+
A clear and concise description of what the bug is.
|
|
12
|
+
|
|
13
|
+
## To reproduce
|
|
14
|
+
|
|
15
|
+
Steps to reproduce the behavior:
|
|
16
|
+
|
|
17
|
+
```python
|
|
18
|
+
from enumplus import Enum
|
|
19
|
+
|
|
20
|
+
# Minimal reproducible example
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## Expected behavior
|
|
24
|
+
|
|
25
|
+
A clear and concise description of what you expected to happen.
|
|
26
|
+
|
|
27
|
+
## Actual behavior
|
|
28
|
+
|
|
29
|
+
A clear and concise description of what actually happened.
|
|
30
|
+
|
|
31
|
+
## Environment
|
|
32
|
+
|
|
33
|
+
- Python version: [e.g. 3.12.1]
|
|
34
|
+
- enumplus version: [e.g. 0.1.0]
|
|
35
|
+
- OS: [e.g. Ubuntu 22.04, Windows 11, macOS 14]
|
|
36
|
+
|
|
37
|
+
## Additional context
|
|
38
|
+
|
|
39
|
+
Add any other context about the problem here.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
blank_issues_enabled: false
|
|
2
|
+
contact_links:
|
|
3
|
+
- name: GitHub Discussions
|
|
4
|
+
url: https://github.com/MathiasPaulenko/enumpy/discussions
|
|
5
|
+
about: Ask questions and discuss ideas with the community.
|
|
6
|
+
- name: Security Policy
|
|
7
|
+
url: https://github.com/MathiasPaulenko/enumpy/blob/main/SECURITY.md
|
|
8
|
+
about: Report security vulnerabilities privately — do not open a public issue.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Feature request
|
|
3
|
+
about: Suggest an idea for this project
|
|
4
|
+
title: "[FEAT] "
|
|
5
|
+
labels: enhancement
|
|
6
|
+
assignees: ""
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Is your feature request related to a problem?
|
|
10
|
+
|
|
11
|
+
A clear and concise description of what the problem is. Ex. I'm always
|
|
12
|
+
frustrated when [...]
|
|
13
|
+
|
|
14
|
+
## Proposed solution
|
|
15
|
+
|
|
16
|
+
A clear and concise description of what you want to happen.
|
|
17
|
+
|
|
18
|
+
## Alternatives considered
|
|
19
|
+
|
|
20
|
+
A clear and concise description of any alternative solutions or features you've
|
|
21
|
+
considered.
|
|
22
|
+
|
|
23
|
+
## Additional context
|
|
24
|
+
|
|
25
|
+
Add any other context or screenshots about the feature request here.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
## Description
|
|
2
|
+
|
|
3
|
+
Briefly describe what this PR does and why.
|
|
4
|
+
|
|
5
|
+
## Type of change
|
|
6
|
+
|
|
7
|
+
- [ ] Bug fix (non-breaking change which fixes an issue)
|
|
8
|
+
- [ ] New feature (non-breaking change which adds functionality)
|
|
9
|
+
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
|
|
10
|
+
- [ ] Documentation update
|
|
11
|
+
- [ ] Refactor / cleanup
|
|
12
|
+
|
|
13
|
+
## Related issues
|
|
14
|
+
|
|
15
|
+
Closes #
|
|
16
|
+
|
|
17
|
+
## Checklist
|
|
18
|
+
|
|
19
|
+
- [ ] My code follows the project's style guidelines (ruff, mypy)
|
|
20
|
+
- [ ] I have added tests for my changes
|
|
21
|
+
- [ ] All existing and new tests pass (`pytest`)
|
|
22
|
+
- [ ] I have updated the documentation if needed
|
|
23
|
+
- [ ] My commits follow [conventional commits](https://www.conventionalcommits.org/)
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: ["main", "master"]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: ["main", "master"]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
test:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
strategy:
|
|
13
|
+
matrix:
|
|
14
|
+
python-version: ["3.11", "3.12", "3.13"]
|
|
15
|
+
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
|
|
19
|
+
- name: Set up Python ${{ matrix.python-version }}
|
|
20
|
+
uses: actions/setup-python@v5
|
|
21
|
+
with:
|
|
22
|
+
python-version: ${{ matrix.python-version }}
|
|
23
|
+
|
|
24
|
+
- name: Install dependencies
|
|
25
|
+
run: |
|
|
26
|
+
python -m pip install --upgrade pip
|
|
27
|
+
pip install -e ".[dev]"
|
|
28
|
+
|
|
29
|
+
- name: Lint with ruff
|
|
30
|
+
run: ruff check enumplus/ tests/
|
|
31
|
+
|
|
32
|
+
- name: Type check with mypy
|
|
33
|
+
run: mypy --strict enumplus/ tests/
|
|
34
|
+
|
|
35
|
+
- name: Run tests
|
|
36
|
+
run: pytest --tb=short
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*"
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: write
|
|
10
|
+
id-token: write
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
test:
|
|
14
|
+
runs-on: ubuntu-latest
|
|
15
|
+
steps:
|
|
16
|
+
- uses: actions/checkout@v4
|
|
17
|
+
|
|
18
|
+
- name: Set up Python
|
|
19
|
+
uses: actions/setup-python@v5
|
|
20
|
+
with:
|
|
21
|
+
python-version: "3.12"
|
|
22
|
+
|
|
23
|
+
- name: Install dependencies
|
|
24
|
+
run: |
|
|
25
|
+
python -m pip install --upgrade pip
|
|
26
|
+
pip install -e ".[dev]"
|
|
27
|
+
|
|
28
|
+
- name: Lint with ruff
|
|
29
|
+
run: ruff check enumplus/ tests/
|
|
30
|
+
|
|
31
|
+
- name: Type check with mypy
|
|
32
|
+
run: mypy --strict enumplus/ tests/
|
|
33
|
+
|
|
34
|
+
- name: Run tests
|
|
35
|
+
run: pytest --tb=short
|
|
36
|
+
|
|
37
|
+
build:
|
|
38
|
+
needs: test
|
|
39
|
+
runs-on: ubuntu-latest
|
|
40
|
+
steps:
|
|
41
|
+
- uses: actions/checkout@v4
|
|
42
|
+
|
|
43
|
+
- name: Set up Python
|
|
44
|
+
uses: actions/setup-python@v5
|
|
45
|
+
with:
|
|
46
|
+
python-version: "3.12"
|
|
47
|
+
|
|
48
|
+
- name: Install build dependencies
|
|
49
|
+
run: |
|
|
50
|
+
python -m pip install --upgrade pip
|
|
51
|
+
pip install build
|
|
52
|
+
|
|
53
|
+
- name: Build package
|
|
54
|
+
run: python -m build
|
|
55
|
+
|
|
56
|
+
- name: Upload artifacts
|
|
57
|
+
uses: actions/upload-artifact@v4
|
|
58
|
+
with:
|
|
59
|
+
name: dist
|
|
60
|
+
path: dist/
|
|
61
|
+
|
|
62
|
+
github-release:
|
|
63
|
+
needs: build
|
|
64
|
+
runs-on: ubuntu-latest
|
|
65
|
+
permissions:
|
|
66
|
+
contents: write
|
|
67
|
+
steps:
|
|
68
|
+
- uses: actions/checkout@v4
|
|
69
|
+
with:
|
|
70
|
+
fetch-depth: 0
|
|
71
|
+
|
|
72
|
+
- name: Download artifacts
|
|
73
|
+
uses: actions/download-artifact@v4
|
|
74
|
+
with:
|
|
75
|
+
name: dist
|
|
76
|
+
path: dist/
|
|
77
|
+
|
|
78
|
+
- name: Generate changelog
|
|
79
|
+
id: changelog
|
|
80
|
+
run: |
|
|
81
|
+
PREVIOUS_TAG=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "")
|
|
82
|
+
if [ -z "$PREVIOUS_TAG" ]; then
|
|
83
|
+
BODY=$(git log --pretty=format:"- %s (%h)" HEAD)
|
|
84
|
+
else
|
|
85
|
+
BODY=$(git log --pretty=format:"- %s (%h)" ${PREVIOUS_TAG}..HEAD)
|
|
86
|
+
fi
|
|
87
|
+
BODY="${BODY//$'\n'/'%0A'}"
|
|
88
|
+
echo "body=$BODY" >> $GITHUB_OUTPUT
|
|
89
|
+
|
|
90
|
+
- name: Create GitHub Release
|
|
91
|
+
uses: softprops/action-gh-release@v2
|
|
92
|
+
with:
|
|
93
|
+
tag_name: ${{ github.ref_name }}
|
|
94
|
+
name: ${{ github.ref_name }}
|
|
95
|
+
body: |
|
|
96
|
+
## Changes
|
|
97
|
+
|
|
98
|
+
${{ steps.changelog.outputs.body }}
|
|
99
|
+
|
|
100
|
+
---
|
|
101
|
+
|
|
102
|
+
**PyPI**: https://pypi.org/project/enumplus/
|
|
103
|
+
files: dist/*
|
|
104
|
+
draft: false
|
|
105
|
+
prerelease: false
|
|
106
|
+
generate_release_notes: true
|
|
107
|
+
|
|
108
|
+
publish-pypi:
|
|
109
|
+
needs: build
|
|
110
|
+
runs-on: ubuntu-latest
|
|
111
|
+
environment: pypi
|
|
112
|
+
permissions:
|
|
113
|
+
id-token: write
|
|
114
|
+
steps:
|
|
115
|
+
- uses: actions/checkout@v4
|
|
116
|
+
|
|
117
|
+
- name: Download artifacts
|
|
118
|
+
uses: actions/download-artifact@v4
|
|
119
|
+
with:
|
|
120
|
+
name: dist
|
|
121
|
+
path: dist/
|
|
122
|
+
|
|
123
|
+
- name: Publish to PyPI
|
|
124
|
+
uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Reference materials (local only)
|
|
2
|
+
ref/
|
|
3
|
+
|
|
4
|
+
# Python
|
|
5
|
+
__pycache__/
|
|
6
|
+
*.py[cod]
|
|
7
|
+
*$py.class
|
|
8
|
+
*.so
|
|
9
|
+
*.egg-info/
|
|
10
|
+
*.egg
|
|
11
|
+
dist/
|
|
12
|
+
build/
|
|
13
|
+
.eggs/
|
|
14
|
+
|
|
15
|
+
# Virtual environments
|
|
16
|
+
.venv/
|
|
17
|
+
venv/
|
|
18
|
+
env/
|
|
19
|
+
|
|
20
|
+
# Testing
|
|
21
|
+
.pytest_cache/
|
|
22
|
+
.coverage
|
|
23
|
+
htmlcov/
|
|
24
|
+
.tox/
|
|
25
|
+
|
|
26
|
+
# Type checking
|
|
27
|
+
.mypy_cache/
|
|
28
|
+
.ruff_cache/
|
|
29
|
+
.pyre/
|
|
30
|
+
|
|
31
|
+
# IDE
|
|
32
|
+
.idea/
|
|
33
|
+
.vscode/
|
|
34
|
+
*.swp
|
|
35
|
+
*.swo
|
|
36
|
+
|
|
37
|
+
# OS
|
|
38
|
+
.DS_Store
|
|
39
|
+
Thumbs.db
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
|
2
|
+
|
|
3
|
+
## Our Pledge
|
|
4
|
+
|
|
5
|
+
We as members, contributors, and leaders pledge to make participation in our
|
|
6
|
+
community a harassment-free experience for everyone, regardless of age, body
|
|
7
|
+
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
|
8
|
+
identity and expression, level of experience, education, socio-economic status,
|
|
9
|
+
nationality, personal appearance, race, caste, color, religion, or sexual
|
|
10
|
+
identity and orientation.
|
|
11
|
+
|
|
12
|
+
We pledge to act and interact in ways that contribute to an open, welcoming,
|
|
13
|
+
diverse, inclusive, and healthy community.
|
|
14
|
+
|
|
15
|
+
## Our Standards
|
|
16
|
+
|
|
17
|
+
Examples of behavior that contributes to a positive environment for our
|
|
18
|
+
community include:
|
|
19
|
+
|
|
20
|
+
* Demonstrating empathy and kindness toward other people
|
|
21
|
+
* Being respectful of differing opinions, viewpoints, and experiences
|
|
22
|
+
* Giving and gracefully accepting constructive feedback
|
|
23
|
+
* Accepting responsibility and apologizing to those affected by our mistakes,
|
|
24
|
+
and learning from the experience
|
|
25
|
+
* Focusing on what is best not just for us as individuals, but for the overall
|
|
26
|
+
community
|
|
27
|
+
|
|
28
|
+
Examples of unacceptable behavior include:
|
|
29
|
+
|
|
30
|
+
* The use of sexualized language or imagery, and sexual attention or advances
|
|
31
|
+
of any kind
|
|
32
|
+
* Trolling, insulting or derogatory comments, and personal or political attacks
|
|
33
|
+
* Public or private harassment
|
|
34
|
+
* Publishing others' private information, such as a physical or email address,
|
|
35
|
+
without their explicit permission
|
|
36
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
|
37
|
+
professional setting
|
|
38
|
+
|
|
39
|
+
## Enforcement Responsibilities
|
|
40
|
+
|
|
41
|
+
Community leaders are responsible for clarifying and enforcing our standards
|
|
42
|
+
of acceptable behavior and will take appropriate and fair corrective action in
|
|
43
|
+
response to any behavior that they deem inappropriate, threatening, offensive,
|
|
44
|
+
or harmful.
|
|
45
|
+
|
|
46
|
+
Community leaders have the right and responsibility to remove, edit, or reject
|
|
47
|
+
comments, commits, code, wiki edits, issues, and other contributions that are
|
|
48
|
+
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
|
49
|
+
decisions when appropriate.
|
|
50
|
+
|
|
51
|
+
## Scope
|
|
52
|
+
|
|
53
|
+
This Code of Conduct applies within all community spaces, and also applies when
|
|
54
|
+
an individual is officially representing the community in public spaces.
|
|
55
|
+
Examples of representing our community include using an official email address,
|
|
56
|
+
posting via an official social media account, or acting as an appointed
|
|
57
|
+
representative at an online or offline event.
|
|
58
|
+
|
|
59
|
+
## Enforcement
|
|
60
|
+
|
|
61
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
|
62
|
+
reported to the community leaders responsible for enforcement at
|
|
63
|
+
mathias.paulenko@outlook.com.
|
|
64
|
+
|
|
65
|
+
All complaints will be reviewed and investigated promptly and fairly.
|
|
66
|
+
|
|
67
|
+
All community leaders are obligated to respect the privacy and security of the
|
|
68
|
+
reporter of any incident.
|
|
69
|
+
|
|
70
|
+
## Enforcement Guidelines
|
|
71
|
+
|
|
72
|
+
Community leaders will follow these Community Impact Guidelines in determining
|
|
73
|
+
the consequences for any action they deem in violation of this Code of Conduct:
|
|
74
|
+
|
|
75
|
+
### 1. Correction
|
|
76
|
+
|
|
77
|
+
**Community Impact**: Use of inappropriate language or other behavior deemed
|
|
78
|
+
unprofessional or unwelcome in the community.
|
|
79
|
+
|
|
80
|
+
**Consequence**: A private, written warning from community leaders, providing
|
|
81
|
+
clarity around the nature of the violation and an explanation of why the
|
|
82
|
+
behavior was inappropriate. A public apology may be requested.
|
|
83
|
+
|
|
84
|
+
### 2. Warning
|
|
85
|
+
|
|
86
|
+
**Community Impact**: A violation through a single incident or series of
|
|
87
|
+
actions.
|
|
88
|
+
|
|
89
|
+
**Consequence**: A warning with consequences for continued behavior. No
|
|
90
|
+
interaction with the people involved, including unsolicited interaction with
|
|
91
|
+
those enforcing the Code of Conduct, for a specified period of time. This
|
|
92
|
+
includes avoiding interactions in community spaces as well as external channels
|
|
93
|
+
like social media. Violating these terms may lead to a temporary or permanent
|
|
94
|
+
ban.
|
|
95
|
+
|
|
96
|
+
### 3. Temporary Ban
|
|
97
|
+
|
|
98
|
+
**Community Impact**: A serious violation of community standards, including
|
|
99
|
+
sustained inappropriate behavior.
|
|
100
|
+
|
|
101
|
+
**Consequence**: A temporary ban from any sort of interaction or public
|
|
102
|
+
communication with the community for a specified period of time. No public or
|
|
103
|
+
private interaction with the people involved, including unsolicited interaction
|
|
104
|
+
with those enforcing the Code of Conduct, is allowed during this period.
|
|
105
|
+
Violating these terms may lead to a permanent ban.
|
|
106
|
+
|
|
107
|
+
### 4. Permanent Ban
|
|
108
|
+
|
|
109
|
+
**Community Impact**: Demonstrating a pattern of violation of community
|
|
110
|
+
standards, including sustained inappropriate behavior, harassment of an
|
|
111
|
+
individual, or aggression toward or disparagement of classes of individuals.
|
|
112
|
+
|
|
113
|
+
**Consequence**: A permanent ban from any sort of public interaction within the
|
|
114
|
+
community.
|
|
115
|
+
|
|
116
|
+
## Attribution
|
|
117
|
+
|
|
118
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
|
119
|
+
version 2.1, available at
|
|
120
|
+
[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
|
|
121
|
+
|
|
122
|
+
Community Impact Guidelines were inspired by
|
|
123
|
+
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
|
|
124
|
+
|
|
125
|
+
For answers to common questions about this code of conduct, see the FAQ at
|
|
126
|
+
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
|
|
127
|
+
[https://www.contributor-covenant.org/translations][translations].
|
|
128
|
+
|
|
129
|
+
[homepage]: https://www.contributor-covenant.org
|
|
130
|
+
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
|
|
131
|
+
[Mozilla CoC]: https://github.com/mozilla/diversity
|
|
132
|
+
[FAQ]: https://www.contributor-covenant.org/faq
|
|
133
|
+
[translations]: https://www.contributor-covenant.org/translations
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# Contributing to enumplus
|
|
2
|
+
|
|
3
|
+
Thank you for your interest in contributing to enumplus! This document describes the process for contributing to the project.
|
|
4
|
+
|
|
5
|
+
## Getting Started
|
|
6
|
+
|
|
7
|
+
1. Fork the repository on GitHub.
|
|
8
|
+
2. Clone your fork locally:
|
|
9
|
+
```bash
|
|
10
|
+
git clone https://github.com/<your-username>/enumpy.git
|
|
11
|
+
cd enumpy
|
|
12
|
+
```
|
|
13
|
+
3. Create a virtual environment and install dev dependencies:
|
|
14
|
+
```bash
|
|
15
|
+
python -m venv .venv
|
|
16
|
+
source .venv/bin/activate # On Windows: .venv\Scripts\activate
|
|
17
|
+
pip install -e ".[dev]"
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Development Workflow
|
|
21
|
+
|
|
22
|
+
1. Create a branch for your feature or bugfix:
|
|
23
|
+
```bash
|
|
24
|
+
git checkout -b feat/my-feature
|
|
25
|
+
```
|
|
26
|
+
2. Make your changes, keeping code style consistent with the existing codebase.
|
|
27
|
+
3. Run the checks before committing:
|
|
28
|
+
```bash
|
|
29
|
+
ruff check enumplus tests
|
|
30
|
+
mypy enumplus
|
|
31
|
+
pytest
|
|
32
|
+
```
|
|
33
|
+
4. Commit using [conventional commits](https://www.conventionalcommits.org/):
|
|
34
|
+
```bash
|
|
35
|
+
git commit -m "feat: add new feature"
|
|
36
|
+
git commit -m "fix: resolve bug in X"
|
|
37
|
+
```
|
|
38
|
+
5. Push to your fork and open a Pull Request.
|
|
39
|
+
|
|
40
|
+
## Code Style
|
|
41
|
+
|
|
42
|
+
- Follow PEP 8 and PEP 257.
|
|
43
|
+
- Use type hints for all public APIs.
|
|
44
|
+
- Line length: 100 characters (enforced by ruff).
|
|
45
|
+
- Target Python 3.11+.
|
|
46
|
+
|
|
47
|
+
## Testing
|
|
48
|
+
|
|
49
|
+
- All new features must include tests.
|
|
50
|
+
- Place tests in the `tests/` directory.
|
|
51
|
+
- Run the full suite with `pytest`.
|
|
52
|
+
- Do not weaken or delete existing tests without explicit justification.
|
|
53
|
+
|
|
54
|
+
## Pull Request Guidelines
|
|
55
|
+
|
|
56
|
+
- Keep PRs focused and small.
|
|
57
|
+
- Reference any related issues (e.g., `Closes #123`).
|
|
58
|
+
- Ensure all CI checks pass before requesting review.
|
|
59
|
+
- Update documentation (`README.md`) if your change affects the public API.
|
|
60
|
+
|
|
61
|
+
## Reporting Issues
|
|
62
|
+
|
|
63
|
+
- Use [GitHub Issues](https://github.com/MathiasPaulenko/enumpy/issues) to report bugs or request features.
|
|
64
|
+
- Use the provided issue templates for consistency.
|
|
65
|
+
|
|
66
|
+
## Code of Conduct
|
|
67
|
+
|
|
68
|
+
By participating in this project, you agree to abide by the [Code of Conduct](CODE_OF_CONDUCT.md).
|
enumplus-1.0.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Mathias Paulenko
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|