pushary 1.9.69 → 1.9.71

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 (123) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/{api-KUJYE5YZ.js → api-HEIRLMTZ.js} +10 -10
  3. package/dist/bin/pushary-bell-hook.js +25 -25
  4. package/dist/bin/pushary-bell.js +10 -10
  5. package/dist/bin/pushary-claude.js +26 -26
  6. package/dist/bin/pushary-clean.js +33 -33
  7. package/dist/bin/pushary-codex-bridge.js +21 -21
  8. package/dist/bin/pushary-codex-hook.js +30 -30
  9. package/dist/bin/pushary-codex-session.js +8 -8
  10. package/dist/bin/pushary-codex.js +13 -13
  11. package/dist/bin/pushary-connect.js +26 -26
  12. package/dist/bin/pushary-cowork.js +5 -5
  13. package/dist/bin/pushary-daemon.js +38 -38
  14. package/dist/bin/pushary-disconnect.js +25 -25
  15. package/dist/bin/pushary-doctor.js +41 -41
  16. package/dist/bin/pushary-elicitation-hook.js +25 -25
  17. package/dist/bin/pushary-gemini-bridge.js +15 -15
  18. package/dist/bin/pushary-gemini-hook.js +27 -27
  19. package/dist/bin/pushary-hook.js +29 -29
  20. package/dist/bin/pushary-login.js +20 -20
  21. package/dist/bin/pushary-logout.js +24 -24
  22. package/dist/bin/pushary-mcp.js +11 -11
  23. package/dist/bin/pushary-mode.js +15 -15
  24. package/dist/bin/pushary-notification-hook.js +24 -24
  25. package/dist/bin/pushary-opencode-hook.js +26 -26
  26. package/dist/bin/pushary-permission-denied-hook.js +29 -29
  27. package/dist/bin/pushary-permission-hook.js +29 -29
  28. package/dist/bin/pushary-post-hook.js +24 -24
  29. package/dist/bin/pushary-prompt-hook.js +24 -24
  30. package/dist/bin/pushary-session-end-hook.js +26 -26
  31. package/dist/bin/pushary-session-start-hook.js +34 -34
  32. package/dist/bin/pushary-setup.js +45 -45
  33. package/dist/bin/pushary-stats.js +5 -5
  34. package/dist/bin/pushary-status.js +31 -31
  35. package/dist/bin/pushary-stop-hook.js +24 -24
  36. package/dist/bin/pushary-stopfailure-hook.js +24 -24
  37. package/dist/bin/pushary-suggestions.js +15 -15
  38. package/dist/bin/pushary-transcript-register.js +16 -16
  39. package/dist/bin/pushary-transcripts.js +18 -18
  40. package/dist/bin/pushary-upgrade.js +39 -39
  41. package/dist/bin/pushary-wait.js +15 -15
  42. package/dist/bin/pushary.js +7 -7
  43. package/dist/{chunk-KVXX5M5A.js → chunk-25W6AD3W.js} +6 -6
  44. package/dist/{chunk-SCKZVTFV.js → chunk-2XD4TTUM.js} +10 -10
  45. package/dist/{chunk-SKTZKAGH.js → chunk-3CN2EFKK.js} +1 -1
  46. package/dist/{chunk-XZKSUJ55.js → chunk-3FY5ZPIZ.js} +1 -1
  47. package/dist/{chunk-7FWZNWIO.js → chunk-4QPF4BGP.js} +6 -6
  48. package/dist/{chunk-3HWDWR42.js → chunk-4XFFGFHN.js} +13 -13
  49. package/dist/{chunk-HZNZJTGH.js → chunk-5NQ3SMVP.js} +9 -9
  50. package/dist/{chunk-VKZ3RJ5U.js → chunk-5WHSFMV2.js} +1 -1
  51. package/dist/{chunk-Z3FMJ567.js → chunk-6W2ASRZO.js} +38 -48
  52. package/dist/{chunk-EAJUFO7Q.js → chunk-7OYWCOVC.js} +4 -4
  53. package/dist/{chunk-METUT7V4.js → chunk-AERRQEWZ.js} +2 -2
  54. package/dist/{chunk-72ILLFCY.js → chunk-AN26S5DC.js} +6 -6
  55. package/dist/{chunk-OYFGZARB.js → chunk-AUOVB62W.js} +3 -3
  56. package/dist/{chunk-X2MTVD4W.js → chunk-AZ56FPRG.js} +1 -1
  57. package/dist/{chunk-PK6WI4HH.js → chunk-B3KPRSCM.js} +5 -5
  58. package/dist/{chunk-YSOZVBFW.js → chunk-BJRLJJS2.js} +1 -1
  59. package/dist/{chunk-UC2J5RR4.js → chunk-BZ7XGS5L.js} +1 -1
  60. package/dist/{chunk-2REVIFLS.js → chunk-C3YAMEO2.js} +2 -2
  61. package/dist/{chunk-GZHQQP7J.js → chunk-D536PHXF.js} +4 -4
  62. package/dist/{chunk-SSJDAX4E.js → chunk-DOMDCMGC.js} +5 -5
  63. package/dist/{chunk-C4EDAHXI.js → chunk-EBOGB7JR.js} +1 -1
  64. package/dist/{chunk-ZK5WYAMI.js → chunk-EVJRITSI.js} +1 -1
  65. package/dist/{chunk-7XS44DQX.js → chunk-EZHM6I2V.js} +4 -4
  66. package/dist/{chunk-7CW63ZK3.js → chunk-FA6INGK7.js} +3 -3
  67. package/dist/{chunk-QZPRCMPV.js → chunk-FTOKESSK.js} +1 -1
  68. package/dist/{chunk-TXRV7AOA.js → chunk-G3J5JKEJ.js} +6 -6
  69. package/dist/{chunk-VIQ5OS5E.js → chunk-GIE7PLZD.js} +4 -4
  70. package/dist/{chunk-WOJW23ZD.js → chunk-HR6M44CX.js} +7 -7
  71. package/dist/{chunk-4BXI6WJI.js → chunk-IPSO7DUB.js} +3 -3
  72. package/dist/{chunk-JWRDCANS.js → chunk-ITKAMUHG.js} +3 -3
  73. package/dist/{chunk-N2WAXSJY.js → chunk-IYMYGKFB.js} +9 -9
  74. package/dist/{chunk-AUYMNTUX.js → chunk-J7BLYQ7Z.js} +4 -4
  75. package/dist/{chunk-PIGBU7D3.js → chunk-JEZGDP55.js} +5 -5
  76. package/dist/{chunk-RQOT6QL3.js → chunk-JGEPODEP.js} +453 -16
  77. package/dist/{chunk-QE22XDUK.js → chunk-JMACQEPU.js} +2 -2
  78. package/dist/{chunk-5UIA5GLL.js → chunk-KGZH5RTB.js} +6 -6
  79. package/dist/{chunk-NWN6GGJL.js → chunk-LA3MMHLO.js} +2 -2
  80. package/dist/{chunk-YAA6MT6O.js → chunk-LKAO35SY.js} +3 -3
  81. package/dist/{chunk-VHMZPN3N.js → chunk-LKKIFFUC.js} +1 -1
  82. package/dist/{chunk-NSR6IFA6.js → chunk-LMP2FAS6.js} +3 -3
  83. package/dist/{chunk-DJPNVVJQ.js → chunk-LRS4TJU2.js} +4 -4
  84. package/dist/{chunk-FZ2SHXUE.js → chunk-LWAYXE7G.js} +2 -2
  85. package/dist/{chunk-CPYVVEJP.js → chunk-MGF7D2ZL.js} +6 -6
  86. package/dist/{chunk-CJ3W7XRU.js → chunk-MZ6GL46A.js} +1 -1
  87. package/dist/{chunk-AVKD5QS4.js → chunk-NHC5YUH6.js} +5 -5
  88. package/dist/{chunk-GMHQYX3D.js → chunk-NPO3ZTR4.js} +1 -1
  89. package/dist/{chunk-FULXDMAP.js → chunk-OJFOIKRM.js} +3 -3
  90. package/dist/{chunk-D5G2HSQ6.js → chunk-ONZ3UGNY.js} +2 -2
  91. package/dist/{chunk-5LQCADHK.js → chunk-QSZQCKPB.js} +5 -5
  92. package/dist/{chunk-N2FDORN6.js → chunk-QWCOMSDH.js} +3 -3
  93. package/dist/{chunk-274CV7IW.js → chunk-SMIU5URV.js} +2 -2
  94. package/dist/{chunk-BRWU4NT4.js → chunk-SWQTCKLM.js} +6 -6
  95. package/dist/{chunk-OXOYS3UG.js → chunk-T7FPZN5V.js} +3 -3
  96. package/dist/{chunk-DTENGECG.js → chunk-TATE22GH.js} +1 -1
  97. package/dist/{chunk-XLKO2XEG.js → chunk-VMQEB56V.js} +2 -2
  98. package/dist/{chunk-LWFSXSRG.js → chunk-VSQDVH43.js} +1 -1
  99. package/dist/{chunk-NFWZVY25.js → chunk-WOZLV3LN.js} +4 -4
  100. package/dist/{chunk-32OSSYGZ.js → chunk-X2KK42JA.js} +1 -1
  101. package/dist/{chunk-HGXWC4WT.js → chunk-X6CSZSSQ.js} +4 -4
  102. package/dist/{chunk-7YJSDXLM.js → chunk-XJMUEOXT.js} +1 -1
  103. package/dist/{chunk-KHOWMC57.js → chunk-XSUWXBHF.js} +3 -3
  104. package/dist/{chunk-54O76CMR.js → chunk-XZTFYFC7.js} +2 -2
  105. package/dist/{chunk-FD6KOIT2.js → chunk-YG3NFC5N.js} +5 -5
  106. package/dist/{chunk-2LI3DF7Q.js → chunk-YMBJU4CT.js} +2 -2
  107. package/dist/{chunk-77L2TNJW.js → chunk-YRWGCYHH.js} +1 -1
  108. package/dist/{chunk-JQMERLQS.js → chunk-YX6VQGLG.js} +2 -2
  109. package/dist/{chunk-UXN73YAE.js → chunk-ZBPBX656.js} +3 -3
  110. package/dist/{chunk-AQA63ZWO.js → chunk-ZZ7VB6QC.js} +3 -3
  111. package/dist/{codex-app-cards-switch-GBTS3OQW.js → codex-app-cards-switch-A77HUVKT.js} +11 -11
  112. package/dist/{codex-desktop-launch-S6OULJDZ.js → codex-desktop-launch-FSHKRCRL.js} +1 -1
  113. package/dist/{codex-session-launch-K2KE3AD5.js → codex-session-launch-VAXYRXK6.js} +18 -18
  114. package/dist/{config-OBGYURFX.js → config-SMJ2QWQF.js} +3 -3
  115. package/dist/{global-upgrade-ZMWRPO5G.js → global-upgrade-63X4UFFP.js} +10 -10
  116. package/dist/{identity-OLRKDYFR.js → identity-3L2YHAZP.js} +4 -4
  117. package/dist/{live-capabilities-LZECCGFQ.js → live-capabilities-QBQX7RFM.js} +5 -5
  118. package/dist/{paths-YUF2TFTA.js → paths-5VPGINSP.js} +3 -3
  119. package/dist/{reapply-5SZSMZJJ.js → reapply-MSIZJULX.js} +27 -27
  120. package/dist/src/index.js +28 -28
  121. package/dist/{upgrade-lock-MSBKXUKM.js → upgrade-lock-KKW6XZ7B.js} +4 -4
  122. package/dist/{usage-KX2HN47E.js → usage-ICF3NG4F.js} +3 -3
  123. package/package.json +1 -1
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  ensureCodexTrustsPusharyHooks
3
- } from "./chunk-54O76CMR.js";
3
+ } from "./chunk-XZTFYFC7.js";
4
4
  import {
5
5
  hermesReceiptPaths,
6
6
  hermesSetupPredatesThePluginFolder,
7
7
  installHermesPlugin,
8
8
  refreshHermesPluginFiles,
9
9
  shippedHermesPlugin
10
- } from "./chunk-Z3FMJ567.js";
10
+ } from "./chunk-6W2ASRZO.js";
11
11
  import {
12
12
  fxIgnoresInstructionsFile,
13
13
  fxInstructionsBody,
@@ -16,7 +16,7 @@ import {
16
16
  macAppFxBridge,
17
17
  refreshClineKey,
18
18
  switchFxHttpEntryToBridge
19
- } from "./chunk-SSJDAX4E.js";
19
+ } from "./chunk-DOMDCMGC.js";
20
20
  import {
21
21
  OPENCODE_HOOK_BINARY,
22
22
  agentHookOwner,
@@ -28,16 +28,16 @@ import {
28
28
  openCodePluginDir,
29
29
  openCodeWired,
30
30
  withOpenCodeAskRules
31
- } from "./chunk-72ILLFCY.js";
31
+ } from "./chunk-AN26S5DC.js";
32
32
  import {
33
33
  detectClaudeVersion
34
- } from "./chunk-YAA6MT6O.js";
34
+ } from "./chunk-LKAO35SY.js";
35
35
  import {
36
36
  addCompatibleHooks,
37
37
  compatibleConfigFile,
38
38
  compatibleInstructionsFile,
39
39
  hasCompatibleHooks
40
- } from "./chunk-DJPNVVJQ.js";
40
+ } from "./chunk-LRS4TJU2.js";
41
41
  import {
42
42
  GEMINI_HOOK_BINARY,
43
43
  addGeminiHooks,
@@ -49,7 +49,7 @@ import {
49
49
  geminiWired,
50
50
  hasGeminiHooks,
51
51
  planHooks
52
- } from "./chunk-NFWZVY25.js";
52
+ } from "./chunk-WOZLV3LN.js";
53
53
  import {
54
54
  CLAUDE_HOOK_BINARY,
55
55
  CLAUDE_HOOK_EVENTS,
@@ -94,7 +94,7 @@ import {
94
94
  renderAgentInstructions,
95
95
  supportedClaudeEvents,
96
96
  vscodePluginMcp
97
- } from "./chunk-274CV7IW.js";
97
+ } from "./chunk-SMIU5URV.js";
98
98
  import {
99
99
  formatVersion,
100
100
  readJsonSafe,
@@ -102,12 +102,12 @@ import {
102
102
  resolveGlobalBinary,
103
103
  writeFileAtomic,
104
104
  writeJsonAtomic
105
- } from "./chunk-OXOYS3UG.js";
105
+ } from "./chunk-T7FPZN5V.js";
106
106
  import {
107
107
  HOOK_COMPATIBLE_PROFILES,
108
108
  isCompatibleAgentType,
109
109
  isRecord
110
- } from "./chunk-RQOT6QL3.js";
110
+ } from "./chunk-JGEPODEP.js";
111
111
 
