python-ulid 2.7.0__tar.gz → 3.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 (35) hide show
  1. python_ulid-3.1.0/.envrc +10 -0
  2. python_ulid-3.1.0/.github/workflows/lint-and-test.yml +113 -0
  3. {python_ulid-2.7.0 → python_ulid-3.1.0}/.gitignore +4 -2
  4. {python_ulid-2.7.0 → python_ulid-3.1.0}/.pre-commit-config.yaml +2 -2
  5. {python_ulid-2.7.0 → python_ulid-3.1.0}/.readthedocs.yml +1 -1
  6. python_ulid-3.1.0/.ruff_defaults.toml +545 -0
  7. {python_ulid-2.7.0 → python_ulid-3.1.0}/CHANGELOG.rst +39 -14
  8. {python_ulid-2.7.0 → python_ulid-3.1.0}/PKG-INFO +3 -2
  9. python_ulid-3.1.0/devbox.json +11 -0
  10. python_ulid-3.1.0/devbox.lock +178 -0
  11. {python_ulid-2.7.0 → python_ulid-3.1.0}/docs/source/conf.py +8 -8
  12. python_ulid-3.1.0/hatch.toml +40 -0
  13. {python_ulid-2.7.0 → python_ulid-3.1.0}/pyproject.toml +35 -5
  14. {python_ulid-2.7.0 → python_ulid-3.1.0}/tests/test_ulid.py +38 -5
  15. {python_ulid-2.7.0 → python_ulid-3.1.0}/ulid/__init__.py +107 -38
  16. {python_ulid-2.7.0 → python_ulid-3.1.0}/ulid/__main__.py +22 -18
  17. {python_ulid-2.7.0 → python_ulid-3.1.0}/ulid/base32.py +51 -59
  18. python_ulid-3.1.0/ulid/constants.py +21 -0
  19. python_ulid-3.1.0/uv.lock +1359 -0
  20. python_ulid-2.7.0/.github/workflows/lint-and-test.yml +0 -72
  21. python_ulid-2.7.0/hatch.toml +0 -32
  22. python_ulid-2.7.0/ulid/constants.py +0 -10
  23. {python_ulid-2.7.0 → python_ulid-3.1.0}/.github/workflows/publish.yml +0 -0
  24. {python_ulid-2.7.0 → python_ulid-3.1.0}/LICENSE +0 -0
  25. {python_ulid-2.7.0 → python_ulid-3.1.0}/README.rst +0 -0
  26. {python_ulid-2.7.0 → python_ulid-3.1.0}/docs/Makefile +0 -0
  27. {python_ulid-2.7.0 → python_ulid-3.1.0}/docs/requirements.txt +0 -0
  28. {python_ulid-2.7.0 → python_ulid-3.1.0}/docs/source/api.rst +0 -0
  29. {python_ulid-2.7.0 → python_ulid-3.1.0}/docs/source/changelog.rst +0 -0
  30. {python_ulid-2.7.0 → python_ulid-3.1.0}/docs/source/index.rst +0 -0
  31. {python_ulid-2.7.0 → python_ulid-3.1.0}/logo.png +0 -0
  32. {python_ulid-2.7.0 → python_ulid-3.1.0}/tests/__init__.py +0 -0
  33. {python_ulid-2.7.0 → python_ulid-3.1.0}/tests/test_base32.py +0 -0
  34. {python_ulid-2.7.0 → python_ulid-3.1.0}/tests/test_cli.py +0 -0
  35. {python_ulid-2.7.0 → python_ulid-3.1.0}/ulid/py.typed +0 -0
