@parity/product-deploy 0.7.29 → 0.7.30-rc.0

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 (53) hide show
  1. package/assets/environments.json +5 -2
  2. package/dist/bug-report.js +4 -4
  3. package/dist/{chunk-SBLSXJ2L.js → chunk-2ULXHYB4.js} +58 -7
  4. package/dist/{chunk-G5VJOHZJ.js → chunk-2WWR3DVD.js} +3 -3
  5. package/dist/{chunk-2VAUMZB2.js → chunk-7Y7RDOGT.js} +39 -8
  6. package/dist/{chunk-BMAEWZYV.js → chunk-AFBOKCCQ.js} +3 -3
  7. package/dist/{chunk-7PYJMQQP.js → chunk-E62JHC4N.js} +2 -2
  8. package/dist/{chunk-7UGOKEKF.js → chunk-EYWOZU4M.js} +3 -3
  9. package/dist/{chunk-XR6ZWT4P.js → chunk-FIKBEVYL.js} +1 -1
  10. package/dist/{chunk-JZFXFZ5L.js → chunk-GL2HHK4G.js} +5 -2
  11. package/dist/{chunk-5VZQ2KSU.js → chunk-JCOZV25R.js} +18 -15
  12. package/dist/{chunk-IDYGYIMH.js → chunk-LHLCPDGL.js} +1 -1
  13. package/dist/{chunk-2TAHVGIF.js → chunk-MZ4Z5AXI.js} +43 -60
  14. package/dist/{chunk-T7EEVWNU.js → chunk-SI2ZUOYD.js} +5 -5
  15. package/dist/chunk-SLE4P6MO.js +39 -0
  16. package/dist/chunk-XAB7WM3S.js +90 -0
  17. package/dist/{chunk-WGZUHHII.js → chunk-YCVK36KC.js} +1 -1
  18. package/dist/{chunk-QTAKQVPQ.js → chunk-YP6AS724.js} +5 -1
  19. package/dist/{chunk-QTQGD54B.js → chunk-ZGH7YHV5.js} +1 -1
  20. package/dist/chunk-probe.js +3 -3
  21. package/dist/deploy.d.ts +3 -1
  22. package/dist/deploy.js +11 -9
  23. package/dist/dotns.d.ts +19 -2
  24. package/dist/dotns.js +7 -5
  25. package/dist/environments.js +1 -1
  26. package/dist/index.d.ts +1 -0
  27. package/dist/index.js +10 -10
  28. package/dist/manifest/publish.js +10 -10
  29. package/dist/memory-report.js +2 -2
  30. package/dist/merkle.js +9 -9
  31. package/dist/personhood/bind-paid-alias.d.ts +1 -1
  32. package/dist/personhood/bind-paid-alias.js +3 -2
  33. package/dist/personhood/bind-personal-id.js +2 -2
  34. package/dist/personhood/bootstrap.d.ts +7 -0
  35. package/dist/personhood/bootstrap.js +29 -17
  36. package/dist/personhood/chain-prereqs.d.ts +76 -0
  37. package/dist/personhood/chain-prereqs.js +17 -0
  38. package/dist/personhood/claim-pgas.d.ts +33 -2
  39. package/dist/personhood/claim-pgas.js +4 -2
  40. package/dist/personhood/constants.d.ts +5 -5
  41. package/dist/personhood/constants.js +3 -3
  42. package/dist/personhood/member-key.js +2 -2
  43. package/dist/personhood/people-client.js +5 -5
  44. package/dist/personhood/proof-validity.d.ts +41 -0
  45. package/dist/personhood/proof-validity.js +12 -0
  46. package/dist/personhood/reprove.d.ts +1 -1
  47. package/dist/personhood/reprove.js +10 -13
  48. package/dist/pool.js +3 -3
  49. package/dist/run-state.js +1 -1
  50. package/dist/telemetry.d.ts +43 -1
  51. package/dist/telemetry.js +4 -2
  52. package/dist/version-check.js +3 -3
  53. package/package.json +3 -3
@@ -2,6 +2,29 @@ import * as _sentry_node from '@sentry/node';
2
2
  import { DeployContextForReport } from './memory-report.js';
3
3
  import 'node:v8';
4
4
 