112
112
  // src/reapply.ts
113
113
  import { dirname, join } from "path";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  DEFAULT_SESSION
3
- } from "./chunk-HZNZJTGH.js";
3
+ } from "./chunk-5NQ3SMVP.js";
4
4
 
5
5
  // src/answer.ts
6
6
  var isDeferAnswer = (value) => value === "defer";
@@ -7,7 +7,7 @@ import {
7
7
  recordSealerFor,
8
8
  uploadTranscriptRecords,
9
9
  wrapSessionKey
10
- } from "./chunk-NWN6GGJL.js";
10
+ } from "./chunk-LA3MMHLO.js";
11
11
 
12
12
  // src/live-session.ts
13
13
  var MAX_TRANSCRIPT_QUEUE = 100;
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  announceSubscriptionRequired,
3
3
  isDeferAnswer
4
- } from "./chunk-SKTZKAGH.js";
4
+ } from "./chunk-3CN2EFKK.js";
5
5
  import {
6
6
  AUTO_DECISION_WINDOW_MS,
7
7
  DEFAULT_SESSION,
@@ -10,19 +10,19 @@ import {
10
10
  permissionDeniedAction,
11
11
  releaseThrottle,
12
12
  reportEvent
13
- } from "./chunk-HZNZJTGH.js";
13
+ } from "./chunk-5NQ3SMVP.js";
14
14
  import {
15
15
  askUser,
16
16
  isDecisionStopped,
17
17
  isQuestionLimitRefusal,
18
18
  waitForQuestion
19
- } from "./chunk-FD6KOIT2.js";
19
+ } from "./chunk-YG3NFC5N.js";
20
20
  import {
21
21
  SubscriptionRequiredError
22
- } from "./chunk-VIQ5OS5E.js";
22
+ } from "./chunk-GIE7PLZD.js";
23
23
  import {
24
24
  getMachineId
25
- } from "./chunk-FZ2SHXUE.js";
25
+ } from "./chunk-LWAYXE7G.js";
26
26
  import {
27
27
  ASK_CONTEXT_MAX,
28
28
  agentQuestionContext,
@@ -34,7 +34,7 @@ import {
34
34
  questionsShownAsASet,
35
35
  shouldDeferToNativeMode,
36
36
  wireVerdictFor
37
- } from "./chunk-RQOT6QL3.js";
37
+ } from "./chunk-JGEPODEP.js";
38
38
 
