@wildo-ai/wildo-cli 1.1.12 → 1.1.13

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 (102) hide show
  1. package/dist/src/commands/config/sync.command.d.ts.map +1 -1
  2. package/dist/src/commands/config/sync.command.js +1 -0
  3. package/dist/src/commands/config/sync.command.js.map +1 -1
  4. package/dist/src/commands/context/journey.command.d.ts.map +1 -1
  5. package/dist/src/commands/context/journey.command.js +8 -0
  6. package/dist/src/commands/context/journey.command.js.map +1 -1
  7. package/dist/src/commands/creation/drive.command.d.ts.map +1 -1
  8. package/dist/src/commands/creation/drive.command.js +2 -0
  9. package/dist/src/commands/creation/drive.command.js.map +1 -1
  10. package/dist/src/commands/fwk/publish-all.command.d.ts.map +1 -1
  11. package/dist/src/commands/fwk/publish-all.command.js +8 -0
  12. package/dist/src/commands/fwk/publish-all.command.js.map +1 -1
  13. package/dist/src/commands/local/dev.command.d.ts +68 -0
  14. package/dist/src/commands/local/dev.command.d.ts.map +1 -1
  15. package/dist/src/commands/local/dev.command.js +216 -8
  16. package/dist/src/commands/local/dev.command.js.map +1 -1
  17. package/dist/src/commands/local/doctor.command.d.ts +22 -9
  18. package/dist/src/commands/local/doctor.command.d.ts.map +1 -1
  19. package/dist/src/commands/local/doctor.command.js +45 -42
  20. package/dist/src/commands/local/doctor.command.js.map +1 -1
  21. package/dist/src/commands/providers/connect.command.d.ts.map +1 -1
  22. package/dist/src/commands/providers/connect.command.js +11 -1
  23. package/dist/src/commands/providers/connect.command.js.map +1 -1
  24. package/dist/src/commands/seal/currency.command.d.ts +13 -0
  25. package/dist/src/commands/seal/currency.command.d.ts.map +1 -0
  26. package/dist/src/commands/seal/currency.command.js +52 -0
  27. package/dist/src/commands/seal/currency.command.js.map +1 -0
  28. package/dist/src/commands/seal/seal-admin-door.utils.d.ts.map +1 -1
  29. package/dist/src/commands/seal/seal-admin-door.utils.js +2 -0
  30. package/dist/src/commands/seal/seal-admin-door.utils.js.map +1 -1
  31. package/dist/src/commands/seal/verify.command.d.ts +5 -0
  32. package/dist/src/commands/seal/verify.command.d.ts.map +1 -1
  33. package/dist/src/commands/seal/verify.command.js +26 -2
  34. package/dist/src/commands/seal/verify.command.js.map +1 -1
  35. package/dist/src/services/application/content-guardrail-classifier.service.d.ts +19 -0
  36. package/dist/src/services/application/content-guardrail-classifier.service.d.ts.map +1 -1
  37. package/dist/src/services/application/content-guardrail-classifier.service.js +75 -11
  38. package/dist/src/services/application/content-guardrail-classifier.service.js.map +1 -1
  39. package/dist/src/services/application/local-provider-doubles.service.d.ts +98 -0
  40. package/dist/src/services/application/local-provider-doubles.service.d.ts.map +1 -0
  41. package/dist/src/services/application/local-provider-doubles.service.js +214 -0
  42. package/dist/src/services/application/local-provider-doubles.service.js.map +1 -0
  43. package/dist/src/services/application/system-of-record-simulators.service.d.ts +21 -2
  44. package/dist/src/services/application/system-of-record-simulators.service.d.ts.map +1 -1
  45. package/dist/src/services/application/system-of-record-simulators.service.js +21 -12
  46. package/dist/src/services/application/system-of-record-simulators.service.js.map +1 -1
  47. package/dist/src/services/companion/creation-drive.service.d.ts +32 -2
  48. package/dist/src/services/companion/creation-drive.service.d.ts.map +1 -1
  49. package/dist/src/services/companion/creation-drive.service.js +61 -4
  50. package/dist/src/services/companion/creation-drive.service.js.map +1 -1
  51. package/dist/src/services/credentials/credentials.schemas.d.ts +6 -0
  52. package/dist/src/services/credentials/credentials.schemas.d.ts.map +1 -1
  53. package/dist/src/services/credentials/credentials.schemas.js +7 -1
  54. package/dist/src/services/credentials/credentials.schemas.js.map +1 -1
  55. package/dist/src/services/credentials/provider-env-vars.utils.d.ts.map +1 -1
  56. package/dist/src/services/credentials/provider-env-vars.utils.js +11 -3
  57. package/dist/src/services/credentials/provider-env-vars.utils.js.map +1 -1
  58. package/dist/src/services/data-services/data-services.schemas.d.ts +9 -0
  59. package/dist/src/services/data-services/data-services.schemas.d.ts.map +1 -1
  60. package/dist/src/services/data-services/data-services.schemas.js +9 -0
  61. package/dist/src/services/data-services/data-services.schemas.js.map +1 -1
  62. package/dist/src/services/deployment/docker/docker-compose-generator.service.d.ts.map +1 -1
  63. package/dist/src/services/deployment/docker/docker-compose-generator.service.js +7 -2
  64. package/dist/src/services/deployment/docker/docker-compose-generator.service.js.map +1 -1
  65. package/dist/src/services/deployment/local-dev-session-lease.service.d.ts.map +1 -1
  66. package/dist/src/services/deployment/local-dev-session-lease.service.js +22 -1
  67. package/dist/src/services/deployment/local-dev-session-lease.service.js.map +1 -1
  68. package/dist/src/services/environment/authored-infra-config.utils.d.ts.map +1 -1
  69. package/dist/src/services/environment/authored-infra-config.utils.js +1 -0
  70. package/dist/src/services/environment/authored-infra-config.utils.js.map +1 -1
  71. package/dist/src/services/environment/authored-infra-member-authority.d.ts.map +1 -1
  72. package/dist/src/services/environment/authored-infra-member-authority.js +5 -0
  73. package/dist/src/services/environment/authored-infra-member-authority.js.map +1 -1
  74. package/dist/src/services/environment/env-configuration-generator.service.d.ts.map +1 -1
  75. package/dist/src/services/environment/env-configuration-generator.service.js +6 -3
  76. package/dist/src/services/environment/env-configuration-generator.service.js.map +1 -1
  77. package/dist/src/services/environment/env-vars-builder.service.d.ts +6 -0
  78. package/dist/src/services/environment/env-vars-builder.service.d.ts.map +1 -1
  79. package/dist/src/services/environment/env-vars-builder.service.js +24 -1
  80. package/dist/src/services/environment/env-vars-builder.service.js.map +1 -1
  81. package/dist/src/services/environment/environment-hydration.utils.d.ts.map +1 -1
  82. package/dist/src/services/environment/environment-hydration.utils.js +1 -0
  83. package/dist/src/services/environment/environment-hydration.utils.js.map +1 -1
  84. package/dist/src/services/environment/environment.schemas.d.ts +7 -1
  85. package/dist/src/services/environment/environment.schemas.d.ts.map +1 -1
  86. package/dist/src/services/environment/environment.schemas.js.map +1 -1
  87. package/dist/src/services/environment/runtime-bootstrap.service.d.ts +2 -0
  88. package/dist/src/services/environment/runtime-bootstrap.service.d.ts.map +1 -1
  89. package/dist/src/services/environment/runtime-bootstrap.service.js +4 -0
  90. package/dist/src/services/environment/runtime-bootstrap.service.js.map +1 -1
  91. package/dist/src/services/framework/framework-docker-publish.service.d.ts +13 -0
  92. package/dist/src/services/framework/framework-docker-publish.service.d.ts.map +1 -1
  93. package/dist/src/services/framework/framework-docker-publish.service.js +24 -7
  94. package/dist/src/services/framework/framework-docker-publish.service.js.map +1 -1
  95. package/dist/src/services/registry/provider-connect.service.d.ts +57 -1
  96. package/dist/src/services/registry/provider-connect.service.d.ts.map +1 -1
  97. package/dist/src/services/registry/provider-connect.service.js +63 -2
  98. package/dist/src/services/registry/provider-connect.service.js.map +1 -1
  99. package/dist/tsconfig.build.tsbuildinfo +1 -1
  100. package/package.json +18 -18
  101. package/scripts/app-dependency-alignment/propagated-engine-overrides.json +1 -1
  102. package/wildo-framework.info.json +1 -1