@@ -0,0 +1,10 @@
1
+ #!/bin/bash
2
+
3
+ # Automatically sets up your devbox environment whenever you cd into this
4
+ # directory via our direnv integration:
5
+
6
+ eval "$(devbox generate direnv --print-envrc)"
7
+ unset UV_PYTHON
8
+
9
+ # check out https://www.jetpack.io/devbox/docs/ide_configuration/direnv/
10
+ # for more details
@@ -0,0 +1,113 @@
1
+ name: lint-and-test
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ jobs:
10
+ lint-docs:
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - uses: actions/checkout@v5
14
+ - name: Set up Python 3.13
15
+ uses: actions/setup-python@v5
16
+ with:
17
+ python-version: "3.13"
18
+ - name: Install hatch
19
+ uses: pypa/hatch@install
20
+ - name: Lint documentation
21
+ run: hatch run docs:check
22
+
23
+ lint-code:
24
+ runs-on: ubuntu-latest
25
+ name: Lint code
26
+ steps:
27
+ - uses: actions/checkout@v5
28
+ - name: Set up Python 3.13
29
+ uses: actions/setup-python@v5
30
+ with:
31
+ python-version: "3.13"
32
+ - name: Install hatch
33
+ uses: pypa/hatch@install
34
+ - name: Lint code
35
+ run: hatch fmt --check
36
+
37
+ lint-typing:
38
+ runs-on: ubuntu-latest
39
+ name: Lint type annotations
40
+ steps:
41
+ - uses: actions/checkout@v5
42
+ - name: Set up Python 3.13
43
+ uses: actions/setup-python@v5
44
+ with:
45
+ python-version: "3.13"
46
+ - name: Install hatch
47
+ uses: pypa/hatch@install
48
+ - name: Lint typing
49
+ run: hatch run types:check
50
+
51
+ test:
52
+ runs-on: ubuntu-latest
53
+ name: Run tests
54
+ strategy:
55
+ matrix:
56
+ python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
57
+ steps:
58
+ - uses: actions/checkout@v5
59
+ - name: Set up Python ${{ matrix.python-version }}
60
+ uses: actions/setup-python@v5
61
+ with:
62
+ python-version: ${{ matrix.python-version }}
63
+
64
+ - name: Install hatch
65
+ uses: pypa/hatch@install
66
+
67
+ - name: Test
68
+ run: hatch test --cover --python ${{ matrix.python-version }}
69
+
70
+ - name: Disambiguate coverage filename
71
+ run: mv .coverage ".coverage.${{ matrix.os }}.${{ matrix.python-version }}"
72
+
73
+ - name: Upload coverage data
74
+ uses: actions/upload-artifact@v4
75
+ with:
76
+ include-hidden-files: true
77
+ name: coverage-${{ matrix.os }}-${{ matrix.python-version }}
78
+ path: .coverage*
79
+
80
+
81
+ coverage:
82
+ runs-on: ubuntu-latest
83
+ name: Report coverage
84
+ needs:
85
+ - test
86
+ steps:
87
+ - uses: actions/checkout@v5
88
+ - name: Install Hatch
89
+ uses: pypa/hatch@install
90
+
91
+ - name: Download coverage data
92
+ uses: actions/download-artifact@v4
93
+ with:
94
+ pattern: coverage-*
95
+ merge-multiple: true
96
+
97
+ - name: Combine coverage data
98
+ run: hatch run coverage:combine
99
+
100
+ - name: Export coverage reports
101
+ run: hatch run coverage:xml
102
+
103
+ - uses: codecov/codecov-action@v4
104
+ with:
105
+ token: ${{ secrets.CODECOV_TOKEN }}
106
+
107
+
108
+ package:
109
+ name: Build & verify package
110
+ runs-on: ubuntu-latest
111
+ steps:
112
+ - uses: actions/checkout@v5
113
+ - uses: hynek/build-and-inspect-python-package@v2
@@ -7,9 +7,11 @@ __pycache__
7
7
  /.cache
8
8
  /.eggs
9
9
  /.mypy_cache
10
+ /.pytest_cache
11
+ /.ruff_cache
12
+ /.devbox
13
+
10
14
  /coverage.xml
11
- /AUTHORS
12
- /ChangeLog
13
15
  /dist/
14
16
  /build/
15
17
  /docs/build
@@ -1,10 +1,10 @@
1
1
  repos:
2
2
  - repo: https://github.com/astral-sh/ruff-pre-commit
3
- rev: v0.3.3
3
+ rev: v0.12.9
4
4
  hooks:
5
5
  - id: ruff
6
6
  - id: ruff-format
7
7
  - repo: https://github.com/pycqa/doc8
8
- rev: v1.1.1
8
+ rev: v2.0.0
9
9
  hooks:
10
10
  - id: doc8
@@ -3,7 +3,7 @@ version: 2
3
3
  build:
4
4
  os: ubuntu-22.04
5
5
  tools:
6
- python: "3.11"
6
+ python: "3.13"
7
7
 
8
8
  sphinx:
9
9
  configuration: docs/source/conf.py