39
39
  // src/machine-decision-audit.ts
40
40
  import { basename } from "path";
@@ -4,24 +4,24 @@ import {
4
4
  outcomeOfFailedAsk,
5
5
  reportMachineDenial,
6
6
  storedWaitDeadline
7
- } from "./chunk-7FWZNWIO.js";
7
+ } from "./chunk-4QPF4BGP.js";
8
8
  import {
9
9
  isGatingMoment,
10
10
  recordKeylessMoment
11
- } from "./chunk-7YJSDXLM.js";
11
+ } from "./chunk-XJMUEOXT.js";
12
12
  import {
13
13
  isAdmitted,
14
14
  readAdmissionRules
15
- } from "./chunk-WOJW23ZD.js";
15
+ } from "./chunk-HR6M44CX.js";
16
16
  import {
17
17
  isDeferAnswer,
18
18
  oncePerSession
19
- } from "./chunk-SKTZKAGH.js";
19
+ } from "./chunk-3CN2EFKK.js";
20
20
  import {
21
21
  activeHookSource,
22
22
  activeIdentity,
23
23
  namedSource
24
- } from "./chunk-DJPNVVJQ.js";
24
+ } from "./chunk-LRS4TJU2.js";
25
25
  import {
26
26
  DEFAULT_SESSION,
27
27
  UNNAMED_ACTION,
@@ -45,10 +45,10 @@ import {
45
45
  reportEvent,
46
46
  scopePathFor,
47
47
  settleQuestionsForToolUse
48
- } from "./chunk-HZNZJTGH.js";
48
+ } from "./chunk-5NQ3SMVP.js";
49
49
  import {
50
50
  repoKeyFor
51
- } from "./chunk-GMHQYX3D.js";
51
+ } from "./chunk-NPO3ZTR4.js";
52
52
  import {
53
53
  askUser,
54
54
  cancelQuestion,
@@ -65,20 +65,20 @@ import {
65
65
  waitForQuestion,
66
66
  waitsForThePhone,
67
67
  withdrawQuestion
68
- } from "./chunk-FD6KOIT2.js";
68
+ } from "./chunk-YG3NFC5N.js";
69
69
  import {
70
70
  getMachineId
71
- } from "./chunk-FZ2SHXUE.js";
71
+ } from "./chunk-LWAYXE7G.js";
72
72
  import {
73
73
  claudeConfigDir
74
- } from "./chunk-274CV7IW.js";
74
+ } from "./chunk-SMIU5URV.js";
75
75
  import {
76
76
  getApiKey,
77
77
  getBaseUrl
78
- } from "./chunk-32OSSYGZ.js";
78
+ } from "./chunk-X2KK42JA.js";
79
79
  import {
80
80
  NPX_LATEST_COMMAND
81
- } from "./chunk-X2MTVD4W.js";
81
+ } from "./chunk-AZ56FPRG.js";
82
82
  import {
83
83
  AGENT_QUESTION_STRATEGY,
84
84
  AGENT_QUESTION_TOOL,
@@ -133,7 +133,7 @@ import {
133
133
  terminalStaysLiveForTheCall,
134
134
  timeoutActionWithoutLocalPrompt,
135
135
  unansweredRefusalReason
136
- } from "./chunk-RQOT6QL3.js";
136
+ } from "./chunk-JGEPODEP.js";
137
137
 