@@ -56,15 +56,17 @@
56
56
  * into the platform `.env` files; confirms creds match what the
57
57
  * container actually has.
58
58
  * 5. Valkey admin auth — same.
59
- * 6. **Stale per-app users** — enumerate Mongo `admin.system.users`
60
- * and Valkey ACL entries; flag every non-canonical-admin entry.
61
- * These persist across `local up`/`local down` cycles and across
62
- * `wildo_platform` database drops; when the apps-manager generates
63
- * new derived passwords, the stale entries cause `WRONGPASS` on
64
- * Redis or `MongoServerError: Authentication failed` on Mongo.
65
- * `wildo local reset` would wipe them along with all data; this
66
- * diagnostic merely surfaces them with a surgical-fix command
67
- * string.
59
+ * 6. **Application users** — enumerate Mongo `admin.system.users`
60
+ * and Valkey ACL entries that the platform does not own, and LIST them.
61
+ * Leftovers of a removed application persist across `local up`/`local
62
+ * down` cycles and across `wildo_platform` database drops, and can
63
+ * surface as `WRONGPASS` or `Authentication failed`. But every
64
+ * registered application has users of its own here too, and the
65
+ * doctor reads no registration, so it cannot tell a leftover from a
66
+ * live one: the check is informational and suggests no deletion
67
+ * (#3704 — it used to WARN on every healthy stack and print a command
68
+ * that would drop the running application's own user and the mongot
69
+ * sync user).
68
70
  * 7. Platform services HTTP — apps-manager (5151), crontabs-batches-
