@open-mercato/cli 0.10.1-develop.8028.1.e3bfa74009 → 0.10.1-develop.8033.1.a68811b809

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 (90) hide show
  1. package/dist/agentic/guides/module-facts.json +162 -162
  2. package/dist/agentic/guides/module-facts.v2.json +162 -162
  3. package/dist/agentic/guides/modules/agent_orchestrator/index.md +1 -1
  4. package/dist/agentic/guides/modules/ai_assistant/index.md +1 -1
  5. package/dist/agentic/guides/modules/api_docs/index.md +1 -1
  6. package/dist/agentic/guides/modules/api_keys/index.md +1 -1
  7. package/dist/agentic/guides/modules/attachments/index.md +1 -1
  8. package/dist/agentic/guides/modules/audit_logs/index.md +1 -1
  9. package/dist/agentic/guides/modules/auth/index.md +1 -1
  10. package/dist/agentic/guides/modules/availability/index.md +1 -1
  11. package/dist/agentic/guides/modules/business_rules/index.md +1 -1
  12. package/dist/agentic/guides/modules/carrier_inpost/index.md +1 -1
  13. package/dist/agentic/guides/modules/cart/index.md +1 -1
  14. package/dist/agentic/guides/modules/catalog/index.md +1 -1
  15. package/dist/agentic/guides/modules/channel_apns/index.md +1 -1
  16. package/dist/agentic/guides/modules/channel_discord/index.md +1 -1
  17. package/dist/agentic/guides/modules/channel_expo/index.md +1 -1
  18. package/dist/agentic/guides/modules/channel_fcm/index.md +1 -1
  19. package/dist/agentic/guides/modules/channel_gmail/index.md +1 -1
  20. package/dist/agentic/guides/modules/channel_imap/index.md +1 -1
  21. package/dist/agentic/guides/modules/channel_resend/index.md +1 -1
  22. package/dist/agentic/guides/modules/channel_ses/index.md +1 -1
  23. package/dist/agentic/guides/modules/channel_smtp/index.md +1 -1
  24. package/dist/agentic/guides/modules/checkout/index.md +1 -1
  25. package/dist/agentic/guides/modules/communication_channels/index.md +1 -1
  26. package/dist/agentic/guides/modules/configs/index.md +1 -1
  27. package/dist/agentic/guides/modules/content/index.md +1 -1
  28. package/dist/agentic/guides/modules/currencies/index.md +1 -1
  29. package/dist/agentic/guides/modules/customer_accounts/index.md +1 -1
  30. package/dist/agentic/guides/modules/customer_groups/index.md +1 -1
  31. package/dist/agentic/guides/modules/customers/index.md +1 -1
  32. package/dist/agentic/guides/modules/dashboards/index.md +1 -1
  33. package/dist/agentic/guides/modules/data_sync/index.md +1 -1
  34. package/dist/agentic/guides/modules/design_system/index.md +1 -1
  35. package/dist/agentic/guides/modules/devices/index.md +1 -1
  36. package/dist/agentic/guides/modules/dictionaries/index.md +1 -1
  37. package/dist/agentic/guides/modules/directory/index.md +1 -1
  38. package/dist/agentic/guides/modules/documents/index.md +1 -1
  39. package/dist/agentic/guides/modules/ecommerce/index.md +1 -1
  40. package/dist/agentic/guides/modules/entities/index.md +1 -1
  41. package/dist/agentic/guides/modules/eudr/index.md +1 -1
  42. package/dist/agentic/guides/modules/events/index.md +1 -1
  43. package/dist/agentic/guides/modules/feature_toggles/index.md +1 -1
  44. package/dist/agentic/guides/modules/forms/index.md +1 -1
  45. package/dist/agentic/guides/modules/gateway_autopay/index.md +1 -1
  46. package/dist/agentic/guides/modules/gateway_stripe/index.md +1 -1
  47. package/dist/agentic/guides/modules/gateway_tpay/index.md +1 -1
  48. package/dist/agentic/guides/modules/generators/index.md +1 -1
  49. package/dist/agentic/guides/modules/inbox_ops/index.md +1 -1
  50. package/dist/agentic/guides/modules/integrations/index.md +1 -1
  51. package/dist/agentic/guides/modules/messages/index.md +1 -1
  52. package/dist/agentic/guides/modules/notifications/index.md +1 -1
  53. package/dist/agentic/guides/modules/onboarding/index.md +1 -1
  54. package/dist/agentic/guides/modules/payment_gateways/index.md +1 -1
  55. package/dist/agentic/guides/modules/perspectives/index.md +1 -1
  56. package/dist/agentic/guides/modules/phone_calls/index.md +1 -1
  57. package/dist/agentic/guides/modules/planner/index.md +1 -1
  58. package/dist/agentic/guides/modules/portal/index.md +1 -1
  59. package/dist/agentic/guides/modules/progress/index.md +1 -1
  60. package/dist/agentic/guides/modules/promotions/index.md +1 -1
  61. package/dist/agentic/guides/modules/push_notifications/index.md +1 -1
  62. package/dist/agentic/guides/modules/query_index/index.md +1 -1
  63. package/dist/agentic/guides/modules/record_locks/index.md +1 -1
  64. package/dist/agentic/guides/modules/resources/index.md +1 -1
  65. package/dist/agentic/guides/modules/sales/index.md +1 -1
  66. package/dist/agentic/guides/modules/scheduler/index.md +1 -1
  67. package/dist/agentic/guides/modules/search/index.md +1 -1
  68. package/dist/agentic/guides/modules/security/index.md +1 -1
  69. package/dist/agentic/guides/modules/seeds/index.md +1 -1
  70. package/dist/agentic/guides/modules/shipping_carriers/index.md +1 -1
  71. package/dist/agentic/guides/modules/sso/index.md +1 -1
  72. package/dist/agentic/guides/modules/staff/index.md +1 -1
  73. package/dist/agentic/guides/modules/storage_s3/index.md +1 -1
  74. package/dist/agentic/guides/modules/sync_akeneo/index.md +1 -1
  75. package/dist/agentic/guides/modules/sync_excel/index.md +1 -1
  76. package/dist/agentic/guides/modules/system_status_overlays/index.md +1 -1
  77. package/dist/agentic/guides/modules/telemetry/index.md +1 -1
  78. package/dist/agentic/guides/modules/tillio/index.md +1 -1
  79. package/dist/agentic/guides/modules/translations/index.md +1 -1
  80. package/dist/agentic/guides/modules/warranty_claims/index.md +1 -1
  81. package/dist/agentic/guides/modules/webhooks/index.md +1 -1
  82. package/dist/agentic/guides/modules/wms/index.md +1 -1
  83. package/dist/agentic/guides/modules/workflows/index.md +1 -1
  84. package/dist/agentic/guides/reference-module-facts.json +1 -1
  85. package/dist/agentic/guides/upstream/manifest.json +1 -1
  86. package/dist/lib/testing/integration.js +11 -4
  87. package/dist/lib/testing/integration.js.map +2 -2
  88. package/package.json +7 -7
  89. package/src/lib/testing/__tests__/integration.test.ts +31 -0
  90. package/src/lib/testing/integration.ts +11 -4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-mercato/cli",