138
138
  // src/terminal-answer-watch.ts
139
139
  import { closeSync, openSync, readSync, statSync } from "fs";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  repoKeyFor
3
- } from "./chunk-GMHQYX3D.js";
3
+ } from "./chunk-NPO3ZTR4.js";
4
4
  import {
5
5
  cancelQuestion,
6
6
  clientErrorKindOf,
@@ -8,29 +8,29 @@ import {
8
8
  reportClientError,
9
9
  sendNotification,
10
10
  waitForAnswer
11
- } from "./chunk-FD6KOIT2.js";
11
+ } from "./chunk-YG3NFC5N.js";
12
12
  import {
13
13
  withRetry
14
- } from "./chunk-VIQ5OS5E.js";
14
+ } from "./chunk-GIE7PLZD.js";
15
15
  import {
16
16
  getMachineId
17
- } from "./chunk-FZ2SHXUE.js";
17
+ } from "./chunk-LWAYXE7G.js";
18
18
  import {
19
19
  reportedInstallSource
20
- } from "./chunk-METUT7V4.js";
20
+ } from "./chunk-AERRQEWZ.js";
21
21
  import {
22
22
  IDLE_PROMPT_NOTIFICATION,
23
23
  NOTIFICATION_PUSH_TYPES,
24
24
  POSTTOOLUSE_MIRROR_ONLY_TOOLS,
25
25
  canonicalJson
26
- } from "./chunk-274CV7IW.js";
26
+ } from "./chunk-SMIU5URV.js";
27
27
  import {
28
28
  writeFileAtomic
29
- } from "./chunk-OXOYS3UG.js";
29
+ } from "./chunk-T7FPZN5V.js";
30
30
  import {
31
31
  getApiKey,
32
32
  getBaseUrl
33
- } from "./chunk-32OSSYGZ.js";
33
+ } from "./chunk-X2KK42JA.js";
34
34
  import {
35
35
  ACTION_BODY_MAX,
36
36
  AGENTS,
@@ -65,7 +65,7 @@ import {
65
65
  toToolLookup,
66
66
  truncateLine,
67
67
  unansweredRefusalReason
68
- } from "./chunk-RQOT6QL3.js";
68
+ } from "./chunk-JGEPODEP.js";
69
69
 