69
71
  * manager (5152) `/health` responses.
70
72
  * 8. Companion semantic readiness — companion (4341) `/health/ready` if the active
@@ -93,6 +95,7 @@ import { BaseCommand } from '../../kernel/base-command.js';
93
95
  import { DockerUtils } from '../../services/deployment/docker/docker.service.js';
94
96
  import { CommandCategory } from '../../kernel/types.js';
95
97
  import { ErrorUtils } from '../../infrastructure/errors/error.utils.js';
98
+ import { MONGOT_SYNC_SOURCE } from '../../services/data-services/data-services.schemas.js';
96
99
  import { WildoDeploymentRuntime, WildoLocationType } from '@wildo-ai/platform-config-lib';
97
100
  import { collectCreationPreflightChecks } from '../../services/application/creation-preflight.service.js';
98
101
  import { aiUseDeclarationsCheck, assessApplicationAiUseDeclarations, readAgentAiUseDeclarationsFromCompanion, } from '../../services/application/ai-use-declarations.service.js';
@@ -100,7 +103,7 @@ import { resolveCompanionClientOptionsFromContext } from '../../services/compani
100
103
  import { readFrontendProviderKeyReportOnDisk } from '../../services/application/frontend-providers-not-configured.service.js';
101
104
  import { describeFrontendProviderNotConfigured } from '@wildo-ai/saas-models';
102
105
  import { checkSpecificationFindings, collectLocalPreconditionChecks, readSpecificationFindingsFromCompanion, } from '../../services/deployment/local-precondition-checks.service.js';
