py-juxlib 0.3.3__tar.gz → 0.3.4__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.
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/.gitignore +0 -1
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/PKG-INFO +2 -5
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/README.md +1 -4
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/pyproject.toml +1 -1
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/config/manager.py +17 -6
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/LICENSE +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/api/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/api/client.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/api/models.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/config/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/config/schema.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/errors/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/errors/codes.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/errors/exceptions.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/metadata/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/metadata/ci.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/metadata/detection.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/metadata/git.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/metadata/models.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/metadata/project.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/py.typed +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/signing/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/signing/keys.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/signing/signer.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/signing/verifier.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/signing/xml.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/storage/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/src/juxlib/storage/filesystem.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/conftest.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/generate-test-certs.sh +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/sample-report.xml +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/test-cert.pem +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/test-ec-cert.pem +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/test-ec-private.pem +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/fixtures/test-private.pem +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/integration/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/integration/test_config_storage.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/integration/test_e2e_workflow.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/test_version.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/__init__.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/test_api_client.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/test_config.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/test_errors.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/test_metadata.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/test_signing.py +0 -0
- {py_juxlib-0.3.3 → py_juxlib-0.3.4}/tests/unit/test_storage.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: py-juxlib
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.4
|
|
4
4
|
Summary: Shared Python library for Jux tools ecosystem
|
|
5
5
|
Project-URL: Homepage, https://github.com/jux-tools/py-juxlib
|
|
6
6
|
Project-URL: Documentation, https://github.com/jux-tools/py-juxlib#readme
|
|
@@ -108,10 +108,7 @@ with open("junit-report-signed.xml", "wb") as f:
|
|
|
108
108
|
```python
|
|
109
109
|
from juxlib.api import JuxAPIClient
|
|
110
110
|
|
|
111
|
-
client = JuxAPIClient(
|
|
112
|
-
api_url="https://jux.example.com",
|
|
113
|
-
bearer_token="your-token"
|
|
114
|
-
)
|
|
111
|
+
client = JuxAPIClient(api_url="https://jux.example.com", bearer_token="your-token")
|
|
115
112
|
|
|
116
113
|
with open("junit-report-signed.xml") as f:
|
|
117
114
|
response = client.publish_report(f.read())
|
|
@@ -64,10 +64,7 @@ with open("junit-report-signed.xml", "wb") as f:
|
|
|
64
64
|
```python
|
|
65
65
|
from juxlib.api import JuxAPIClient
|
|
66
66
|
|
|
67
|
-
client = JuxAPIClient(
|
|
68
|
-
api_url="https://jux.example.com",
|
|
69
|
-
bearer_token="your-token"
|
|
70
|
-
)
|
|
67
|
+
client = JuxAPIClient(api_url="https://jux.example.com", bearer_token="your-token")
|
|
71
68
|
|
|
72
69
|
with open("junit-report-signed.xml") as f:
|
|
73
70
|
response = client.publish_report(f.read())
|
|
@@ -25,16 +25,27 @@ class ConfigValidationError(Exception):
|
|
|
25
25
|
"""Raised when configuration validation fails."""
|
|
26
26
|
|
|
27
27
|
|
|
28
|
+
def _is_macos() -> bool:
|
|
29
|
+
"""Return True on macOS.
|
|
30
|
+
|
|
31
|
+
A function rather than an inline ``sys.platform`` check: mypy narrows on
|
|
32
|
+
``sys.platform`` for the platform it runs on, so an inline check made the
|
|
33
|
+
other branch unreachable on one OS and its ``type: ignore`` unused on the
|
|
34
|
+
other.
|
|
35
|
+
"""
|
|
36
|
+
return sys.platform == "darwin"
|
|
37
|
+
|
|
38
|
+
|
|
28
39
|
def get_xdg_config_home() -> Path:
|
|
29
40
|
"""Get XDG config home directory.
|
|
30
41
|
|
|
31
42
|
Returns:
|
|
32
43
|
Path to config directory (~/.config on Linux, ~/Library/Application Support on macOS)
|
|
33
44
|
"""
|
|
34
|
-
if
|
|
45
|
+
if _is_macos():
|
|
35
46
|
return Path.home() / "Library" / "Application Support"
|
|
36
|
-
# Linux/other platforms
|
|
37
|
-
xdg_config = os.environ.get("XDG_CONFIG_HOME")
|
|
47
|
+
# Linux/other platforms
|
|
48
|
+
xdg_config = os.environ.get("XDG_CONFIG_HOME")
|
|
38
49
|
if xdg_config:
|
|
39
50
|
return Path(xdg_config)
|
|
40
51
|
return Path.home() / ".config"
|
|
@@ -46,10 +57,10 @@ def get_xdg_data_home() -> Path:
|
|
|
46
57
|
Returns:
|
|
47
58
|
Path to data directory (~/.local/share on Linux, ~/Library/Application Support on macOS)
|
|
48
59
|
"""
|
|
49
|
-
if
|
|
60
|
+
if _is_macos():
|
|
50
61
|
return Path.home() / "Library" / "Application Support"
|
|
51
|
-
# Linux/other platforms
|
|
52
|
-
xdg_data = os.environ.get("XDG_DATA_HOME")
|
|
62
|
+
# Linux/other platforms
|
|
63
|
+
xdg_data = os.environ.get("XDG_DATA_HOME")
|
|
53
64
|
if xdg_data:
|
|
54
65
|
return Path(xdg_data)
|
|
55
66
|
return Path.home() / ".local" / "share"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|