70
70
  // ../hook-mapping/src/describe.ts
71
71
  import { isAbsolute, relative, resolve } from "path";
@@ -2,7 +2,7 @@ import {
2
2
  isApprovalMode,
3
3
  isRecord,
4
4
  isTimeoutAction
5
- } from "./chunk-RQOT6QL3.js";
5
+ } from "./chunk-JGEPODEP.js";
6
6
 
7
7
  // src/cli/settings-response.ts
8
8
  var isFiniteNumber = (value) => typeof value === "number" && Number.isFinite(value);
@@ -5,19 +5,19 @@ import {
5
5
  hermesAppWiringRecord,
6
6
  hermesConfigReceipt,
7
7
  hermesSetupReceipt
8
- } from "./chunk-274CV7IW.js";
8
+ } from "./chunk-SMIU5URV.js";
9
9
  import {
10
10
  readJsonSafe,
11
11
  resolvePathBinary,
12
12
  writeJsonAtomic
13
- } from "./chunk-OXOYS3UG.js";
13
+ } from "./chunk-T7FPZN5V.js";
14
14
  import {
15
15
  isNewerVersion,
16
16
  isReleaseVersion
17
17
  } from "./chunk-QTOLNRET.js";
18
18
  import {
19
19
  isRecord
20
- } from "./chunk-RQOT6QL3.js";
20
+ } from "./chunk-JGEPODEP.js";
21
21
 
22
22
  // src/hermes/plugin-payload.ts
23
23
  import { createHash } from "crypto";
@@ -34,7 +34,9 @@ from . import api, approval, host, identity, installation, schemas, tools
34
34
 
35
35
  logger = logging.getLogger(__name__)
36
36
 
37
- MAX_ERROR_NOTIFICATIONS = 3
37
+ FAILED_TURN_WITHOUT_REASON = "no reason given"
38
+ REDACTION_UNAVAILABLE = "[redaction unavailable]"
39
+ FAILED_TURN_REASON_MAX_LENGTH = 200
38
40
  SYSTEM_PROMPT_SECTION_ID = "pushary.reach-the-human"
39
41
  HERMES_QUESTION_TOOL = "clarify"
40
42
  QUESTION_ROUTING_PROMPT = (
@@ -82,7 +84,7 @@ TOOL_REGISTRATIONS = (
82
84
  "Ask one of your own end-users and block on a fail-closed answer (Partner plan)"),
83
85
  )
84
86
 
85
- _session_totals = {"tools": 0, "errors": 0, "notified": 0}
87
+ _session_totals = {"tools": 0, "errors": 0}
86
88
  _last_turn = {"completed": False, "interrupted": False}
87
89
  _plugin_activity = {"attempted": False}
88
90
  _plugin_activity_lock = threading.Lock()
@@ -173,7 +175,7 @@ def _redact_outbound_text(text: str) -> str:
173
175
  return redact_for_egress(redacted) if redact_for_egress else redacted
174
176
  except Exception:
175
177
  logger.warning("[pushary] host redaction unavailable; omitting outbound detail")
176
- return "[redaction unavailable]"
178
+ return REDACTION_UNAVAILABLE
177
179
 