3
- "version": "0.10.1-develop.8028.1.e3bfa74009",
3
+ "version": "0.10.1-develop.8033.1.a68811b809",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -60,10 +60,10 @@
60
60
  "@mikro-orm/decorators": "^7.1.14",
61
61
  "@mikro-orm/migrations": "^7.1.14",
62
62
  "@mikro-orm/postgresql": "^7.1.14",
63
- "@open-mercato/events": "0.10.1-develop.8028.1.e3bfa74009",
64
- "@open-mercato/queue": "0.10.1-develop.8028.1.e3bfa74009",
65
- "@open-mercato/shared": "0.10.1-develop.8028.1.e3bfa74009",
66
- "@open-mercato/telemetry": "0.10.1-develop.8028.1.e3bfa74009",
63
+ "@open-mercato/events": "0.10.1-develop.8033.1.a68811b809",
64
+ "@open-mercato/queue": "0.10.1-develop.8033.1.a68811b809",
65
+ "@open-mercato/shared": "0.10.1-develop.8033.1.a68811b809",
66
+ "@open-mercato/telemetry": "0.10.1-develop.8033.1.a68811b809",
67
67
  "cross-spawn": "^7.0.6",
68
68
  "minisearch": "7.2.0",
69
69
  "pg": "8.23.0",