103
- import { CONTENT_GUARDRAIL_CLASSIFIER_CHECK_NAME, EnvironmentProviderEnvReadingKind, contentGuardrailClassifierCheck, guardedAgentRefs, readEnvironmentClassifiers, readEnvironmentProviderEnv, } from '../../services/application/content-guardrail-classifier.service.js';
106
+ import { CONTENT_GUARDRAIL_CLASSIFIER_CHECK_NAME, EnvironmentProviderEnvReadingKind, contentGuardrailClassifierCheck, guardedAgentRefs, guardrailsDeclaredBy, readEnvironmentClassifiers, readEnvironmentProviderEnv, } from '../../services/application/content-guardrail-classifier.service.js';
104
107
  import { getComposedProviderSecretsCatalogue, resolveAndRegisterSaasProviderContributions } from '../../services/credentials/composed-provider-catalogue.js';
105
108
  import { collectProviderConfigurationChecks } from '../../services/registry/provider-configuration-checks.service.js';
106
109
  import { settleAllAuthoredInfraEnvConfigs } from '../../services/environment/authored-infra-config.utils.js';
@@ -114,7 +117,27 @@ import { StoredDeclarationCurrency, StoredDeclarationCurrencyService, } from '..
114
117
  // Canonical admin user names baked into the framework's container images.
115
118
  // Anything else in the user/ACL list is a per-app (or scoped) entry
116
119
  // that's a candidate for the stale-credentials class of failure.
117
- const CANONICAL_MONGO_ADMINS = new Set(['wildo']);
120
+ /** MongoDB users the PLATFORM owns: its root, and the identity mongot syncs as (#3704). */
121
+ const CANONICAL_MONGO_ADMINS = new Set(['wildo', MONGOT_SYNC_SOURCE.USERNAME]);
122
+ /**
123
+ * The doctor's report of the users in a platform data service that the platform does not own (#3704).
124
+ *
125
+ * Informational on purpose. Each registered application has users of its own in these services, and the doctor reads no
126
+ * registration, so it cannot tell a live application's user from a leftover of a removed one. It used to WARN on every
127
+ * healthy stack and print a command dropping each user — including the running application's own and the mongot sync
128
+ * user, which would have broken the application and search — with the platform admin password inline, which `--json`
129
+ * output then carried into a CI artifact. So: no status above PASS, no suggested deletion, no credential.
130
+ */
131
+ export function describeApplicationDataServiceUsers(name, users) {
132
+ return {
133
+ name,
134
+ status: LocalPreconditionCheckStatus.PASS,
135
+ detail: users.length === 0
136
+ ? '(none besides the platform\'s own)'
137
+ : `${users.length} not owned by the platform: ${users.join(', ')} — each belongs to a registered application or is `
138
+ + 'left over from a removed one; check the registration before removing any',
139
+ };
140
+ }
118
141
  const CANONICAL_VALKEY_ACL_USERS = new Set(['default']);
119
142
  /**
120
143
  * Containers ALLOWED to run non-native, because no native image exists upstream.
@@ -356,6 +379,7 @@ export default class LocalDoctorCommand extends BaseCommand {
356
379
  */
357
380
  async checkContentGuardrailClassifier(saasRoot, read) {
358
381
  const guardedAgents = 'agents' in read ? guardedAgentRefs(read.agents) : undefined;
382
+ const guardrailsNeeded = 'agents' in read ? guardrailsDeclaredBy(read.agents) : undefined;
359
383
  const notReadBecause = 'notReadBecause' in read
360
384
  ? read.notReadBecause
361
385
  : guardedAgents === undefined ? 'the dev companion\'s agent reading predates the guardrail fields; redeliver the companion' : undefined;
@@ -381,7 +405,12 @@ export default class LocalDoctorCommand extends BaseCommand {
381
405
  return readEnvironmentProviderEnv(path);
382
406
  },
383
407
  });