178
180
 
179
181
  def _summarize_args(args):
@@ -312,52 +314,25 @@ def _on_pre_tool_call(tool_name=None, args=None, session_id=None, **kwargs):
312
314
  return _block_unapproved(tool_name)
313
315
 
314
316
 
315
- def _tool_failure(result, status, error_message):
317
+ def _tool_failed(result, status):
316
318
  if status is not None:
317
- return (error_message or "tool returned an error") if status == "error" else None
319
+ return status == "error"
318
320
  try:
319
321
  parsed = json.loads(result) if isinstance(result, str) else result
320
322
  except (json.JSONDecodeError, TypeError):
321
- return None
322
- if isinstance(parsed, dict) and parsed.get("error"):
323
- return str(parsed["error"])
324
- return None
323
+ return False
324
+ return isinstance(parsed, dict) and bool(parsed.get("error"))
325
325
 
326
326
 
327
- def _on_post_tool_call(tool_name, args, result, duration_ms=0, status=None,
328
- error_message=None, **kwargs):
327
+ def _on_post_tool_call(tool_name, args, result, duration_ms=0, status=None, **kwargs):
329
328
  _session_totals["tools"] += 1
330
-
331
- failure = _tool_failure(result, status, error_message)
332
- if failure is None:
333
- return
334
-
335
- _session_totals["errors"] += 1
336
- if not api.is_configured():
337
- return
338
- if _session_totals["notified"] >= MAX_ERROR_NOTIFICATIONS:
339
- return
340
- _session_totals["notified"] += 1
341
-
342
- try:
343
- failure = _redact_outbound_text(str(failure))
344
- api.send_notification(
345
- title="Tool error in Hermes",
346
- body=f"{tool_name} failed: {failure[:150]}",
347
- agent_name=identity.agent_name(),
348
- context={
349
- "type": "error",
350
- "errorMessage": failure[:500],
351
- "summary": f"Tool '{tool_name}' returned an error after {duration_ms}ms",
352
- },
353
- )
354
- except Exception:
355
- pass
329
+ if _tool_failed(result, status):
330
+ _session_totals["errors"] += 1
356
331
 
357
332
 
358
333
  def _on_session_start(session_id=None, **kwargs):
359
334
  identity.remember_session(session_id)
360
- _session_totals.update(tools=0, errors=0, notified=0)
335
+ _session_totals.update(tools=0, errors=0)
361
336
  _last_turn.update(completed=False, interrupted=False)
362
337
  _report_session_event("session_start", session_id, can_drain=True)
363
338
  _report_plugin_active_once(session_id)
@@ -397,26 +372,40 @@ def _on_pre_llm_call(session_id=None, **kwargs):
397
372
  }
398
373
 
399
374
 
400
- def _report_session_event(event, session_id, can_drain=False):
375
+ def _report_session_event(event, session_id, can_drain=False, error=None):
401
376
  if not api.is_configured() or not session_id:
402
377
  return
403
378
  try:
404
- api.agent_event(event, session_id, can_drain=can_drain)
379
+ api.agent_event(event, session_id, can_drain=can_drain, error=error)
405
380
  except Exception:
406
381
  pass
407
382
 
408
383
 
409
- def _on_session_end(session_id=None, completed=False, interrupted=False, **kwargs):
384
+ def _turn_failure_reason(failed, interrupted, turn_exit_reason):
385
+ if failed is not True or interrupted:
386
+ return None
387
+ reason = _redact_outbound_text(str(turn_exit_reason or "").strip())
388
+ if not reason or reason == REDACTION_UNAVAILABLE:
389
+ return FAILED_TURN_WITHOUT_REASON
390
+ return reason[:FAILED_TURN_REASON_MAX_LENGTH]
391
+
392
+
393
+ def _on_session_end(session_id=None, completed=False, interrupted=False, failed=False,
394
+ turn_exit_reason=None, **kwargs):
410
395
  identity.remember_session(session_id)
411
396
  _last_turn.update(completed=bool(completed), interrupted=bool(interrupted))
412
- _report_session_event("session_end", session_id or identity.session_id())
397
+ _report_session_event(
398
+ "session_end",
399
+ session_id or identity.session_id(),
400
+ error=_turn_failure_reason(failed, interrupted, turn_exit_reason),
401
+ )
413
402
 
414
403
 
415
404
  def _on_session_finalize(session_id=None, **kwargs):
416
405
  _report_session_event("session_closed", session_id or identity.session_id())
417
406
  tool_count = _session_totals["tools"]
418
407
  error_count = _session_totals["errors"]
419
- _session_totals.update(tools=0, errors=0, notified=0)
408
+ _session_totals.update(tools=0, errors=0)
420
409
 
421
410
  if not os.environ.get("PUSHARY_AUTO_NOTIFY_SESSION_END"):
422
411
  identity.forget_session()
@@ -635,7 +624,7 @@ def report_plugin_active(session_id):
635
624
  return False
636
625
 
637
626
 
638
- def agent_event(event, session_id, can_drain=False):
627
+ def agent_event(event, session_id, can_drain=False, error=None):
639
628
  """Report a Hermes session and pick up a queued notch instruction."""
640
629
  try:
641
630
  pending = _read_pending(session_id) if can_drain else None