@@ -75,10 +75,10 @@
75
75
  "typescript-js": "npm:typescript@6.0.3"
76
76
  },
77
77
  "peerDependencies": {
78
- "@open-mercato/shared": "0.10.1-develop.8028.1.e3bfa74009"
78
+ "@open-mercato/shared": "0.10.1-develop.8033.1.a68811b809"
79
79
  },
80
80
  "devDependencies": {
81
- "@open-mercato/shared": "0.10.1-develop.8028.1.e3bfa74009",
81
+ "@open-mercato/shared": "0.10.1-develop.8033.1.a68811b809",
82
82
  "@types/jest": "^30.0.0",
83
83
  "jest": "^30.4.2",
84
84
  "ts-jest": "^29.4.12"
@@ -28,6 +28,7 @@ import {
28
28
  killProcessTree,
29
29
  terminateProcessTree,
30
30
  registerEphemeralShutdownHandlers,
31
+ withoutCoverageEnvironment,
31
32
  } from '../integration'
32
33
  import type { CapturedOutputProcess, ShutdownProcessRef } from '../integration'
33
34
  import { resolveSpawnCommand } from '../../spawn'
@@ -1182,6 +1183,36 @@ describe('formatCapturedOutput', () => {
1182
1183
  })
1183
1184
  })
1184
1185
 