5
+ /**
6
+ * Registry of instrumented code paths for dead-branch coverage monitoring.
7
+ *
8
+ * Each ID is emitted as a "code.path.<id>" span attribute the first time a deploy
9
+ * exercises that branch. The nightly check-code-path-coverage.py queries
10
+ * Sentry for zero-hit paths over a rolling 30-day window and files a GitHub
11
+ * issue if any are found.
12
+ *
13
+ * Rule: never remove an ID without also removing the corresponding branch.
14
+ * Add a new ID whenever you add a conditional branch worth monitoring.
15
+ *
16
+ * When adding a new ID here, ALSO add it to CODE_PATHS in
17
+ * tools/check-code-path-coverage.py with an `introduced` date of today
18
+ * (YYYY-MM-DD UTC). The grace window prevents the brand-new path from
19
+ * triggering a false "0 hits over 30d" alarm before any consumer has
20
+ * had time to upgrade and exercise the branch.
21
+ */
22
+ declare const CODE_PATHS: {
23
+ readonly DOTNS_AUTO_MAPPING: "dotns.auto-mapping";
24
+ readonly DOTNS_MANUAL_MAPPING: "dotns.manual-mapping";
25
+ };
26
+ type CodePath = typeof CODE_PATHS[keyof typeof CODE_PATHS];
27
+
5
28
  declare const VERSION: string;
6
29
  type SentryModule = typeof _sentry_node | null;