@@ -0,0 +1,545 @@
1
+ line-length = 120
2
+
3
+ [format]
4
+ docstring-code-format = true
5
+ docstring-code-line-length = 80
6
+
7
+ [lint]
8
+ select = [
9
+ "A001",
10
+ "A002",
11
+ "A003",
12
+ "ARG001",
13
+ "ARG002",
14
+ "ARG003",
15
+ "ARG004",
16
+ "ARG005",
17
+ "ASYNC100",
18
+ "B002",
19
+ "B003",
20
+ "B004",
21
+ "B005",
22
+ "B006",
23
+ "B007",
24
+ "B008",
25
+ "B009",
26
+ "B010",
27
+ "B011",
28
+ "B012",
29
+ "B013",
30
+ "B014",
31
+ "B015",
32
+ "B016",
33
+ "B017",
34
+ "B018",
35
+ "B019",
36
+ "B020",
37
+ "B021",
38
+ "B022",
39
+ "B023",
40
+ "B024",
41
+ "B025",
42
+ "B026",
43
+ "B028",
44
+ "B029",
45
+ "B030",
46
+ "B031",
47
+ "B032",
48
+ "B033",
49
+ "B034",
50
+ "B035",
51
+ "B904",
52
+ "B905",
53
+ "BLE001",
54
+ "C400",
55
+ "C401",
56
+ "C402",
57
+ "C403",
58
+ "C404",
59
+ "C405",
60
+ "C406",
61
+ "C408",
62
+ "C409",
63
+ "C410",
64
+ "C411",
65
+ "C413",
66
+ "C414",
67
+ "C415",
68
+ "C416",
69
+ "C417",
70
+ "C418",
71
+ "C419",
72
+ "COM818",
73
+ "DTZ001",
74
+ "DTZ002",
75
+ "DTZ003",
76
+ "DTZ004",
77
+ "DTZ005",
78
+ "DTZ006",
79
+ "DTZ007",
80
+ "DTZ011",
81
+ "DTZ012",
82
+ "E101",
83
+ "E401",
84
+ "E402",
85
+ "E701",
86
+ "E702",
87
+ "E703",
88
+ "E711",
89
+ "E712",
90
+ "E713",
91
+ "E714",
92
+ "E721",
93
+ "E722",
94
+ "E731",
95
+ "E741",
96
+ "E742",
97
+ "E743",
98
+ "E902",
99
+ "EM101",
100
+ "EM102",
101
+ "EM103",
102
+ "EXE001",
103
+ "EXE002",
104
+ "EXE003",
105
+ "EXE004",
106
+ "EXE005",
107
+ "F401",
108
+ "F402",
109
+ "F403",
110
+ "F404",
111
+ "F405",
112
+ "F406",
113
+ "F407",
114
+ "F501",
115
+ "F502",
116
+ "F503",
117
+ "F504",
118
+ "F505",
119
+ "F506",
120
+ "F507",
121
+ "F508",
122
+ "F509",
123
+ "F521",
124
+ "F522",
125
+ "F523",
126
+ "F524",
127
+ "F525",
128
+ "F541",
129
+ "F601",
130
+ "F602",
131
+ "F621",
132
+ "F622",
133
+ "F631",
134
+ "F632",
135
+ "F633",
136
+ "F634",
137
+ "F701",
138
+ "F702",
139
+ "F704",
140
+ "F706",
141
+ "F707",
142
+ "F722",
143
+ "F811",
144
+ "F821",
145
+ "F822",
146
+ "F823",
147
+ "F841",
148
+ "F842",
149
+ "F901",
150
+ "FA100",
151
+ "FA102",
152
+ "FBT001",
153
+ "FBT002",
154
+ "FLY002",
155
+ "G001",
156
+ "G002",
157
+ "G003",
158
+ "G004",
159
+ "G010",
160
+ "G101",
161
+ "G201",
162
+ "G202",
163
+ "I001",
164
+ "I002",
165
+ "ICN001",
166
+ "ICN002",
167
+ "ICN003",
168
+ "INP001",
169
+ "INT001",
170
+ "INT002",
171
+ "INT003",
172
+ "ISC003",
173
+ "LOG001",
174
+ "LOG002",
175
+ "LOG007",
176
+ "LOG009",
177
+ "N801",
178
+ "N802",
179
+ "N803",
180
+ "N804",
181
+ "N805",
182
+ "N806",
183
+ "N807",
184
+ "N811",
185
+ "N812",
186
+ "N813",
187
+ "N814",
188
+ "N815",
189
+ "N816",
190
+ "N817",
191
+ "N818",
192
+ "N999",
193
+ "PERF101",
194
+ "PERF102",
195
+ "PERF401",
196
+ "PERF402",
197
+ "PGH005",
198
+ "PIE790",
199
+ "PIE794",
200
+ "PIE796",
201
+ "PIE800",
202
+ "PIE804",
203
+ "PIE807",
204
+ "PIE808",
205
+ "PIE810",
206
+ "PLC0105",
207
+ "PLC0131",
208
+ "PLC0132",
209
+ "PLC0205",
210
+ "PLC0208",
211
+ "PLC0414",
212
+ "PLC3002",
213
+ "PLE0100",
214
+ "PLE0101",
215
+ "PLE0116",
216
+ "PLE0117",
217
+ "PLE0118",
218
+ "PLE0237",
219
+ "PLE0241",
220
+ "PLE0302",
221
+ "PLE0307",
222
+ "PLE0604",
223
+ "PLE0605",
224
+ "PLE1142",
225
+ "PLE1205",
226
+ "PLE1206",
227
+ "PLE1300",
228
+ "PLE1307",
229
+ "PLE1310",
230
+ "PLE1507",
231
+ "PLE1700",
232
+ "PLE2502",
233
+ "PLE2510",
234
+ "PLE2512",
235
+ "PLE2513",
236
+ "PLE2514",
237
+ "PLE2515",
238
+ "PLR0124",
239
+ "PLR0133",
240
+ "PLR0206",
241
+ "PLR0402",
242
+ "PLR1711",
243
+ "PLR1714",
244
+ "PLR1722",
245
+ "PLR2004",
246
+ "PLR5501",
247
+ "PLW0120",
248
+ "PLW0127",
249
+ "PLW0129",
250
+ "PLW0131",
251
+ "PLW0406",
252
+ "PLW0602",
253
+ "PLW0603",
254
+ "PLW0711",
255
+ "PLW1508",
256
+ "PLW1509",
257
+ "PLW1510",
258
+ "PLW2901",
259
+ "PLW3301",
260
+ "PT001",
261
+ "PT002",
262
+ "PT003",
263
+ "PT006",
264
+ "PT007",
265
+ "PT008",
266
+ "PT009",
267
+ "PT010",
268
+ "PT011",
269
+ "PT012",
270
+ "PT013",
271
+ "PT014",
272
+ "PT015",
273
+ "PT016",
274
+ "PT017",
275
+ "PT018",
276
+ "PT019",
277
+ "PT020",
278
+ "PT021",
279
+ "PT022",
280
+ "PT023",
281
+ "PT024",
282
+ "PT025",
283
+ "PT026",
284
+ "PT027",
285
+ "PYI001",
286
+ "PYI002",
287
+ "PYI003",
288
+ "PYI004",
289
+ "PYI005",
290
+ "PYI006",
291
+ "PYI007",
292
+ "PYI008",
293
+ "PYI009",
294
+ "PYI010",
295
+ "PYI011",
296
+ "PYI012",
297
+ "PYI013",
298
+ "PYI014",
299
+ "PYI015",
300
+ "PYI016",
301
+ "PYI017",
302
+ "PYI018",
303
+ "PYI019",
304
+ "PYI020",
305
+ "PYI021",
306
+ "PYI024",
307
+ "PYI025",
308
+ "PYI026",
309
+ "PYI029",
310
+ "PYI030",
311
+ "PYI032",
312
+ "PYI033",
313
+ "PYI034",
314
+ "PYI035",
315
+ "PYI036",
316
+ "PYI041",
317
+ "PYI042",
318
+ "PYI043",
319
+ "PYI044",
320
+ "PYI045",
321
+ "PYI046",
322
+ "PYI047",
323
+ "PYI048",
324
+ "PYI049",
325
+ "PYI050",
326
+ "PYI051",
327
+ "PYI052",
328
+ "PYI053",
329
+ "PYI054",
330
+ "PYI055",
331
+ "PYI056",
332
+ "PYI058",
333
+ "RET503",
334
+ "RET504",
335
+ "RET505",
336
+ "RET506",
337
+ "RET507",
338
+ "RET508",
339
+ "RSE102",
340
+ "RUF001",
341
+ "RUF002",
342
+ "RUF003",
343
+ "RUF005",
344
+ "RUF006",
345
+ "RUF007",
346
+ "RUF008",
347
+ "RUF009",
348
+ "RUF010",
349
+ "RUF012",
350
+ "RUF013",
351
+ "RUF015",
352
+ "RUF016",
353
+ "RUF017",
354
+ "RUF018",
355
+ "RUF019",
356
+ "RUF020",
357
+ "RUF100",
358
+ "S101",
359
+ "S102",
360
+ "S103",
361
+ "S104",
362
+ "S105",
363
+ "S106",
364
+ "S107",
365
+ "S108",
366
+ "S110",
367
+ "S112",
368
+ "S113",
369
+ "S201",
370
+ "S202",
371
+ "S301",
372
+ "S302",
373
+ "S303",
374
+ "S304",
375
+ "S305",
376
+ "S306",
377
+ "S307",
378
+ "S308",
379
+ "S310",
380
+ "S311",
381
+ "S312",
382
+ "S313",
383
+ "S314",
384
+ "S315",
385
+ "S316",
386
+ "S317",
387
+ "S318",
388
+ "S319",
389
+ "S321",
390
+ "S323",
391
+ "S324",
392
+ "S501",
393
+ "S502",
394
+ "S503",
395
+ "S504",
396
+ "S505",
397
+ "S506",
398
+ "S507",
399
+ "S508",
400
+ "S509",
401
+ "S601",
402
+ "S602",
403
+ "S604",
404
+ "S605",
405
+ "S606",
406
+ "S607",
407
+ "S608",
408
+ "S609",
409
+ "S611",
410
+ "S612",
411
+ "S701",
412
+ "S702",
413
+ "SIM101",
414
+ "SIM102",
415
+ "SIM103",
416
+ "SIM105",
417
+ "SIM107",
418
+ "SIM108",
419
+ "SIM109",
420
+ "SIM110",
421
+ "SIM112",
422
+ "SIM113",
423
+ "SIM114",
424
+ "SIM115",
425
+ "SIM116",
426
+ "SIM117",
427
+ "SIM118",
428
+ "SIM201",
429
+ "SIM202",
430
+ "SIM208",
431
+ "SIM210",
432
+ "SIM211",
433
+ "SIM212",
434
+ "SIM220",
435
+ "SIM221",
436
+ "SIM222",
437
+ "SIM223",
438
+ "SIM300",
439
+ "SIM910",
440
+ "SIM911",
441
+ "SLF001",
442
+ "SLOT000",
443
+ "SLOT001",
444
+ "SLOT002",
445
+ "T100",
446
+ "T201",
447
+ "T203",
448
+ "TC001",
449
+ "TC002",
450
+ "TC003",
451
+ "TC004",
452
+ "TC005",
453
+ "TC010",
454
+ "TD004",
455
+ "TD005",
456
+ "TD006",
457
+ "TD007",
458
+ "TID251",
459
+ "TID252",
460
+ "TID253",
461
+ "TRY002",
462
+ "TRY003",
463
+ "TRY004",
464
+ "TRY201",
465
+ "TRY203",
466
+ "TRY300",
467
+ "TRY301",
468
+ "TRY400",
469
+ "TRY401",
470
+ "UP001",
471
+ "UP003",
472
+ "UP004",
473
+ "UP005",
474
+ "UP006",
475
+ "UP007",
476
+ "UP008",
477
+ "UP009",
478
+ "UP010",
479
+ "UP011",
480
+ "UP012",
481
+ "UP013",
482
+ "UP014",
483
+ "UP015",
484
+ "UP017",
485
+ "UP018",
486
+ "UP019",
487
+ "UP020",
488
+ "UP021",
489
+ "UP022",
490
+ "UP023",
491
+ "UP024",
492
+ "UP025",
493
+ "UP026",
494
+ "UP028",
495
+ "UP029",
496
+ "UP030",
497
+ "UP031",
498
+ "UP032",
499
+ "UP033",
500
+ "UP034",
501
+ "UP035",
502
+ "UP036",
503
+ "UP037",
504
+ "UP039",
505
+ "UP040",
506
+ "UP041",
507
+ "W291",
508
+ "W292",
509
+ "W293",
510
+ "W505",
511
+ "W605",
512
+ "YTT101",
513
+ "YTT102",
514
+ "YTT103",
515
+ "YTT201",
516
+ "YTT202",
517
+ "YTT203",
518
+ "YTT204",
519
+ "YTT301",
520
+ "YTT302",
521
+ "YTT303",
522
+ ]
523
+
524
+ [lint.per-file-ignores]
525
+ "**/scripts/*" = [
526
+ "INP001",
527
+ "T201",
528
+ ]
529
+ "**/tests/**/*" = [
530
+ "PLC1901",
531
+ "PLR2004",
532
+ "PLR6301",
533
+ "S",
534
+ "TID252",
535
+ ]
536
+
537
+ [lint.flake8-tidy-imports]
538
+ ban-relative-imports = "all"
539
+
540
+ [lint.isort]
541
+ known-first-party = ["python_ulid"]
542
+
543
+ [lint.flake8-pytest-style]
544
+ fixture-parentheses = false
545
+ mark-parentheses = false