@@ -647,6 +636,7 @@ def agent_event(event, session_id, can_drain=False):
647
636
  "canDrainCommand": can_drain and pending is None,
648
637
  "ackMode": can_drain and pending is None,
649
638
  "skipCommandDrain": pending is not None,
639
+ **({"error": error} if error else {}),
650
640
  })
651
641
  with urllib.request.urlopen(req, timeout=10) as resp:
652
642
  raw = resp.read().decode("utf-8")
@@ -1073,7 +1063,7 @@ def record_plugin_load(approval_transport_registered, home=None, pid=None, now=N
1073
1063
  logger.debug("[pushary] could not record the plugin load: %s", exc)
1074
1064
  return None
1075
1065
  ` },
1076
- { path: "plugin.yaml", contents: "name: pushary\nversion: 0.8.0\ndescription: Push notifications and human-in-the-loop for Hermes Agent via Pushary\nauthor: RalphNex OU\nrequires_env:\n - name: PUSHARY_API_KEY\n description: Your Pushary API key\n url: https://pushary.com/sign-up?from=hermes\n secret: true\nprovides_tools:\n - pushary_remind\n - pushary_notify\n - pushary_ask\n - pushary_wait\n - pushary_cancel\n - pushary_propose_scope\n - pushary_enroll\n - pushary_ask_end_user\nprovides_hooks:\n - pre_llm_call\n - pre_tool_call\n - post_tool_call\n - on_session_start\n - on_session_end\n - on_session_finalize\nprovides_approval_transports:\n - pushary\n" },
1066
+ { path: "plugin.yaml", contents: "name: pushary\nversion: 0.8.1\ndescription: Push notifications and human-in-the-loop for Hermes Agent via Pushary\nauthor: RalphNex OU\nrequires_env:\n - name: PUSHARY_API_KEY\n description: Your Pushary API key\n url: https://pushary.com/sign-up?from=hermes\n secret: true\nprovides_tools:\n - pushary_remind\n - pushary_notify\n - pushary_ask\n - pushary_wait\n - pushary_cancel\n - pushary_propose_scope\n - pushary_enroll\n - pushary_ask_end_user\nprovides_hooks:\n - pre_llm_call\n - pre_tool_call\n - post_tool_call\n - on_session_start\n - on_session_end\n - on_session_finalize\nprovides_approval_transports:\n - pushary\n" },
1077
1067
  { path: "schemas.py", contents: `PUSHARY_REMIND = {
1078
1068
  "name": "pushary_remind",
1079
1069
  "description": "Schedule a one-time personal reminder on Pushary, even after Hermes exits. Use body plus in_minutes or at (ISO timestamp with explicit UTC offset, within 30 days). Never guess the user's timezone. Confirm the returned time. No arguments lists pending reminders; cancel_reminder_id cancels a scheduled one. Use Hermes cron for agent work; use this for reminding the operator.",
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  realpath
3
- } from "./chunk-YAA6MT6O.js";
3
+ } from "./chunk-LKAO35SY.js";
4
4
  import {
5
5
  findNativeClaudeInstall
6
- } from "./chunk-YSOZVBFW.js";
6
+ } from "./chunk-BJRLJJS2.js";
7
7
  import {
8
8
  readGlobalPrefixAsync,
9
9
  resolveGlobalBinary,
@@ -13,10 +13,10 @@ import {
13
13
  resolvePackageVersionFromBinary,
14
14
  resolvePathBinary,
15
15
  resolvePathBinaryAsync
16
- } from "./chunk-OXOYS3UG.js";
16
+ } from "./chunk-T7FPZN5V.js";
17
17
  import {
18
18
  MANAGED_PROVIDERS
19
- } from "./chunk-RQOT6QL3.js";
19
+ } from "./chunk-JGEPODEP.js";
20
20
 
21
21
  // src/live-capabilities.ts
22
22
  import { homedir } from "os";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  configFilePath
3
- } from "./chunk-32OSSYGZ.js";
3
+ } from "./chunk-X2KK42JA.js";
4
4
  import {
5
5
  normalizeInstallSource
6
- } from "./chunk-RQOT6QL3.js";
6
+ } from "./chunk-JGEPODEP.js";
7
7
 
8
8
  // src/install-source.ts
9
9
  import { readFileSync } from "fs";
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  compatibleConfigFile
3
- } from "./chunk-DJPNVVJQ.js";
3
+ } from "./chunk-LRS4TJU2.js";
4
4
  import {
5
5
  hookOwnerOf,
6
6
  hookOwnerOfCommands,
7
7
  liveBridgeProbe,
8
8
  resolveBridgeStub
9
- } from "./chunk-NFWZVY25.js";
9
+ } from "./chunk-WOZLV3LN.js";
10
10
  import {
11
11
  AGENT_CHOICES
12
- } from "./chunk-ZK5WYAMI.js";
12
+ } from "./chunk-EVJRITSI.js";
13
13
  import {
14
14
  claudeSettings,
15
15
  codexHooksJson,
@@ -18,10 +18,10 @@ import {
18
18
  guardedArgv,
19
19
  pusharyDir,
20
20
  vscodePluginDir
21
- } from "./chunk-274CV7IW.js";
21
+ } from "./chunk-SMIU5URV.js";
22
22
  import {
23
23
  readJsonSafe
24
- } from "./chunk-OXOYS3UG.js";
24
+ } from "./chunk-T7FPZN5V.js";
25
25
  import {
26
26
  HOOK_BUDGETS,
27
27
  HOOK_COMPATIBLE_PROFILES,
@@ -29,7 +29,7 @@ import {
29
29
  OPENCODE_APPROVAL_EVENT,
30
30
  hookCompatibleProfile,
31
31
  isRecord
32
- } from "./chunk-RQOT6QL3.js";
32
+ } from "./chunk-JGEPODEP.js";
33
33
 