7
30
  interface InternalContextSignals {
@@ -50,7 +73,26 @@ declare function __setDeployRootSpanForTest(span: any | null): void;
50
73
  declare function __setSentryForTest(stub: any): SentryModule;
51
74
  declare function getCurrentSentryTraceId(): string | undefined;
52
75
  declare function setDeploySentryTag(key: string, value: string): void;
76
+ /**
77
+ * Mark a code path as exercised in the current deploy span.
78
+ * Used for dead-branch coverage monitoring — see src/code-paths.ts.
79
+ *
80
+ * Design: each path gets its own boolean attribute `code.path.<id>` = "true"
81
+ * rather than a single `code.path` attribute. This avoids the overwrite problem
82
+ * — a single deploy span that exercises multiple branches would otherwise only
83
+ * record the last one. Boolean-per-path lets Sentry query `has:code.path.pool.auth.v2`
84
+ * independently for each path.
85
+ *
86
+ * Note: @sentry/node user-defined attributes come back as string-typed in EAP
87
+ * regardless of value type. Store as the string "true" so queries using
88
+ * `count_if(code.path.pool.auth.v2, "true")` or `has:code.path.pool.auth.v2`
89
+ * both work correctly.
90
+ *
91
+ * No-ops gracefully if called outside a deploy span (setDeployAttribute guards
92
+ * on deployRootSpan — see setDeployAttribute implementation above).
93
+ */
94
+ declare function markCodePath(id: CodePath): void;
53
95
  declare function captureWarning(message: string, context?: Record<string, unknown>): void;
54
96
  declare function flush(): Promise<void>;
55
97
 
56
- export { type DeployErrorCategory, type DeployErrorKind, type InternalContextSignals, VERSION, __setDeployRootSpanForTest, __setSentryForTest, analyseErrorPattern, captureWarning, classifyDeployError, classifyErrorKind, classifySadReason, closeTelemetry, computeDeployOutcome, flush, getCurrentSentryTraceId, getDeployAttributes, initTelemetry, isExpectedError, isInternalContext, isInternalContextFromSignals, markRelaunchOomHintShown, resolveRepo, resolveRunner, resolveRunnerType, sampleMemory, sanitizeBranch, sanitizeErrorMessage, sanitizeRepo, scrubPaths, setDeployAttribute, setDeployReportContext, setDeploySentryTag, setRunStateActive, truncateAddress, withDeploySpan, withSpan };
98
+ export { type DeployErrorCategory, type DeployErrorKind, type InternalContextSignals, VERSION, __setDeployRootSpanForTest, __setSentryForTest, analyseErrorPattern, captureWarning, classifyDeployError, classifyErrorKind, classifySadReason, closeTelemetry, computeDeployOutcome, flush, getCurrentSentryTraceId, getDeployAttributes, initTelemetry, isExpectedError, isInternalContext, isInternalContextFromSignals, markCodePath, markRelaunchOomHintShown, resolveRepo, resolveRunner, resolveRunnerType, sampleMemory, sanitizeBranch, sanitizeErrorMessage, sanitizeRepo, scrubPaths, setDeployAttribute, setDeployReportContext, setDeploySentryTag, setRunStateActive, truncateAddress, withDeploySpan, withSpan };
package/dist/telemetry.js CHANGED
@@ -16,6 +16,7 @@ import {
16
16
  isExpectedError,
17
17
  isInternalContext,
18
18
  isInternalContextFromSignals,
19
+ markCodePath,
19
20
  markRelaunchOomHintShown,
20
21
  resolveRepo,
21
22
  resolveRunner,
@@ -32,8 +33,8 @@ import {
32
33
  truncateAddress,
33
34
  withDeploySpan,
34
35
  withSpan
35
- } from "./chunk-QTAKQVPQ.js";
36
- import "./chunk-G5VJOHZJ.js";
36
+ } from "./chunk-YP6AS724.js";
37
+ import "./chunk-2WWR3DVD.js";
37
38
  export {
38
39
  VERSION,
39
40
  __setDeployRootSpanForTest,
@@ -52,6 +53,7 @@ export {
52
53
  isExpectedError,
53
54
  isInternalContext,
54
55
  isInternalContextFromSignals,
56
+ markCodePath,
55
57
  markRelaunchOomHintShown,
56
58
  resolveRepo,
57
59
  resolveRunner,
@@ -11,9 +11,9 @@ import {
11
11
  isPreReleaseVersion,
12
12
  preReleaseWarning,
13
13
  promptYesNo
14
- } from "./chunk-WGZUHHII.js";
15
- import "./chunk-QTAKQVPQ.js";
16
- import "./chunk-G5VJOHZJ.js";
14
+ } from "./chunk-YCVK36KC.js";
15
+ import "./chunk-YP6AS724.js";
16
+ import "./chunk-2WWR3DVD.js";
17
17
  export {
18
18
  assessVersion,
19
19
  checkNodeVersion,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parity/product-deploy",
3
- "version": "0.7.29",
3
+ "version": "0.7.30-rc.0",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -39,7 +39,7 @@
39
39
  "tools/release-retry-wrapper.mjs"
40
40
  ],
41
41
  "scripts": {
42
- "build": "tsup src/index.ts src/deploy.ts src/dotns.ts src/pool.ts src/telemetry.ts src/memory-report.ts src/merkle.ts src/gh-pages-mirror.ts src/version-check.ts src/bug-report.ts src/run-state.ts src/environments.ts src/errors.ts src/manifest.ts src/chunk-probe.ts src/manifest-embed.ts src/manifest-fetch.ts src/manifest-roundtrip.ts src/incremental-stats.ts src/chunker.ts src/personhood/encoding.ts src/personhood/hashing.ts src/personhood/constants.ts src/personhood/member-key.ts src/personhood/people-client.ts src/personhood/reprove.ts src/personhood/bind-personal-id.ts src/personhood/claim-pgas.ts src/personhood/bind-paid-alias.ts src/personhood/bootstrap.ts src/manifest/types.ts src/manifest/schema.ts src/manifest/byte-budget.ts src/manifest/config-load.ts src/manifest/publish.ts --format esm --dts --clean --target node22",
42
+ "build": "tsup src/index.ts src/deploy.ts src/dotns.ts src/pool.ts src/telemetry.ts src/memory-report.ts src/merkle.ts src/gh-pages-mirror.ts src/version-check.ts src/bug-report.ts src/run-state.ts src/environments.ts src/errors.ts src/manifest.ts src/chunk-probe.ts src/manifest-embed.ts src/manifest-fetch.ts src/manifest-roundtrip.ts src/incremental-stats.ts src/chunker.ts src/personhood/encoding.ts src/personhood/hashing.ts src/personhood/constants.ts src/personhood/member-key.ts src/personhood/people-client.ts src/personhood/proof-validity.ts src/personhood/reprove.ts src/personhood/bind-personal-id.ts src/personhood/claim-pgas.ts src/personhood/bind-paid-alias.ts src/personhood/bootstrap.ts src/personhood/chain-prereqs.ts src/manifest/types.ts src/manifest/schema.ts src/manifest/byte-budget.ts src/manifest/config-load.ts src/manifest/publish.ts --format esm --dts --clean --target node22",
43
43
  "refresh-environments": "node scripts/refresh-environments.mjs",
44
44
  "check:watched-dependencies": "node tools/check-watched-dependencies.mjs",
45
45
  "prepare": "npm run build",
@@ -66,7 +66,7 @@
66
66
  "jiti": "^2.4.2",
67
67
  "multiformats": "^13.4.1",
68
68
  "polkadot-api": "^2.1.3",
69
- "verifiablejs": "^1.2.0",
69
+ "verifiablejs": "1.3.0-beta.4",
70
70
  "viem": "^2.30.5"
71
71
  },
72
72
  "devDependencies": {