ghosttrap-cli 0.3.24__tar.gz → 0.3.26__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.
- ghosttrap_cli-0.3.26/LICENSE +21 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/PKG-INFO +4 -1
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli/cli.py +2 -2
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli.egg-info/PKG-INFO +4 -1
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli.egg-info/SOURCES.txt +1 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/pyproject.toml +3 -2
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/README.md +0 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli/__init__.py +0 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli.egg-info/dependency_links.txt +0 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli.egg-info/entry_points.txt +0 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli.egg-info/requires.txt +0 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/ghosttrap_cli.egg-info/top_level.txt +0 -0
- {ghosttrap_cli-0.3.24 → ghosttrap_cli-0.3.26}/setup.cfg +0 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Alex Rowley
|
|
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.
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: ghosttrap-cli
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.26
|
|
4
4
|
Summary: Watch for errors streaming from ghosttrap.io
|
|
5
|
+
License-Expression: MIT
|
|
5
6
|
Project-URL: Homepage, https://github.com/alex-rowley/ghosttrap-cli
|
|
6
7
|
Requires-Python: >=3.10
|
|
7
8
|
Description-Content-Type: text/markdown
|
|
9
|
+
License-File: LICENSE
|
|
8
10
|
Requires-Dist: websockets>=12.0
|
|
11
|
+
Dynamic: license-file
|
|
9
12
|
|
|
10
13
|
# ghosttrap-cli
|
|
11
14
|
|
|
@@ -27,7 +27,7 @@ def _harden_signals():
|
|
|
27
27
|
except (OSError, ValueError):
|
|
28
28
|
pass
|
|
29
29
|
|
|
30
|
-
__version__ = "0.3.
|
|
30
|
+
__version__ = "0.3.26"
|
|
31
31
|
|
|
32
32
|
GHOSTTRAP_SERVER = "wss://ghosttrap.io/stream/"
|
|
33
33
|
CONFIG_DIR = os.path.expanduser("~/.ghosttrap")
|
|
@@ -75,7 +75,7 @@ Read `~/.ghosttrap/config.json` for state. It contains:
|
|
|
75
75
|
|
|
76
76
|
1. Detect the current repo from `git config --get remote.origin.url` (returns `owner/name`).
|
|
77
77
|
2. Find a matching entry in config by looking for one whose `owner`/`name` equals the detected slug. If no match, tell the user to run `ghosttrap setup`. (The owner/name on a config entry auto-refreshes from the server when the repo is renamed or transferred, so always match against the entry's stored owner/name, not the config key.)
|
|
78
|
-
3. If `sdk_installed` is false or missing: install the SDK (`pip install ghosttrap-sdk`), wire `ghosttrap.init("<token>")` into the app startup. For Django projects, also add `"ghosttrap.django.GhostTrapApp"` to INSTALLED_APPS (re-attaches logging handler after Django's dictConfig) and `"ghosttrap.django.GhostTrapMiddleware"` to MIDDLEWARE (catches unhandled view exceptions). The SDK auto-hooks into Celery task_failure if Celery is installed, and attaches a logging handler for logger.exception() calls. Use whatever pattern the project already uses for configuration (env vars, settings files, hardcoded — match the existing style). Then update the config: set `sdk_installed: true`, `sdk_version`, `init_file` to record what you did. Only pass `send_user=True` to `init()` if the user explicitly asks for user context in reports — it's PII and stays off by default.
|
|
78
|
+
3. If `sdk_installed` is false or missing: install the SDK (`pip install ghosttrap-sdk`), wire `ghosttrap.init("<token>")` into the app startup. For Django projects, also add `"ghosttrap.django.GhostTrapApp"` to INSTALLED_APPS (re-attaches logging handler after Django's dictConfig) and `"ghosttrap.django.GhostTrapMiddleware"` to MIDDLEWARE (catches unhandled view exceptions). The SDK auto-hooks into Celery task_failure if Celery is installed, catches unhandled exceptions in background threads (threading.excepthook), and attaches a logging handler for logger.exception() calls. Bare `logger.error(...)` calls with no exception are NOT reported unless the user explicitly asks — then pass `trap_logs=True` to `init()` (sdk >= 0.4.7); warn them that chatty codebases will flood. Use whatever pattern the project already uses for configuration (env vars, settings files, hardcoded — match the existing style). Then update the config: set `sdk_installed: true`, `sdk_version`, `init_file` to record what you did. Only pass `send_user=True` to `init()` if the user explicitly asks for user context in reports — it's PII and stays off by default.
|
|
79
79
|
4. Run `ghosttrap peek --clear` with `run_in_background: true`. The `--clear` flag skips any stale backlog from prior sessions so you only get fresh errors.
|
|
80
80
|
|
|
81
81
|
## Manual capture
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: ghosttrap-cli
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.26
|
|
4
4
|
Summary: Watch for errors streaming from ghosttrap.io
|
|
5
|
+
License-Expression: MIT
|
|
5
6
|
Project-URL: Homepage, https://github.com/alex-rowley/ghosttrap-cli
|
|
6
7
|
Requires-Python: >=3.10
|
|
7
8
|
Description-Content-Type: text/markdown
|
|
9
|
+
License-File: LICENSE
|
|
8
10
|
Requires-Dist: websockets>=12.0
|
|
11
|
+
Dynamic: license-file
|
|
9
12
|
|
|
10
13
|
# ghosttrap-cli
|
|
11
14
|
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
[build-system]
|
|
2
|
-
requires = ["setuptools>=
|
|
2
|
+
requires = ["setuptools>=77.0"]
|
|
3
3
|
build-backend = "setuptools.build_meta"
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "ghosttrap-cli"
|
|
7
|
-
version = "0.3.
|
|
7
|
+
version = "0.3.26"
|
|
8
8
|
description = "Watch for errors streaming from ghosttrap.io"
|
|
9
9
|
readme = "README.md"
|
|
10
|
+
license = "MIT"
|
|
10
11
|
requires-python = ">=3.10"
|
|
11
12
|
dependencies = [
|
|
12
13
|
"websockets>=12.0",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|