34
34
  // src/opencode-plugin.ts
35
35
  var OPENCODE_PLUGIN_MARKER = "pushary-opencode-plugin w1";
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  pusharyDir
3
- } from "./chunk-274CV7IW.js";
3
+ } from "./chunk-SMIU5URV.js";
4
4
  import {
5
5
  readJsonSafe,
6
6
  writeFileAtomic
7
- } from "./chunk-OXOYS3UG.js";
7
+ } from "./chunk-T7FPZN5V.js";
8
8
  import {
9
9
  DECLINED_AGENTS_FILE,
10
10
  DISCONNECT_AGENT_IDS,
@@ -13,7 +13,7 @@ import {
13
13
  serializeDeclinedAgents,
14
14
  withDeclinedAgent,
15
15
  withoutDeclinedAgent
16
- } from "./chunk-RQOT6QL3.js";
16
+ } from "./chunk-JGEPODEP.js";
17
17
 
18
18
  // src/declined-agents-file.ts
19
19
  import { join } from "path";
@@ -2,7 +2,7 @@ import {
2
2
  DISCONNECT_AGENT_IDS,
3
3
  SETUP_AGENT_CHOICES,
4
4
  isApprovalMode
5
- } from "./chunk-RQOT6QL3.js";
5
+ } from "./chunk-JGEPODEP.js";
6
6
 
7
7
  // src/cli/mode-request.ts
8
8
  var parseDuration = (value) => {
@@ -1,19 +1,19 @@
1
1
  import {
2
2
  macAppBridgeAvailable
3
- } from "./chunk-72ILLFCY.js";
3
+ } from "./chunk-AN26S5DC.js";
4
4
  import {
5
5
  keyPrefix
6
- } from "./chunk-GZHQQP7J.js";
6
+ } from "./chunk-D536PHXF.js";
7
7
  import {
8
8
  bridgeAgentKey
9
- } from "./chunk-274CV7IW.js";
9
+ } from "./chunk-SMIU5URV.js";
10
10
  import {
11
11
  readJsonSafe
12
- } from "./chunk-OXOYS3UG.js";
12
+ } from "./chunk-T7FPZN5V.js";
13
13
  import {
14
14
  isRecord,
15
15
  isValidApiKey
16
- } from "./chunk-RQOT6QL3.js";
16
+ } from "./chunk-JGEPODEP.js";
17
17
 
18
18
  // src/shared-mcp-key.ts
19
19
  var asRecord = (value) => value !== null && typeof value === "object" && !Array.isArray(value) ? value : void 0;
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isFile
3
- } from "./chunk-OXOYS3UG.js";
3
+ } from "./chunk-T7FPZN5V.js";
4
4
 
5
5
  // src/claude-native-install.ts
6
6
  import { accessSync, constants } from "fs";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  HOOK_HOLD_BUDGET_ENV,
3
3
  hookHoldBudgetProof
4
- } from "./chunk-RQOT6QL3.js";
4
+ } from "./chunk-JGEPODEP.js";
5
5
 
6
6
  // src/hold-budget.ts
7
7
  var takeHookHoldBudget = (args = process.argv.slice(2), env = process.env) => {
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  autoUpdateLock
3
- } from "./chunk-274CV7IW.js";
3
+ } from "./chunk-SMIU5URV.js";
4
4
  import {
5
5
  installPackageGlobally,
6
6
  npmErrorMessage,
7
7
  writeJsonAtomic
8
- } from "./chunk-OXOYS3UG.js";
8
+ } from "./chunk-T7FPZN5V.js";
9
9
 
10
10
  // src/upgrade-lock.ts
11
11
  import { fork } from "child_process";
@@ -1,19 +1,19 @@
1
1
  import {
2
2
  resolveInstallSourceFor
3
- } from "./chunk-METUT7V4.js";
3
+ } from "./chunk-AERRQEWZ.js";
4
4
  import {
5
5
  backupFile,
6
6
  readJsonSafe,
7
7
  writeFileAtomic,
8
8
  writeJsonAtomic
9
- } from "./chunk-OXOYS3UG.js";
9
+ } from "./chunk-T7FPZN5V.js";
10
10
  import {
11
11
  configFilePath
12
- } from "./chunk-32OSSYGZ.js";
12
+ } from "./chunk-X2KK42JA.js";
13
13
  import {
14
14
  API_KEY_PREFIX_PATTERN,
15
15
  isRecord
16
- } from "./chunk-RQOT6QL3.js";
16
+ } from "./chunk-JGEPODEP.js";
17
17
 
18
18
  // src/shell-alias.ts
19
19
  import { homedir } from "os";