1186
+ describe('withoutCoverageEnvironment', () => {
1187
+ it('drops NODE_V8_COVERAGE and keeps every other key', () => {
1188
+ const environment: NodeJS.ProcessEnv = {
1189
+ NODE_V8_COVERAGE: '/tmp/coverage/raw',
1190
+ DATABASE_URL: 'postgres://localhost/test',
1191
+ NEXT_PUBLIC_FLAG: '1',
1192
+ }
1193
+
1194
+ expect(withoutCoverageEnvironment(environment)).toEqual({
1195
+ DATABASE_URL: 'postgres://localhost/test',
1196
+ NEXT_PUBLIC_FLAG: '1',
1197
+ })
1198
+ })
1199
+
1200
+ it('does not mutate the input environment', () => {
1201
+ const environment: NodeJS.ProcessEnv = { NODE_V8_COVERAGE: '/tmp/coverage/raw', PORT: '3000' }
1202
+
1203
+ const result = withoutCoverageEnvironment(environment)
1204
+
1205
+ expect(result).not.toBe(environment)
1206
+ expect(environment).toEqual({ NODE_V8_COVERAGE: '/tmp/coverage/raw', PORT: '3000' })
1207
+ })
1208
+
1209
+ it('returns an equal copy when coverage is not configured', () => {
1210
+ const environment: NodeJS.ProcessEnv = { PORT: '3000' }
1211
+
1212
+ expect(withoutCoverageEnvironment(environment)).toEqual({ PORT: '3000' })
1213
+ })
1214
+ })
1215
+
1185
1216
  describe('registerEphemeralShutdownHandlers', () => {
1186
1217
  const makeProcessRef = () => {
1187
1218
  const listeners = new Map<string, Array<() => void>>()
@@ -476,6 +476,12 @@ function buildEnvironment(overrides: NodeJS.ProcessEnv): NodeJS.ProcessEnv {
476
476
  }
477
477
  }
478
478
 
479
+ export function withoutCoverageEnvironment(environment: NodeJS.ProcessEnv): NodeJS.ProcessEnv {
480
+ const result: NodeJS.ProcessEnv = { ...environment }
481
+ delete result.NODE_V8_COVERAGE
482
+ return result
483
+ }
484
+
479
485
  function buildEnvironmentFingerprint(environment: NodeJS.ProcessEnv): string {
480
486
  const publicKeys = Object.keys(environment)
481
487
  .filter((key) => key.startsWith('NEXT_PUBLIC_'))
@@ -3769,6 +3775,7 @@ export async function startEphemeralEnvironment(options: EphemeralRuntimeOptions
3769
3775
  const appReadyTimeoutMs = resolveAppReadyTimeoutMs(options.logPrefix)
3770
3776
  const buildCacheTtlSeconds = resolveBuildCacheTtlSeconds(options.logPrefix)
3771
3777
  const environmentFingerprint = buildEnvironmentFingerprint(commandEnvironment)
3778
+ const buildToolEnvironment = withoutCoverageEnvironment(commandEnvironment)
3772
3779
  let sourceFingerprintValue: string | null = null
3773
3780
  let needsBuild = true
3774
3781
  let shouldPersistBuildCache = true
@@ -3811,7 +3818,7 @@ export async function startEphemeralEnvironment(options: EphemeralRuntimeOptions
3811
3818
  if (PROJECT_SUPPORTS_PACKAGE_BUILDS) {
3812
3819
  console.log(`[${options.logPrefix}] Building packages...`)
3813
3820
  await runTimedStep(options.logPrefix, 'Building packages', { expectedSeconds: 20 }, async () =>
3814
- runYarnCommand(['build:packages'], commandEnvironment, {
3821
+ runYarnCommand(['build:packages'], buildToolEnvironment, {
3815
3822
  silent: !options.verbose,
3816
3823
  }))
3817
3824
  } else {
@@ -3823,14 +3830,14 @@ export async function startEphemeralEnvironment(options: EphemeralRuntimeOptions
3823
3830
  force: true,
3824
3831
  })
3825
3832
  await runTimedStep(options.logPrefix, 'Regenerating module artifacts', { expectedSeconds: 8 }, async () =>
3826
- runYarnCommand(['generate'], commandEnvironment, {
3833
+ runYarnCommand(['generate'], buildToolEnvironment, {
3827
3834
  silent: !options.verbose,
3828
3835
  }, appDirectory))
3829
3836
 
3830
3837
  if (PROJECT_SUPPORTS_PACKAGE_BUILDS) {
3831
3838
  console.log(`[${options.logPrefix}] Rebuilding packages after generation...`)
3832
3839
  await runTimedStep(options.logPrefix, 'Rebuilding packages after generation', { expectedSeconds: 20 }, async () =>
3833
- runYarnCommand(['build:packages'], commandEnvironment, {
3840
+ runYarnCommand(['build:packages'], buildToolEnvironment, {
3834
3841
  silent: !options.verbose,
3835
3842
  }))
3836
3843
  }
@@ -3838,7 +3845,7 @@ export async function startEphemeralEnvironment(options: EphemeralRuntimeOptions
3838
3845
  console.log(`[${options.logPrefix}] Building application...`)
3839
3846
  await resetNextBuildOutputDirectories(options.logPrefix)
3840
3847
  await runTimedStep(options.logPrefix, 'Building application', { expectedSeconds: 76 }, async () =>
3841
- runYarnCommand(['build'], commandEnvironment, {
3848
+ runYarnCommand(['build'], buildToolEnvironment, {
3842
3849
  silent: !options.verbose,
3843
3850
  }, appDirectory))
3844
3851
  }