just-cdb 0.1.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.
@@ -0,0 +1,63 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ env:
10
+ CARGO_TERM_COLOR: always
11
+
12
+ jobs:
13
+ lint-rust:
14
+ name: Lint Rust
15
+ runs-on: ubuntu-latest
16
+ steps:
17
+ - uses: actions/checkout@v6
18
+
19
+ - uses: dtolnay/rust-toolchain@stable
20
+ with:
21
+ components: rustfmt, clippy
22
+
23
+ - uses: Swatinem/rust-cache@v2
24
+
25
+ - name: Check formatting
26
+ run: cargo fmt -- --check
27
+
28
+ - name: Clippy
29
+ run: cargo clippy -- -D warnings
30
+
31
+ test-rust:
32
+ name: Test Rust
33
+ runs-on: ubuntu-latest
34
+ steps:
35
+ - uses: actions/checkout@v6
36
+
37
+ - uses: dtolnay/rust-toolchain@stable
38
+
39
+ - uses: Swatinem/rust-cache@v2
40
+
41
+ - name: Run tests
42
+ run: cargo test
43
+
44
+ test-python:
45
+ name: Test Python (${{ matrix.os }})
46
+ runs-on: ${{ matrix.os }}
47
+ strategy:
48
+ fail-fast: false
49
+ matrix:
50
+ os: [ubuntu-latest, macos-latest, windows-latest]
51
+ steps:
52
+ - uses: actions/checkout@v6
53
+
54
+ - uses: dtolnay/rust-toolchain@stable
55
+
56
+ - uses: Swatinem/rust-cache@v2
57
+
58
+ - uses: astral-sh/setup-uv@v7
59
+
60
+ - name: Build and test
61
+ run: |
62
+ uv run maturin develop
63
+ uv run pytest
@@ -0,0 +1,207 @@
1
+ name: Release
2
+
3
+ on:
4
+ workflow_dispatch:
5
+ inputs:
6
+ version:
7
+ description: 'New version number to release (e.g., 0.2.0)'
8
+ required: true
9
+ type: string
10
+
11
+ permissions:
12
+ contents: write
13
+
14
+ jobs:
15
+ prepare-release:
16
+ name: Prepare Release & Git Tag
17
+ runs-on: ubuntu-latest
18
+ outputs:
19
+ version: ${{ steps.bump.outputs.version }}
20
+ steps:
21
+ - name: Checkout repository
22
+ uses: actions/checkout@v6
23
+ with:
24
+ fetch-depth: 0
25
+
26
+ - name: Set up Python
27
+ uses: actions/setup-python@v6
28
+ with:
29
+ python-version: '3.12'
30
+
31
+ - name: Bump version in configuration files
32
+ id: bump
33
+ run: |
34
+ python -c "
35
+ import re
36
+ version = '${{ inputs.version }}'
37
+
38
+ # 1. Update pyproject.toml
39
+ with open('pyproject.toml', 'r') as f:
40
+ content = f.read()
41
+ content = re.sub(r'(?<=^version = \")[^\"]+', version, content, count=1, flags=re.MULTILINE)
42
+ with open('pyproject.toml', 'w') as f:
43
+ f.write(content)
44
+
45
+ # 2. Update Cargo.toml
46
+ with open('Cargo.toml', 'r') as f:
47
+ content = f.read()
48
+ content = re.sub(r'(?<=^version = \")[^\"]+', version, content, count=1, flags=re.MULTILINE)
49
+ with open('Cargo.toml', 'w') as f:
50
+ f.write(content)
51
+ "
52
+ echo "version=${{ inputs.version }}" >> $GITHUB_OUTPUT
53
+
54
+ - name: Commit and push changes
55
+ run: |
56
+ git config --global user.name "github-actions[bot]"
57
+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
58
+ git add pyproject.toml Cargo.toml
59
+ if [ -n "$(git status --porcelain)" ]; then
60
+ git commit -m "chore: bump version to v${{ inputs.version }}"
61
+ git remote set-url origin "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git"
62
+ git push origin main
63
+ else
64
+ echo "No changes to commit (version is already set to ${{ inputs.version }})."
65
+ fi
66
+
67
+ - name: Create and push Git tag
68
+ run: |
69
+ if git rev-parse "v${{ inputs.version }}" >/dev/null 2>&1; then
70
+ echo "Tag v${{ inputs.version }} already exists. Force updating tag."
71
+ git tag -f "v${{ inputs.version }}"
72
+ git remote set-url origin "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git"
73
+ git push origin "v${{ inputs.version }}" --force
74
+ else
75
+ git tag "v${{ inputs.version }}"
76
+ git remote set-url origin "https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git"
77
+ git push origin "v${{ inputs.version }}"
78
+ fi
79
+
80
+ - name: Create GitHub Release
81
+ env:
82
+ GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
83
+ run: |
84
+ gh release create "v${{ inputs.version }}" --title "v${{ inputs.version }}" --generate-notes || echo "Release already exists."
85
+
86
+ build-windows:
87
+ name: Build Wheels (Windows - x86_64)
88
+ runs-on: windows-latest
89
+ needs: prepare-release
90
+ steps:
91
+ - name: Checkout repository
92
+ uses: actions/checkout@v6
93
+ with:
94
+ ref: "v${{ needs.prepare-release.outputs.version }}"
95
+
96
+ - name: Build wheels using Maturin
97
+ uses: PyO3/maturin-action@v1
98
+ with:
99
+ target: x86_64
100
+ args: --release --out dist
101
+ sccache: 'true'
102
+
103
+ - name: Upload wheels as artifact
104
+ uses: actions/upload-artifact@v7
105
+ with:
106
+ name: wheels-windows-x86_64
107
+ path: dist
108
+
109
+ build-linux:
110
+ name: Build Wheels (Linux - ${{ matrix.target }})
111
+ runs-on: ubuntu-latest
112
+ needs: prepare-release
113
+ strategy:
114
+ fail-fast: false
115
+ matrix:
116
+ target: [x86_64, aarch64]
117
+ steps:
118
+ - name: Checkout repository
119
+ uses: actions/checkout@v6
120
+ with:
121
+ ref: "v${{ needs.prepare-release.outputs.version }}"
122
+
123
+ - name: Set up QEMU for multi-architecture emulation
124
+ if: matrix.target == 'aarch64'
125
+ uses: docker/setup-qemu-action@v4
126
+
127
+ - name: Build wheels using Maturin (manylinux)
128
+ uses: PyO3/maturin-action@v1
129
+ with:
130
+ target: ${{ matrix.target }}
131
+ args: --release --out dist
132
+ sccache: 'true'
133
+ manylinux: auto
134
+
135
+ - name: Upload wheels as artifact
136
+ uses: actions/upload-artifact@v7
137
+ with:
138
+ name: wheels-linux-${{ matrix.target }}
139
+ path: dist
140
+
141
+ build-macos:
142
+ name: Build Wheels (macOS - ${{ matrix.target }})
143
+ runs-on: macos-latest
144
+ needs: prepare-release
145
+ strategy:
146
+ fail-fast: false
147
+ matrix:
148
+ target: [x86_64, aarch64]
149
+ steps:
150
+ - name: Checkout repository
151
+ uses: actions/checkout@v6
152
+ with:
153
+ ref: "v${{ needs.prepare-release.outputs.version }}"
154
+
155
+ - name: Build wheels using Maturin
156
+ uses: PyO3/maturin-action@v1
157
+ with:
158
+ target: ${{ matrix.target }}
159
+ args: --release --out dist
160
+ sccache: 'true'
161
+
162
+ - name: Upload wheels as artifact
163
+ uses: actions/upload-artifact@v7
164
+ with:
165
+ name: wheels-macos-${{ matrix.target }}
166
+ path: dist
167
+
168
+ build-sdist:
169
+ name: Build Source Distribution
170
+ runs-on: ubuntu-latest
171
+ needs: prepare-release
172
+ steps:
173
+ - name: Checkout repository
174
+ uses: actions/checkout@v6
175
+ with:
176
+ ref: "v${{ needs.prepare-release.outputs.version }}"
177
+
178
+ - name: Build source distribution using Maturin
179
+ uses: PyO3/maturin-action@v1
180
+ with:
181
+ command: sdist
182
+ args: --out dist
183
+
184
+ - name: Upload source distribution as artifact
185
+ uses: actions/upload-artifact@v7
186
+ with:
187
+ name: sdist
188
+ path: dist
189
+
190
+ publish:
191
+ name: Publish to PyPI
192
+ runs-on: ubuntu-latest
193
+ needs: [build-windows, build-linux, build-macos, build-sdist]
194
+ permissions:
195
+ id-token: write # Required for PyPI OIDC Trusted Publishing
196
+ steps:
197
+ - name: Download all build artifacts
198
+ uses: actions/download-artifact@v8
199
+ with:
200
+ pattern: '*'
201
+ path: dist
202
+ merge-multiple: true
203
+
204
+ - name: Publish all packages to PyPI
205
+ uses: pypa/gh-action-pypi-publish@release/v1
206
+ with:
207
+ packages-dir: dist/
@@ -0,0 +1,220 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[codz]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ # Usually these files are written by a python script from a template
31
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
32
+ *.manifest
33
+ *.spec
34
+
35
+ # Installer logs
36
+ pip-log.txt
37
+ pip-delete-this-directory.txt
38
+
39
+ # Unit test / coverage reports
40
+ htmlcov/
41
+ .tox/
42
+ .nox/
43
+ .coverage
44
+ .coverage.*
45
+ .cache
46
+ nosetests.xml
47
+ coverage.xml
48
+ *.cover
49
+ *.py.cover
50
+ *.lcov
51
+ .hypothesis/
52
+ .pytest_cache/
53
+ cover/
54
+
55
+ # Translations
56
+ *.mo
57
+ *.pot
58
+
59
+ # Django stuff:
60
+ *.log
61
+ local_settings.py
62
+ db.sqlite3
63
+ db.sqlite3-journal
64
+
65
+ # Flask stuff:
66
+ instance/
67
+ .webassets-cache
68
+
69
+ # Scrapy stuff:
70
+ .scrapy
71
+
72
+ # Sphinx documentation
73
+ docs/_build/
74
+
75
+ # PyBuilder
76
+ .pybuilder/
77
+ target/
78
+
79
+ # Jupyter Notebook
80
+ .ipynb_checkpoints
81
+
82
+ # IPython
83
+ profile_default/
84
+ ipython_config.py
85
+
86
+ # pyenv
87
+ # For a library or package, you might want to ignore these files since the code is
88
+ # intended to run in multiple environments; otherwise, check them in:
89
+ # .python-version
90
+
91
+ # pipenv
92
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
93
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
94
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
95
+ # install all needed dependencies.
96
+ # Pipfile.lock
97
+
98
+ # UV
99
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
100
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
101
+ # commonly ignored for libraries.
102
+ # uv.lock
103
+
104
+ # poetry
105
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
106
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
107
+ # commonly ignored for libraries.
108
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
109
+ # poetry.lock
110
+ # poetry.toml
111
+
112
+ # pdm
113
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
114
+ # pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
115
+ # https://pdm-project.org/en/latest/usage/project/#working-with-version-control
116
+ # pdm.lock
117
+ # pdm.toml
118
+ .pdm-python
119
+ .pdm-build/
120
+
121
+ # pixi
122
+ # Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
123
+ # pixi.lock
124
+ # Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
125
+ # in the .venv directory. It is recommended not to include this directory in version control.
126
+ .pixi/*
127
+ !.pixi/config.toml
128
+
129
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
130
+ __pypackages__/
131
+
132
+ # Celery stuff
133
+ celerybeat-schedule*
134
+ celerybeat.pid
135
+
136
+ # Redis
137
+ *.rdb
138
+ *.aof
139
+ *.pid
140
+
141
+ # RabbitMQ
142
+ mnesia/
143
+ rabbitmq/
144
+ rabbitmq-data/
145
+
146
+ # ActiveMQ
147
+ activemq-data/
148
+
149
+ # SageMath parsed files
150
+ *.sage.py
151
+
152
+ # Environments
153
+ .env
154
+ .envrc
155
+ .venv
156
+ env/
157
+ venv/
158
+ ENV/
159
+ env.bak/
160
+ venv.bak/
161
+
162
+ # Spyder project settings
163
+ .spyderproject
164
+ .spyproject
165
+
166
+ # Rope project settings
167
+ .ropeproject
168
+
169
+ # mkdocs documentation
170
+ /site
171
+
172
+ # mypy
173
+ .mypy_cache/
174
+ .dmypy.json
175
+ dmypy.json
176
+
177
+ # Pyre type checker
178
+ .pyre/
179
+
180
+ # pytype static type analyzer
181
+ .pytype/
182
+
183
+ # Cython debug symbols
184
+ cython_debug/
185
+
186
+ # PyCharm
187
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
188
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
189
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
190
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
191
+ # .idea/
192
+
193
+ # Abstra
194
+ # Abstra is an AI-powered process automation framework.
195
+ # Ignore directories containing user credentials, local state, and settings.
196
+ # Learn more at https://abstra.io/docs
197
+ .abstra/
198
+
199
+ # Visual Studio Code
200
+ # Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
201
+ # that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
202
+ # and can be added to the global gitignore or merged into this file. However, if you prefer,
203
+ # you could uncomment the following to ignore the entire vscode folder
204
+ # .vscode/
205
+ # Temporary file for partial code execution
206
+ tempCodeRunnerFile.py
207
+
208
+ # Ruff stuff:
209
+ .ruff_cache/
210
+
211
+ # PyPI configuration file
212
+ .pypirc
213
+
214
+ # Marimo
215
+ marimo/_static/
216
+ marimo/_lsp/
217
+ __marimo__/
218
+
219
+ # Streamlit
220
+ .streamlit/secrets.toml
@@ -0,0 +1 @@
1
+ 3.13