384
- return contentGuardrailClassifierCheck({ readings, guardedAgents, ...(notReadBecause ? { agentsNotReadBecause: notReadBecause } : {}) });
408
+ return contentGuardrailClassifierCheck({
409
+ readings,
410
+ guardedAgents,
411
+ ...(guardrailsNeeded ? { guardrailsNeeded } : {}),
412
+ ...(notReadBecause ? { agentsNotReadBecause: notReadBecause } : {}),
413
+ });
385
414
  }
386
415
  catch (error) {
387
416
  return {
@@ -602,24 +631,11 @@ export default class LocalDoctorCommand extends BaseCommand {
602
631
  });
603
632
  return results;
604
633
  }
605
- // Stale per-app users.
634
+ // Users the platform does not own: listed, never judged (#3704).
606
635
  try {
607
636
  const out = execSync(`docker exec wildo-mongodb mongosh "mongodb://${creds.user}:${creds.pass}@localhost:27017/admin?directConnection=true" --quiet --eval 'JSON.stringify(db.getSiblingDB("admin").system.users.find({}, {user:1, _id:0}).toArray())'`, { encoding: 'utf-8', stdio: 'pipe' }).trim();
608
637
  const users = JSON.parse(out);
609
- const stale = users.map((u) => u.user).filter((u) => !CANONICAL_MONGO_ADMINS.has(u));
610
- if (stale.length === 0) {
611
- results.push({ name: 'mongo per-app users', status: LocalPreconditionCheckStatus.PASS, detail: '(no stale entries)' });
612
- }
613
- else {
614
- results.push({
615
- name: 'mongo per-app users',
616
- status: LocalPreconditionCheckStatus.WARN,
617
- detail: `${stale.length} non-canonical user(s): ${stale.join(', ')}`,
618
- fix: stale
619
- .map((u) => `docker exec wildo-mongodb mongosh "mongodb://${creds.user}:${creds.pass}@localhost:27017/admin?directConnection=true" --quiet --eval 'db.getSiblingDB("admin").dropUser("${u}")'`)
620
- .join(' && '),
621
- });
622
- }
638
+ results.push(describeApplicationDataServiceUsers('mongo application users', users.map((u) => u.user).filter((u) => !CANONICAL_MONGO_ADMINS.has(u))));
623
639
  }
624
640
  catch {
625
641
  // best-effort
@@ -721,7 +737,7 @@ export default class LocalDoctorCommand extends BaseCommand {
721
737
  });
722
738
  return results;
723
739
  }
724
- // Stale per-app ACL entries.
740
+ // ACL users the platform does not own: listed, never judged (#3704).
725
741
  try {
726
742
  const out = execSync(`docker exec wildo-valkey valkey-cli -a '${password.replace(/'/g, "'\\''")}' ACL LIST`, { encoding: 'utf-8', stdio: 'pipe' });
727
743
  const names = out
@@ -730,20 +746,7 @@ export default class LocalDoctorCommand extends BaseCommand {
730
746
  .filter((line) => line.startsWith('user '))
731
747
  .map((line) => line.split(/\s+/)[1])
732
748
  .filter((n) => Boolean(n));
733
- const stale = names.filter((n) => !CANONICAL_VALKEY_ACL_USERS.has(n));
734
- if (stale.length === 0) {
735
- results.push({ name: 'valkey per-app ACLs', status: LocalPreconditionCheckStatus.PASS, detail: '(no stale entries)' });
736
- }
737
- else {
738
- results.push({
739
- name: 'valkey per-app ACLs',
740
- status: LocalPreconditionCheckStatus.WARN,
741
- detail: `${stale.length} non-canonical ACL(s): ${stale.join(', ')}`,
742
- fix: stale
743
- .map((u) => `docker exec wildo-valkey valkey-cli -a '<VALKEY_PASSWORD>' ACL DELUSER ${u}`)
744
- .join(' && '),
745
- });
746
- }
749
+ results.push(describeApplicationDataServiceUsers('valkey application ACLs', names.filter((n) => !CANONICAL_VALKEY_ACL_USERS.has(n))));
747
750
  }
748
751
  catch {
749
752
  // best-effort