@beignet/cli 0.0.33 → 0.0.34

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/CHANGELOG.md CHANGED
@@ -1,5 +1,16 @@
1
1
  # @beignet/cli
2
2
 
3
+ ## 0.0.34
4
+
5
+ ### Patch Changes
6
+
7
+ - 8226b4c: Isolate notification channel failures, add app-owned preference checks, provide independently retryable queued delivery through existing job dispatchers, and document the app structure for queued notification workers.
8
+ - 479a383: Warn when hand-authored tenant-owned Drizzle repository ports expose raw `workspaceId` methods in addition to raw `tenantId` methods.
9
+ - 9345cc9: Stabilize the pre-1.0 public surface around factory-only providers, canonical server and testing imports, consistent memory naming, and the removal of deprecated aliases.
10
+ - Updated dependencies [8226b4c]
11
+ - Updated dependencies [9345cc9]
12
+ - @beignet/core@0.0.34
13
+
3
14
  ## 0.0.33
4
15
 
5
16
  ### Patch Changes
package/README.md CHANGED
@@ -568,7 +568,7 @@ The command writes `features/posts/policy.ts` with a `definePolicy(...)` starter
568
568
  Register the policy with `createGate(...)`, install the gate as a port, and
569
569
  bind it into request context so use cases can call `ctx.gate.authorize(...)`.
570
570
  For tenant, ownership, or role-heavy rules, add a matrix test with
571
- `createPolicyTester(...)` from `@beignet/core/ports/testing`.
571
+ `createPolicyTester(...)` from `@beignet/core/testing`.
572
572
 
573
573
  ## Generate a port adapter
574
574
 
@@ -622,13 +622,13 @@ writes with a branded `TenantScope`; generated use cases call
622
622
  `requireTenantScope(ctx)`, repository ports require `scope: TenantScope`, and
623
623
  adapters unwrap the storage key with `tenantScopeId(scope)`. `doctor --strict`
624
624
  also warns when tenant-scoped generated repositories lose that boundary, when
625
- hand-authored Drizzle ports expose raw `tenantId` app-facing methods, or when
626
- scoped adapters stop using `tenantScopeId(scope)` predicates. Use `--events` to
627
- generate created, updated, and deleted domain events and publish them through
628
- `ctx.ports.eventBus`. The
625
+ hand-authored Drizzle ports expose raw `tenantId` or `workspaceId` app-facing
626
+ methods, or when scoped adapters stop using `tenantScopeId(scope)` predicates.
627
+ Use `--events` to generate created, updated, and deleted domain events and
628
+ publish them through `ctx.ports.eventBus`. The
629
629
  starter ships no event bus, so `--events` also wires one: it adds
630
630
  `eventBus: EventBusPort` to `AppPorts`, defers the key in
631
- `infra/app-ports.ts`, registers `createInMemoryEventBusProvider()` in
631
+ `infra/app-ports.ts`, registers `createMemoryEventBusProvider()` in
632
632
  `server/providers.ts`, and adds the `@beignet/provider-event-bus-memory`
633
633
  dependency. The wiring is skipped when the ports file already mentions
634
634
  `eventBus`, so apps that wired their own bus are left untouched. Use
@@ -684,7 +684,7 @@ reports events and jobs the registry cannot deliver.
684
684
 
685
685
  Generators wire the provider-backed ports their output depends on. `make
686
686
  event` (and `make resource --events`) wires `eventBus: EventBusPort` with
687
- `createInMemoryEventBusProvider()` from
687
+ `createMemoryEventBusProvider()` from
688
688
  `@beignet/provider-event-bus-memory`, including the package dependency.
689
689
  `make notification` wires `mailer: MailerPort` with
690
690
  `createMemoryMailerProvider()` and `notifications: NotificationPort` with
package/dist/inspect.js CHANGED
@@ -1495,7 +1495,7 @@ async function inspectPaymentsProductionReadiness(targetDir, files, config, sour
1495
1495
  severity: "warning",
1496
1496
  code: "BEIGNET_PAYMENTS_STRIPE_MEMORY_PROVIDER",
1497
1497
  file: serverProviderFiles(files, config)[0] ?? config.paths.server,
1498
- message: "@beignet/provider-payments-stripe is installed and Stripe env/config is present, but server/providers.ts still registers memory payments. Register stripePaymentsProvider before deploying Stripe-backed billing, or remove the Stripe provider/config until the app is ready to switch.",
1498
+ message: "@beignet/provider-payments-stripe is installed and Stripe env/config is present, but server/providers.ts still registers memory payments. Register createStripePaymentsProvider() before deploying Stripe-backed billing, or remove the Stripe provider/config until the app is ready to switch.",
1499
1499
  });
1500
1500
  }
1501
1501
  if (!(await hasPaymentWebhookRoute(targetDir, files, config, sourceCache))) {
@@ -1551,7 +1551,8 @@ async function hasStripeMemoryProviderMismatch(targetDir, sourceCache, configFil
1551
1551
  if (!installedPackages.has("@beignet/provider-payments-stripe")) {
1552
1552
  return false;
1553
1553
  }
1554
- if (findProviderEntryIndex(providerEntries, ["stripePaymentsProvider"]) >= 0) {
1554
+ if (findProviderEntryIndex(providerEntries, ["createStripePaymentsProvider"]) >=
1555
+ 0) {
1555
1556
  return false;
1556
1557
  }
1557
1558
  if (findProviderEntryIndex(providerEntries, [
@@ -2935,7 +2936,7 @@ async function inspectTenantScopeRepositoryDrift(targetDir, files, resources, co
2935
2936
  severity: "warning",
2936
2937
  code: "BEIGNET_TENANT_SCOPE_RAW_ID_BOUNDARY",
2937
2938
  file: portFile,
2938
- message: `${portFile} declares tenant-owned repository methods (${rawBoundaries.join(", ")}) with raw tenant IDs. Use TenantScope at app-facing repository boundaries and unwrap it with tenantScopeId(scope) inside ${repositoryFile}; keep provider-correlation lookups separate from authorization.`,
2939
+ message: `${portFile} declares tenant-owned repository methods (${rawBoundaries.join(", ")}) with raw tenant or workspace IDs. Use TenantScope at app-facing repository boundaries and unwrap it with tenantScopeId(scope) inside ${repositoryFile}; keep provider-correlation lookups separate from authorization.`,
2939
2940
  });
2940
2941
  continue;
2941
2942
  }
@@ -3030,7 +3031,7 @@ function rawTenantRepositoryMethodBoundaries(block, tables) {
3030
3031
  for (const method of repositoryMethodSignatures(block)) {
3031
3032
  if (isProviderCorrelationMethod(method.name))
3032
3033
  continue;
3033
- const rawColumns = tenantColumnsUsedInSource(method.params, tables).filter((column) => column.property === "tenantId");
3034
+ const rawColumns = tenantColumnsUsedInSource(method.params, tables);
3034
3035
  if (rawColumns.length === 0)
3035
3036
  continue;
3036
3037
  rawMethods.push(method.name);