tokensafe 4.3.0 → 4.3.1
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.
- package/.codex-plugin/plugin.json +1 -1
- package/kimi.plugin.json +1 -1
- package/package.json +1 -1
- package/plugin.json +1 -1
- package/server.json +3 -3
- package/src/cli.py +2 -1
- package/src/installer.py +11 -4
- package/src/mcp_server.py +1 -1
- package/src/telemetry_sync.py +1 -1
- package/src/version_checker.py +1 -1
package/kimi.plugin.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tokensafe",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.1",
|
|
4
4
|
"description": "Your AI agent is smart enough to code all day. Now it actually can. Local runtime firewall & zero-loss context optimizer for AI coding agents.",
|
|
5
5
|
"homepage": "https://tokensafe.dev",
|
|
6
6
|
"license": "MIT",
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tokensafe",
|
|
3
3
|
"mcpName": "dev.tokensafe/tokensafe",
|
|
4
|
-
"version": "4.3.
|
|
4
|
+
"version": "4.3.1",
|
|
5
5
|
"description": "Your AI agent is smart enough to code all day. Now it actually can. Local runtime firewall & zero-loss context optimizer for AI coding agents.",
|
|
6
6
|
"main": "bin/tokensafe.js",
|
|
7
7
|
"bin": {
|
package/plugin.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tokensafe",
|
|
3
3
|
"displayName": "TokenSafe",
|
|
4
|
-
"version": "4.3.
|
|
4
|
+
"version": "4.3.1",
|
|
5
5
|
"description": "Your AI agent is smart enough to code all day. Now it actually can. Local runtime firewall & zero-loss context optimizer for AI coding agents.",
|
|
6
6
|
"logo": "assets/logo.png",
|
|
7
7
|
"developerName": "TokenSafe",
|
package/server.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"name": "dev.tokensafe/tokensafe",
|
|
4
4
|
"title": "TokenSafe",
|
|
5
5
|
"description": "Your AI agent is smart enough to code all day. Local firewall & zero-loss runtime.",
|
|
6
|
-
"version": "4.3.
|
|
6
|
+
"version": "4.3.1",
|
|
7
7
|
"websiteUrl": "https://tokensafe.dev",
|
|
8
8
|
"repository": {
|
|
9
9
|
"url": "https://github.com/tokensafe-dev/tokensafe",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"registryType": "npm",
|
|
24
24
|
"registryBaseUrl": "https://registry.npmjs.org",
|
|
25
25
|
"identifier": "tokensafe",
|
|
26
|
-
"version": "4.3.
|
|
26
|
+
"version": "4.3.1",
|
|
27
27
|
"runtimeHint": "npx",
|
|
28
28
|
"transport": {
|
|
29
29
|
"type": "stdio"
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"registryType": "pypi",
|
|
40
40
|
"registryBaseUrl": "https://pypi.org",
|
|
41
41
|
"identifier": "tokensafe",
|
|
42
|
-
"version": "4.3.
|
|
42
|
+
"version": "4.3.1",
|
|
43
43
|
"runtimeHint": "uvx",
|
|
44
44
|
"transport": {
|
|
45
45
|
"type": "stdio"
|
package/src/cli.py
CHANGED
|
@@ -405,7 +405,8 @@ def main(argv: Optional[List[str]] = None):
|
|
|
405
405
|
status = "\033[32m✔\033[0m" if r["success"] else "\033[31m✖\033[0m"
|
|
406
406
|
print(f" {status} \033[1m{r['name']:<28}\033[0m: {r['message']}")
|
|
407
407
|
print(f"\n\033[32m✔ Universal project rules injected into: {', '.join(res['project_rules'])}\033[0m\n")
|
|
408
|
-
|
|
408
|
+
# Proxy default-on is asserted INSIDE install_all (_ensure_proxy_default);
|
|
409
|
+
# the retired interactive prompt must never be referenced here again.
|
|
409
410
|
elif "--project" in args:
|
|
410
411
|
agents_plugin = None
|
|
411
412
|
if "--agents-plugin" in args:
|
package/src/installer.py
CHANGED
|
@@ -306,16 +306,23 @@ class AgentInstaller:
|
|
|
306
306
|
if not isinstance(entries, list):
|
|
307
307
|
hooks[event_name] = [default_entry]
|
|
308
308
|
return True
|
|
309
|
+
default_matcher = str(default_entry.get("matcher") or "")
|
|
309
310
|
seen = False
|
|
310
311
|
dirty = False
|
|
311
312
|
for entry in entries:
|
|
312
313
|
if isinstance(entry, dict) and isinstance(entry.get("hooks"), list):
|
|
313
314
|
for h in entry["hooks"]:
|
|
314
315
|
if isinstance(h, dict) and "claude_code_hook.py" in str(h.get("command", "")):
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
316
|
+
# Matcher-aware sync: a legacy entry with a
|
|
317
|
+
# DIFFERENT matcher covers only its own tool
|
|
318
|
+
# set (e.g. PostToolUse "Write|Edit|MultiEdit"
|
|
319
|
+
# never fires for Read), so the canonical
|
|
320
|
+
# default entry must still be appended.
|
|
321
|
+
if str(entry.get("matcher") or "") == default_matcher:
|
|
322
|
+
seen = True
|
|
323
|
+
if h.get("command") != claude_cmd:
|
|
324
|
+
h["command"] = claude_cmd
|
|
325
|
+
dirty = True
|
|
319
326
|
if not seen:
|
|
320
327
|
entries.append(default_entry)
|
|
321
328
|
dirty = True
|
package/src/mcp_server.py
CHANGED
package/src/telemetry_sync.py
CHANGED
|
@@ -241,7 +241,7 @@ class TelemetrySync:
|
|
|
241
241
|
current_last_id = last_id
|
|
242
242
|
headers = {
|
|
243
243
|
"Content-Type": "application/json",
|
|
244
|
-
"User-Agent": "TokenSafe-Sync/4.3.
|
|
244
|
+
"User-Agent": "TokenSafe-Sync/4.3.1"
|
|
245
245
|
}
|
|
246
246
|
if active_key:
|
|
247
247
|
headers["Authorization"] = f"Bearer {active_key}"
|
package/src/version_checker.py
CHANGED
|
@@ -17,7 +17,7 @@ import urllib.request
|
|
|
17
17
|
import urllib.error
|
|
18
18
|
from typing import Dict, Any, Optional, Tuple
|
|
19
19
|
|
|
20
|
-
CURRENT_VERSION = "4.3.
|
|
20
|
+
CURRENT_VERSION = "4.3.1"
|
|
21
21
|
CACHE_TTL = 86400 # 24 hours
|
|
22
22
|
# When the cloud is unreachable we must NOT cache the synthesized "up to date"
|
|
23
23
|
# answer for a full day — otherwise an update released right after an outage
|