pygamlastan 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.
Files changed (96) hide show
  1. pygamlastan-0.1.0/.github/workflows/ci.yml +262 -0
  2. pygamlastan-0.1.0/.github/workflows/release.yml +235 -0
  3. pygamlastan-0.1.0/.gitignore +223 -0
  4. pygamlastan-0.1.0/.readthedocs.yaml +25 -0
  5. pygamlastan-0.1.0/Cargo.lock +2221 -0
  6. pygamlastan-0.1.0/Cargo.toml +19 -0
  7. pygamlastan-0.1.0/LICENSE +23 -0
  8. pygamlastan-0.1.0/PKG-INFO +107 -0
  9. pygamlastan-0.1.0/README.md +86 -0
  10. pygamlastan-0.1.0/adr/0001-profile-extension-surface.md +104 -0
  11. pygamlastan-0.1.0/adr/README.md +13 -0
  12. pygamlastan-0.1.0/build-wheels.sh +18 -0
  13. pygamlastan-0.1.0/docs/Makefile +20 -0
  14. pygamlastan-0.1.0/docs/_static/.gitkeep +0 -0
  15. pygamlastan-0.1.0/docs/_templates/.gitkeep +0 -0
  16. pygamlastan-0.1.0/docs/api/attribute_map.rst +57 -0
  17. pygamlastan-0.1.0/docs/api/bindings.rst +75 -0
  18. pygamlastan-0.1.0/docs/api/core.rst +209 -0
  19. pygamlastan-0.1.0/docs/api/crypto.rst +155 -0
  20. pygamlastan-0.1.0/docs/api/idp.rst +64 -0
  21. pygamlastan-0.1.0/docs/api/metadata.rst +61 -0
  22. pygamlastan-0.1.0/docs/api/profiles.rst +101 -0
  23. pygamlastan-0.1.0/docs/api/security.rst +84 -0
  24. pygamlastan-0.1.0/docs/api/xml.rst +29 -0
  25. pygamlastan-0.1.0/docs/conf.py +47 -0
  26. pygamlastan-0.1.0/docs/exceptions.rst +70 -0
  27. pygamlastan-0.1.0/docs/guides/attributes.rst +58 -0
  28. pygamlastan-0.1.0/docs/guides/bindings.rst +103 -0
  29. pygamlastan-0.1.0/docs/guides/idp_integration.rst +215 -0
  30. pygamlastan-0.1.0/docs/guides/metadata.rst +73 -0
  31. pygamlastan-0.1.0/docs/guides/signing.rst +137 -0
  32. pygamlastan-0.1.0/docs/guides/sp_integration.rst +163 -0
  33. pygamlastan-0.1.0/docs/guides/validation.rst +92 -0
  34. pygamlastan-0.1.0/docs/guides/writing_profiles.rst +259 -0
  35. pygamlastan-0.1.0/docs/index.rst +85 -0
  36. pygamlastan-0.1.0/docs/installation.rst +56 -0
  37. pygamlastan-0.1.0/docs/quickstart.rst +103 -0
  38. pygamlastan-0.1.0/examples/django-idp/.dockerignore +7 -0
  39. pygamlastan-0.1.0/examples/django-idp/.env-example +28 -0
  40. pygamlastan-0.1.0/examples/django-idp/.gitignore +7 -0
  41. pygamlastan-0.1.0/examples/django-idp/Caddyfile +8 -0
  42. pygamlastan-0.1.0/examples/django-idp/Dockerfile +33 -0
  43. pygamlastan-0.1.0/examples/django-idp/README.md +213 -0
  44. pygamlastan-0.1.0/examples/django-idp/config/__init__.py +0 -0
  45. pygamlastan-0.1.0/examples/django-idp/config/settings.py +129 -0
  46. pygamlastan-0.1.0/examples/django-idp/config/urls.py +9 -0
  47. pygamlastan-0.1.0/examples/django-idp/config/wsgi.py +6 -0
  48. pygamlastan-0.1.0/examples/django-idp/docker-compose.yml +56 -0
  49. pygamlastan-0.1.0/examples/django-idp/entrypoint.sh +21 -0
  50. pygamlastan-0.1.0/examples/django-idp/idp/__init__.py +0 -0
  51. pygamlastan-0.1.0/examples/django-idp/idp/apps.py +10 -0
  52. pygamlastan-0.1.0/examples/django-idp/idp/checks.py +39 -0
  53. pygamlastan-0.1.0/examples/django-idp/idp/idp_config.py +57 -0
  54. pygamlastan-0.1.0/examples/django-idp/idp/management/__init__.py +0 -0
  55. pygamlastan-0.1.0/examples/django-idp/idp/management/commands/__init__.py +0 -0
  56. pygamlastan-0.1.0/examples/django-idp/idp/management/commands/idp_keys.py +54 -0
  57. pygamlastan-0.1.0/examples/django-idp/idp/management/commands/seed_demo.py +46 -0
  58. pygamlastan-0.1.0/examples/django-idp/idp/migrations/__init__.py +0 -0
  59. pygamlastan-0.1.0/examples/django-idp/idp/saml_logic.py +192 -0
  60. pygamlastan-0.1.0/examples/django-idp/idp/sp_resolver.py +132 -0
  61. pygamlastan-0.1.0/examples/django-idp/idp/templates/idp/base.html +29 -0
  62. pygamlastan-0.1.0/examples/django-idp/idp/templates/idp/error.html +25 -0
  63. pygamlastan-0.1.0/examples/django-idp/idp/templates/idp/index.html +24 -0
  64. pygamlastan-0.1.0/examples/django-idp/idp/templates/idp/login.html +17 -0
  65. pygamlastan-0.1.0/examples/django-idp/idp/urls.py +14 -0
  66. pygamlastan-0.1.0/examples/django-idp/idp/views.py +151 -0
  67. pygamlastan-0.1.0/examples/django-idp/justfile +119 -0
  68. pygamlastan-0.1.0/examples/django-idp/manage.py +20 -0
  69. pygamlastan-0.1.0/examples/django-idp/pyproject.toml +17 -0
  70. pygamlastan-0.1.0/pyproject.toml +45 -0
  71. pygamlastan-0.1.0/python/pygamlastan/__init__.py +53 -0
  72. pygamlastan-0.1.0/python/pygamlastan/__init__.pyi +31 -0
  73. pygamlastan-0.1.0/python/pygamlastan/attribute_map.pyi +30 -0
  74. pygamlastan-0.1.0/python/pygamlastan/bindings.pyi +48 -0
  75. pygamlastan-0.1.0/python/pygamlastan/core.pyi +299 -0
  76. pygamlastan-0.1.0/python/pygamlastan/crypto.pyi +64 -0
  77. pygamlastan-0.1.0/python/pygamlastan/idp.pyi +35 -0
  78. pygamlastan-0.1.0/python/pygamlastan/metadata.pyi +32 -0
  79. pygamlastan-0.1.0/python/pygamlastan/profiles.pyi +128 -0
  80. pygamlastan-0.1.0/python/pygamlastan/py.typed +1 -0
  81. pygamlastan-0.1.0/python/pygamlastan/security.pyi +62 -0
  82. pygamlastan-0.1.0/python/pygamlastan/xml.pyi +7 -0
  83. pygamlastan-0.1.0/src/attribute_map.rs +138 -0
  84. pygamlastan-0.1.0/src/bindings.rs +321 -0
  85. pygamlastan-0.1.0/src/convert.rs +33 -0
  86. pygamlastan-0.1.0/src/core.rs +848 -0
  87. pygamlastan-0.1.0/src/crypto.rs +522 -0
  88. pygamlastan-0.1.0/src/errors.rs +74 -0
  89. pygamlastan-0.1.0/src/idp.rs +164 -0
  90. pygamlastan-0.1.0/src/lib.rs +39 -0
  91. pygamlastan-0.1.0/src/metadata.rs +252 -0
  92. pygamlastan-0.1.0/src/profiles.rs +510 -0
  93. pygamlastan-0.1.0/src/security.rs +444 -0
  94. pygamlastan-0.1.0/src/xml.rs +68 -0
  95. pygamlastan-0.1.0/tests/conftest.py +80 -0
  96. pygamlastan-0.1.0/tests/test_pygamlastan.py +937 -0
@@ -0,0 +1,262 @@
1
+ name: ci
2
+ on:
3
+ pull_request:
4
+ paths:
5
+ - 'src/**'
6
+ - 'python/**'
7
+ - 'tests/**'
8
+ - 'Cargo.lock'
9
+ - 'Cargo.toml'
10
+ - 'pyproject.toml'
11
+ workflow_dispatch:
12
+ env:
13
+ FORCE_COLOR: "1"
14
+ UV_LINK_MODE: "copy"
15
+ jobs:
16
+
17
+ manylinux_x86_64:
18
+ runs-on: ubuntu-latest
19
+ timeout-minutes: 10
20
+ steps:
21
+ - uses: actions/checkout@v7
22
+
23
+ - name: Pull the manylinux image
24
+ run: docker pull quay.io/pypa/manylinux_2_28_x86_64
25
+
26
+ - name: Build the wheel inside manylinux container
27
+ run: |
28
+ docker run --rm \
29
+ -v ${{ github.workspace }}:/io \
30
+ quay.io/pypa/manylinux_2_28_x86_64 \
31
+ /io/build-wheels.sh
32
+
33
+ - name: Install UV
34
+ run: |
35
+ curl -LsSf https://astral.sh/uv/install.sh | sh
36
+ uv venv
37
+ source .venv/bin/activate
38
+ uv pip install pytest
39
+ uv pip install ./dist/pygamlastan-*.whl
40
+
41
+ - name: Run tests
42
+ run: |
43
+ source .venv/bin/activate
44
+ pytest tests/ -vvv
45
+
46
+ - name: Store wheels
47
+ uses: actions/upload-artifact@v4
48
+ with:
49
+ name: pygamlastan_manylinux_x86_64
50
+ path: dist/
51
+ overwrite: true
52
+ retention-days: 1
53
+ if-no-files-found: "error"
54
+ compression-level: 0
55
+
56
+ # PKCS#11 / HSM integration tests, driven by SoftHSM2.
57
+ # Unlike pybergshamra (which provisions a token via hsm-test/setup.sh),
58
+ # pygamlastan's `softhsm` pytest fixture provisions a throwaway token itself
59
+ # and auto-skips when the tooling is absent, so this job only needs to install
60
+ # softhsm2 + opensc and run the suite; the pkcs11-marked tests then execute.
61
+ hsm:
62
+ name: HSM (SoftHSM2 / PKCS#11)
63
+ runs-on: ubuntu-latest
64
+ timeout-minutes: 15
65
+ steps:
66
+ - uses: actions/checkout@v5
67
+
68
+ - name: Install SoftHSM2 + OpenSC
69
+ run: sudo apt-get update && sudo apt-get install -y softhsm2 opensc
70
+
71
+ - uses: dtolnay/rust-toolchain@stable
72
+
73
+ - name: Install UV
74
+ run: curl -LsSf https://astral.sh/uv/install.sh | sh
75
+
76
+ - name: Build and install the extension
77
+ run: |
78
+ uv venv
79
+ uv pip install "maturin>=1,<2" pytest
80
+ uv run maturin develop
81
+
82
+ - name: Run the test suite (incl. PKCS#11)
83
+ run: |
84
+ .venv/bin/python -m pytest tests/ -vvv
85
+
86
+ #manylinux_aarch64:
87
+ #runs-on: ubuntu-24-arm
88
+ #timeout-minutes: 10
89
+ #steps:
90
+ #- uses: actions/checkout@v5
91
+
92
+ #- name: Pull the manylinux image
93
+ #run: docker pull quay.io/pypa/manylinux_2_28_aarch64
94
+
95
+ #- name: Build the wheel inside manylinux container
96
+ #run: |
97
+ #docker run --rm \
98
+ #-v ${{ github.workspace }}:/io \
99
+ #quay.io/pypa/manylinux_2_28_aarch64 \
100
+ #/io/build-wheels.sh
101
+
102
+ #- name: Install UV
103
+ #run: |
104
+ #curl -LsSf https://astral.sh/uv/install.sh | sh
105
+ #uv venv
106
+ #source .venv/bin/activate
107
+ #uv pip install pytest
108
+ #uv pip install ./dist/pygamlastan-*.whl
109
+
110
+ #- name: Run tests
111
+ #run: |
112
+ #source .venv/bin/activate
113
+ #pytest tests/ -vvv
114
+
115
+ #- name: Store wheels
116
+ #uses: actions/upload-artifact@v4
117
+ #with:
118
+ #name: pygamlastan_manylinux_aarch64
119
+ #path: dist/
120
+ #overwrite: true
121
+ #retention-days: 1
122
+ #if-no-files-found: "error"
123
+ #compression-level: 0
124
+
125
+ #macos_aarch64:
126
+ #runs-on: macos-15
127
+ #timeout-minutes: 10
128
+ #steps:
129
+ #- uses: actions/checkout@v5
130
+
131
+ #- uses: actions/setup-python@v6
132
+ #with:
133
+ #allow-prereleases: true
134
+ #python-version: "3.14"
135
+
136
+ #- uses: dtolnay/rust-toolchain@stable
137
+ #with:
138
+ #targets: "aarch64-apple-darwin"
139
+
140
+ #- name: Build environment
141
+ #run: |
142
+ #curl -LsSf https://astral.sh/uv/install.sh | sh
143
+ #uv venv --python python3.14
144
+ #source .venv/bin/activate
145
+ #uv pip install --upgrade "maturin>=1,<2" pytest
146
+
147
+ #- name: Build wheel
148
+ #run: |
149
+ #source .venv/bin/activate
150
+ #MACOSX_DEPLOYMENT_TARGET="11.0" \
151
+ #maturin build \
152
+ #--release \
153
+ #--strip \
154
+ #--interpreter python3.14 \
155
+ #--target=aarch64-apple-darwin
156
+
157
+ #- name: Run tests
158
+ #run: |
159
+ #source .venv/bin/activate
160
+ #uv pip install target/wheels/pygamlastan-*.whl
161
+ #pytest tests/ -vvv
162
+
163
+ #- name: Store wheels
164
+ #uses: actions/upload-artifact@v4
165
+ #with:
166
+ #name: pygamlastan_macos_aarch64
167
+ #path: target/wheels
168
+ #overwrite: true
169
+ #retention-days: 1
170
+ #if-no-files-found: "error"
171
+ #compression-level: 0
172
+
173
+ #windows_amd64:
174
+ #runs-on: windows-2025
175
+ #timeout-minutes: 10
176
+ #steps:
177
+ #- uses: actions/checkout@v5
178
+
179
+ #- uses: actions/setup-python@v6
180
+ #with:
181
+ #allow-prereleases: true
182
+ #python-version: "3.14"
183
+ #architecture: "x64"
184
+
185
+ #- uses: dtolnay/rust-toolchain@stable
186
+ #with:
187
+ #targets: "x86_64-pc-windows-msvc"
188
+
189
+ #- name: Build environment
190
+ #run: |
191
+ #python.exe -m pip install --upgrade pip "maturin>=1,<2" pytest
192
+
193
+ #- name: Build wheel
194
+ #run: |
195
+ #maturin.exe build --release --strip --target=x86_64-pc-windows-msvc
196
+
197
+ #- name: Run tests
198
+ #shell: pwsh
199
+ #run: |
200
+ #python -m venv venv
201
+ #.\venv\Scripts\Activate.ps1
202
+ #pip install pytest
203
+ #pip install pygamlastan --no-index --find-links target\wheels
204
+ #pytest tests/ -vvv
205
+
206
+ #- name: Store wheels
207
+ #uses: actions/upload-artifact@v4
208
+ #with:
209
+ #name: pygamlastan_windows_amd64
210
+ #path: target\wheels
211
+ #overwrite: true
212
+ #retention-days: 1
213
+ #if-no-files-found: "error"
214
+ #compression-level: 0
215
+
216
+ #windows_aarch64:
217
+ #runs-on: windows-11-arm
218
+ #timeout-minutes: 10
219
+ #env:
220
+ #TARGET: "aarch64-pc-windows-msvc"
221
+ #steps:
222
+ #- uses: actions/checkout@v5
223
+
224
+ #- uses: actions/setup-python@v6
225
+ #with:
226
+ #allow-prereleases: true
227
+ #python-version: "3.14"
228
+ #architecture: "arm64"
229
+
230
+ #- shell: pwsh
231
+ #run: |
232
+ #Invoke-WebRequest -Uri "https://static.rust-lang.org/rustup/dist/$env:TARGET/rustup-init.exe" -OutFile rustup-init.exe
233
+ #.\rustup-init.exe --default-toolchain "stable-$env:TARGET" --profile minimal --component rust-src -y
234
+ #"$env:USERPROFILE\.cargo\bin" | Out-File -Append -Encoding ascii $env:GITHUB_PATH
235
+ #"CARGO_HOME=$env:USERPROFILE\.cargo" | Out-File -Append -Encoding ascii $env:GITHUB_ENV
236
+
237
+ #- name: Build environment
238
+ #run: |
239
+ #python.exe -m pip install --upgrade pip "maturin>=1,<2" pytest
240
+
241
+ #- name: Build wheel
242
+ #run: |
243
+ #maturin.exe build --release --strip --target="$env:TARGET"
244
+
245
+ #- name: Run tests
246
+ #shell: pwsh
247
+ #run: |
248
+ #python -m venv venv
249
+ #.\venv\Scripts\Activate.ps1
250
+ #pip install pytest
251
+ #pip install pygamlastan --no-index --find-links target\wheels
252
+ #pytest tests/ -vvv
253
+
254
+ #- name: Store wheels
255
+ #uses: actions/upload-artifact@v4
256
+ #with:
257
+ #name: pygamlastan_windows_aarch64
258
+ #path: target\wheels
259
+ #overwrite: true
260
+ #retention-days: 1
261
+ #if-no-files-found: "error"
262
+ #compression-level: 0
@@ -0,0 +1,235 @@
1
+ name: release
2
+ on:
3
+ push:
4
+ tags:
5
+ - 'v*'
6
+ workflow_dispatch:
7
+ env:
8
+ FORCE_COLOR: "1"
9
+ UV_LINK_MODE: "copy"
10
+ jobs:
11
+
12
+ manylinux_x86_64:
13
+ runs-on: ubuntu-latest
14
+ timeout-minutes: 10
15
+ steps:
16
+ - uses: actions/checkout@v7
17
+
18
+ - name: Pull the manylinux image
19
+ run: docker pull quay.io/pypa/manylinux_2_28_x86_64
20
+
21
+ - name: Build the wheel inside manylinux container
22
+ run: |
23
+ docker run --rm \
24
+ -v ${{ github.workspace }}:/io \
25
+ quay.io/pypa/manylinux_2_28_x86_64 \
26
+ /io/build-wheels.sh
27
+
28
+ - name: Install UV and test
29
+ run: |
30
+ curl -LsSf https://astral.sh/uv/install.sh | sh
31
+ uv venv
32
+ source .venv/bin/activate
33
+ uv pip install pytest
34
+ uv pip install ./dist/pygamlastan-*.whl
35
+ pytest tests/ -vvv
36
+
37
+ - name: Store wheels
38
+ uses: actions/upload-artifact@v4
39
+ with:
40
+ name: pygamlastan_manylinux_x86_64
41
+ path: dist/
42
+ overwrite: true
43
+ retention-days: 3
44
+ if-no-files-found: "error"
45
+ compression-level: 0
46
+
47
+ #manylinux_aarch64:
48
+ #runs-on: ubuntu-24-arm
49
+ #timeout-minutes: 10
50
+ #steps:
51
+ #- uses: actions/checkout@v5
52
+
53
+ #- name: Pull the manylinux image
54
+ #run: docker pull quay.io/pypa/manylinux_2_28_aarch64
55
+
56
+ #- name: Build the wheel inside manylinux container
57
+ #run: |
58
+ #docker run --rm \
59
+ #-v ${{ github.workspace }}:/io \
60
+ #quay.io/pypa/manylinux_2_28_aarch64 \
61
+ #/io/build-wheels.sh
62
+
63
+ #- name: Install UV and test
64
+ #run: |
65
+ #curl -LsSf https://astral.sh/uv/install.sh | sh
66
+ #uv venv
67
+ #source .venv/bin/activate
68
+ #uv pip install pytest
69
+ #uv pip install ./dist/pygamlastan-*.whl
70
+ #pytest tests/ -vvv
71
+
72
+ #- name: Store wheels
73
+ #uses: actions/upload-artifact@v4
74
+ #with:
75
+ #name: pygamlastan_manylinux_aarch64
76
+ #path: dist/
77
+ #overwrite: true
78
+ #retention-days: 3
79
+ #if-no-files-found: "error"
80
+ #compression-level: 0
81
+
82
+ #macos_aarch64:
83
+ #runs-on: macos-15
84
+ #timeout-minutes: 10
85
+ #steps:
86
+ #- uses: actions/checkout@v5
87
+
88
+ #- uses: actions/setup-python@v6
89
+ #with:
90
+ #allow-prereleases: true
91
+ #python-version: "3.14"
92
+
93
+ #- uses: dtolnay/rust-toolchain@stable
94
+ #with:
95
+ #targets: "aarch64-apple-darwin"
96
+
97
+ #- name: Build environment
98
+ #run: |
99
+ #curl -LsSf https://astral.sh/uv/install.sh | sh
100
+ #uv venv --python python3.14
101
+ #source .venv/bin/activate
102
+ #uv pip install --upgrade "maturin>=1,<2" pytest
103
+
104
+ #- name: Build wheel
105
+ #run: |
106
+ #source .venv/bin/activate
107
+ #MACOSX_DEPLOYMENT_TARGET="11.0" \
108
+ #maturin build \
109
+ #--release \
110
+ #--strip \
111
+ #--interpreter python3.14 \
112
+ #--target=aarch64-apple-darwin
113
+
114
+ #- name: Run tests
115
+ #run: |
116
+ #source .venv/bin/activate
117
+ #uv pip install target/wheels/pygamlastan-*.whl
118
+ #pytest tests/ -vvv
119
+
120
+ #- name: Store wheels
121
+ #uses: actions/upload-artifact@v4
122
+ #with:
123
+ #name: pygamlastan_macos_aarch64
124
+ #path: target/wheels
125
+ #overwrite: true
126
+ #retention-days: 3
127
+ #if-no-files-found: "error"
128
+ #compression-level: 0
129
+
130
+ #windows_amd64:
131
+ #runs-on: windows-2025
132
+ #timeout-minutes: 10
133
+ #steps:
134
+ #- uses: actions/checkout@v5
135
+
136
+ #- uses: actions/setup-python@v6
137
+ #with:
138
+ #allow-prereleases: true
139
+ #python-version: "3.14"
140
+ #architecture: "x64"
141
+
142
+ #- uses: dtolnay/rust-toolchain@stable
143
+ #with:
144
+ #targets: "x86_64-pc-windows-msvc"
145
+
146
+ #- name: Build wheel
147
+ #run: |
148
+ #python.exe -m pip install --upgrade pip "maturin>=1,<2"
149
+ #maturin.exe build --release --strip --target=x86_64-pc-windows-msvc
150
+
151
+ #- name: Run tests
152
+ #shell: pwsh
153
+ #run: |
154
+ #python -m venv venv
155
+ #.\venv\Scripts\Activate.ps1
156
+ #pip install pytest
157
+ #pip install pygamlastan --no-index --find-links target\wheels
158
+ #pytest tests/ -vvv
159
+
160
+ #- name: Store wheels
161
+ #uses: actions/upload-artifact@v4
162
+ #with:
163
+ #name: pygamlastan_windows_amd64
164
+ #path: target\wheels
165
+ #overwrite: true
166
+ #retention-days: 3
167
+ #if-no-files-found: "error"
168
+ #compression-level: 0
169
+
170
+ #windows_aarch64:
171
+ #runs-on: windows-11-arm
172
+ #timeout-minutes: 10
173
+ #env:
174
+ #TARGET: "aarch64-pc-windows-msvc"
175
+ #steps:
176
+ #- uses: actions/checkout@v5
177
+
178
+ #- uses: actions/setup-python@v6
179
+ #with:
180
+ #allow-prereleases: true
181
+ #python-version: "3.14"
182
+ #architecture: "arm64"
183
+
184
+ #- shell: pwsh
185
+ #run: |
186
+ #Invoke-WebRequest -Uri "https://static.rust-lang.org/rustup/dist/$env:TARGET/rustup-init.exe" -OutFile rustup-init.exe
187
+ #.\rustup-init.exe --default-toolchain "stable-$env:TARGET" --profile minimal --component rust-src -y
188
+ #"$env:USERPROFILE\.cargo\bin" | Out-File -Append -Encoding ascii $env:GITHUB_PATH
189
+ #"CARGO_HOME=$env:USERPROFILE\.cargo" | Out-File -Append -Encoding ascii $env:GITHUB_ENV
190
+
191
+ #- name: Build wheel
192
+ #run: |
193
+ #python.exe -m pip install --upgrade pip "maturin>=1,<2"
194
+ #maturin.exe build --release --strip --target="$env:TARGET"
195
+
196
+ #- name: Run tests
197
+ #shell: pwsh
198
+ #run: |
199
+ #python -m venv venv
200
+ #.\venv\Scripts\Activate.ps1
201
+ #pip install pytest
202
+ #pip install pygamlastan --no-index --find-links target\wheels
203
+ #pytest tests/ -vvv
204
+
205
+ #- name: Store wheels
206
+ #uses: actions/upload-artifact@v4
207
+ #with:
208
+ #name: pygamlastan_windows_aarch64
209
+ #path: target\wheels
210
+ #overwrite: true
211
+ #retention-days: 3
212
+ #if-no-files-found: "error"
213
+ #compression-level: 0
214
+
215
+ publish:
216
+ runs-on: ubuntu-latest
217
+ needs: [manylinux_x86_64]
218
+ environment: pypi
219
+ permissions:
220
+ id-token: write
221
+ steps:
222
+ - name: Download all artifacts
223
+ uses: actions/download-artifact@v4
224
+ with:
225
+ path: dist
226
+ pattern: pygamlastan_*
227
+ merge-multiple: true
228
+
229
+ - name: List artifacts
230
+ run: ls -lR dist/
231
+
232
+ - name: Publish to PyPI
233
+ uses: pypa/gh-action-pypi-publish@release/v1
234
+ with:
235
+ packages-dir: dist/
@@ -0,0 +1,223 @@
1
+ target/
2
+ **/_build/
3
+ # Byte-compiled / optimized / DLL files
4
+ __pycache__/
5
+ *.py[codz]
6
+ *$py.class
7
+
8
+ # C extensions
9
+ *.so
10
+
11
+ # Distribution / packaging
12
+ .Python
13
+ build/
14
+ develop-eggs/
15
+ dist/
16
+ downloads/
17
+ eggs/
18
+ .eggs/
19
+ lib/
20
+ lib64/
21
+ parts/
22
+ sdist/
23
+ var/
24
+ wheels/
25
+ share/python-wheels/
26
+ *.egg-info/
27
+ .installed.cfg
28
+ *.egg
29
+ MANIFEST
30
+
31
+ # PyInstaller
32
+ # Usually these files are written by a python script from a template
33
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
34
+ *.manifest
35
+ *.spec
36
+
37
+ # Installer logs
38
+ pip-log.txt
39
+ pip-delete-this-directory.txt
40
+
41
+ # Unit test / coverage reports
42
+ htmlcov/
43
+ .tox/
44
+ .nox/
45
+ .coverage
46
+ .coverage.*
47
+ .cache
48
+ nosetests.xml
49
+ coverage.xml
50
+ *.cover
51
+ *.py.cover
52
+ *.lcov
53
+ .hypothesis/
54
+ .pytest_cache/
55
+ cover/
56
+
57
+ # Translations
58
+ *.mo
59
+ *.pot
60
+
61
+ # Django stuff:
62
+ *.log
63
+ local_settings.py
64
+ db.sqlite3
65
+ db.sqlite3-journal
66
+
67
+ # Flask stuff:
68
+ instance/
69
+ .webassets-cache
70
+
71
+ # Scrapy stuff:
72
+ .scrapy
73
+
74
+ # Sphinx documentation
75
+ docs/_build/
76
+
77
+ # PyBuilder
78
+ .pybuilder/
79
+ target/
80
+
81
+ # Jupyter Notebook
82
+ .ipynb_checkpoints
83
+
84
+ # IPython
85
+ profile_default/
86
+ ipython_config.py
87
+
88
+ # pyenv
89
+ # For a library or package, you might want to ignore these files since the code is
90
+ # intended to run in multiple environments; otherwise, check them in:
91
+ # .python-version
92
+
93
+ # pipenv
94
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
95
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
96
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
97
+ # install all needed dependencies.
98
+ # Pipfile.lock
99
+
100
+ # UV
101
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
102
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
103
+ # commonly ignored for libraries.
104
+ # uv.lock
105
+
106
+ # poetry
107
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
108
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
109
+ # commonly ignored for libraries.
110
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
111
+ # poetry.lock
112
+ # poetry.toml
113
+
114
+ # pdm
115
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
116
+ # pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
117
+ # https://pdm-project.org/en/latest/usage/project/#working-with-version-control
118
+ # pdm.lock
119
+ # pdm.toml
120
+ .pdm-python
121
+ .pdm-build/
122
+
123
+ # pixi
124
+ # Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
125
+ # pixi.lock
126
+ # Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
127
+ # in the .venv directory. It is recommended not to include this directory in version control.
128
+ .pixi/*
129
+ !.pixi/config.toml
130
+
131
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
132
+ __pypackages__/
133
+
134
+ # Celery stuff
135
+ celerybeat-schedule*
136
+ celerybeat.pid
137
+
138
+ # Redis
139
+ *.rdb
140
+ *.aof
141
+ *.pid
142
+
143
+ # RabbitMQ
144
+ mnesia/
145
+ rabbitmq/
146
+ rabbitmq-data/
147
+
148
+ # ActiveMQ
149
+ activemq-data/
150
+
151
+ # SageMath parsed files
152
+ *.sage.py
153
+
154
+ # Environments
155
+ .env
156
+ .envrc
157
+ .venv
158
+ env/
159
+ venv/
160
+ ENV/
161
+ env.bak/
162
+ venv.bak/
163
+
164
+ # Spyder project settings
165
+ .spyderproject
166
+ .spyproject
167
+
168
+ # Rope project settings
169
+ .ropeproject
170
+
171
+ # mkdocs documentation
172
+ /site
173
+
174
+ # mypy
175
+ .mypy_cache/
176
+ .dmypy.json
177
+ dmypy.json
178
+
179
+ # Pyre type checker
180
+ .pyre/
181
+
182
+ # pytype static type analyzer
183
+ .pytype/
184
+
185
+ # Cython debug symbols
186
+ cython_debug/
187
+
188
+ # PyCharm
189
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
190
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
191
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
192
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
193
+ # .idea/
194
+
195
+ # Abstra
196
+ # Abstra is an AI-powered process automation framework.
197
+ # Ignore directories containing user credentials, local state, and settings.
198
+ # Learn more at https://abstra.io/docs
199
+ .abstra/
200
+
201
+ # Visual Studio Code
202
+ # Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
203
+ # that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
204
+ # and can be added to the global gitignore or merged into this file. However, if you prefer,
205
+ # you could uncomment the following to ignore the entire vscode folder
206
+ # .vscode/
207
+ # Temporary file for partial code execution
208
+ tempCodeRunnerFile.py
209
+
210
+ # Ruff stuff:
211
+ .ruff_cache/
212
+
213
+ # PyPI configuration file
214
+ .pypirc
215
+
216
+ # Marimo
217
+ marimo/_static/
218
+ marimo/_lsp/
219
+ __marimo__/
220
+
221
+ # Streamlit
222
+ .streamlit/secrets.toml
223
+