Skip to content

Commit 5dabb79

Browse files
chore: version packages (rc)
1 parent d6a756f commit 5dabb79

7 files changed

Lines changed: 95 additions & 7 deletions

File tree

‎.changeset/pre.json‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,16 @@
3131
"atomic-deploys-phase-a",
3232
"atomic-deploys-phase-a2",
3333
"atomic-port-block-allocation",
34+
"auth-admin-organization-member-direct",
3435
"auth-better-auth-1.7",
3536
"auth-cookie-secure-baseurl",
37+
"auth-cross-subdomain-cookies",
3638
"auth-dts-any-collapse-guard",
3739
"auth-fail-closed",
3840
"auth-isproduction-origin",
3941
"auth-login-regressions",
4042
"auth-mirror-ui-port",
43+
"auth-personal-organization-duplicates",
4144
"auth-plugin-route-loader-graceful",
4245
"auth-rate-limit-ipaddress-config",
4346
"auth-remote-name-resolution",
@@ -168,6 +171,7 @@
168171
"effect-idiom-cleanup",
169172
"effect-native-plugins",
170173
"effect4-orpc-v2-migration",
174+
"every-plugin-context-guard",
171175
"every-plugin-declare-runtime-deps",
172176
"every-plugin-dev-generated-rspack-config",
173177
"every-plugin-error-formatting",
@@ -198,6 +202,7 @@
198202
"fresh-clone-dev-flow",
199203
"handler-cleanup",
200204
"hermetic-boot",
205+
"host-pin-boot-drift",
201206
"hosting-adapter-seam",
202207
"http-cache-bound",
203208
"i18n-seam-enforcement",
@@ -290,7 +295,6 @@
290295
"registry-use-command",
291296
"registry-wire-cutover",
292297
"regression-harness-344-residue",
293-
"regression-pglite-dirs",
294298
"regression-silent-failure-hardening",
295299
"regression-teardown-stall-fix",
296300
"relayer-key-self-heal",
@@ -305,6 +309,7 @@
305309
"remove-org-approval",
306310
"resolution-session",
307311
"restore-v1-core-sharing-set",
312+
"revert-regression-pglite-dirs",
308313
"root-template-catalog-parity",
309314
"route-tree-ui-workspace",
310315
"router-error-details-opt-out",

‎packages/every-plugin/CHANGELOG.md‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# every-plugin
22

3+
## 3.0.0-rc.18
4+
5+
### Patch Changes
6+
7+
- 59cfe70: Plugin client factories warn at construction time in development when the caller omits context keys the plugin's declared context schema marks required — naming the keys and the deep failure the omission would cause. The auth plugin's credential-less in-process client now fails with a message that names the missing `reqHeaders` forwarding instead of generic auth-required prose, and the plugin's declared context marks `reqHeaders` as required so typed registries surface the omission at compile time (#860 stage 1, #882).
8+
39
## 3.0.0-rc.17
410

511
### Minor Changes

‎packages/every-plugin/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "every-plugin",
3-
"version": "3.0.0-rc.17",
3+
"version": "3.0.0-rc.18",
44
"type": "module",
55
"publishConfig": {
66
"access": "public"

‎packages/everything-dev/CHANGELOG.md‎

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,82 @@
11
# everything-dev
22

3+
## 2.0.0-rc.44
4+
5+
### Patch Changes
6+
7+
- 07765ba: auth: admin member management no longer depends on the admin's own organization membership (#876 follow-up)
8+
9+
`adminAddMember` forwarded the caller's headers into Better Auth's `addMember`, which checks the
10+
caller's **organization** permissions — so a platform admin who was not a member of the target
11+
organization (the whole point of an admin route) got FORBIDDEN. The mutation is now a direct write,
12+
like every other mutation in `AdminOrganizationsService`: it enforces the organization membership
13+
limit through the plugin's membership policy and refuses duplicate memberships. The integration
14+
suite now covers adding a member to an organization the admin does not belong to — the case the
15+
previous tests masked by creating every fixture organization owned by the admin.
16+
17+
Two smaller consistency fixes ride along:
18+
19+
- `adminUpdateMemberRole` refuses to demote an organization's **only owner** to a non-owner role,
20+
matching `adminRemoveMember`'s existing last-owner guard.
21+
- `getOrganizationForAdmin` guards with the standard `requireAdmin` middleware instead of a
22+
hand-rolled role check, matching the admin routes' pattern.
23+
24+
`crossSubDomainCookies` (#668) also gained config-time warnings for the two ways a shared cookie
25+
domain fails silently at the browser: a `domain` that does not cover the app's own `baseUrl` host
26+
(browsers drop the cookie outright, breaking sign-in) and localhost/loopback base URLs (browsers
27+
refuse `Domain` attributes there). The auth plugin README now documents the full multi-app recipe —
28+
shared cookie domain + shared `BETTER_AUTH_SECRET` + shared `postgres://` `AUTH_DATABASE_URL` —
29+
mirroring the ADR 0027 decomposition.
30+
31+
- a19b559: Auth plugin surfaces cross-subdomain cookie configuration (#668). New authored variable under `auth.variables`: `crossSubDomainCookies: { enabled, domain }`, mapped to Better Auth's `advanced.crossSubDomainCookies`. When enabled, session cookies carry `Domain=<domain>` so a multi-app family on sibling subdomains (`app.example.com`, `activity.example.com`) shares one session — by config alone, no local auth code. `domain` must be a dot-prefixed registrable domain (`.example.com`) when enabled; without it Better Auth falls back to the base URL's root domain. Absent or disabled config leaves cookies host-scoped (behavior unchanged). Sharing a cookie domain requires every app on it to run the same `BETTER_AUTH_SECRET` — the sealed cookie is decrypted with it — plus sibling `trustedOrigins` entries.
32+
- ed70afd: auth: stop creating duplicate personal organizations when metadata or slug drifts off the canonical form (#877)
33+
34+
`findPersonalOrganization` matched only the byte-exact pair `slug = userId AND metadata = '{"isPersonal":true}'`,
35+
while the lenient `isPersonalOrganization()` predicate accepted either signal. An organization whose metadata
36+
was non-canonical JSON (pretty-printed, extra keys) or whose slug had been renamed was invisible to the finder,
37+
so the `user.create` hook silently created a second personal organization on the next signup/session — observed
38+
in production as users with multiple personal orgs plus dangling `user.last_active_organization_id` /
39+
`session.active_organization_id` pointers.
40+
41+
The finder now resolves the personal organization with the lenient signals:
42+
43+
- `slug = userId` (unchanged), or
44+
- metadata containing a top-level `"isPersonal": true` flag **and** the user holds a membership in that organization.
45+
46+
Matches are deterministic (`created_at asc, id asc`, limit 1), so historical duplicates converge on the oldest row
47+
instead of generating new ones. `ensurePersonalOrganization` still writes the canonical metadata string on create;
48+
nothing about creation changes.
49+
50+
Two deliberate hardenings beyond the literal issue proposal:
51+
52+
- The metadata signal is matched with a text pattern, not `metadata::jsonb->>'isPersonal'`. The column is
53+
`text` and better-auth stores raw strings when callers pass non-object metadata, so a bare cast would throw
54+
on malformed rows — inside the `user.create` hook, that breaks every signup on the deployment.
55+
- The metadata branch is bound to the user through a membership check. An unbounded `metadata isPersonal OR slug`
56+
predicate would let any user's lookup match any other user's personal-flagged organization.
57+
58+
The orphan sweep keeps its strict canonical-only deletion query on purpose: widening it to the lenient signals
59+
would delete non-canonical organizations that may hold user data.
60+
61+
- 9da8ed9: Boot the pinned host, not the parent's newest bytes (#874): the orchestrator
62+
resolves the host slot's `digest` and registers the manifest from the pin's
63+
immutable coordinates — a root publish can no longer move the host bytes a
64+
pinned child boots. `mf check` probes the same pin. When a pinned host's
65+
shared singletons still cannot resolve in the image, the boot fails with the
66+
skew named — image version, pin, and `bos upgrade && bos deploy` — instead of
67+
a bare package error.
68+
- 350beba: Revert the regression harness's file-backed pglite substitution: the dev stack
69+
opens the auth database from two processes (the auth service and the auth-plugin
70+
instance composed into the api/host), and a per-secret shared data dir turned
71+
that topology into ADR 0044's silent-corruption case — the suite died on
72+
system-catalog reads past EOF (`pg_attribute`, "unexpected data beyond EOF").
73+
The harness is restored to in-memory pglite, whose per-process databases made
74+
the dual-open harmless. App fixtures for regression specs still seed over HTTP;
75+
a file-backed mode needs a single-writer story first (seed through the running
76+
stack, not pre-spawn against shared files).
77+
- Updated dependencies [59cfe70]
78+
- every-plugin@3.0.0-rc.18
79+
380
## 2.0.0-rc.43
481

582
### Minor Changes

‎packages/everything-dev/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "everything-dev",
3-
"version": "2.0.0-rc.43",
3+
"version": "2.0.0-rc.44",
44
"type": "module",
55
"engines": {
66
"node": ">=20.11"

‎packages/everything-dev/src/services/scaffold/upgrade-audit/steps/v2-catalog.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,8 @@ export const V2_CATALOG: Readonly<Record<string, string>> = {
6565
"drizzle-kit": "^0.31.11",
6666
"drizzle-orm": "^0.45.4",
6767
effect: "4.0.0-rc.118",
68-
"every-plugin": "^3.0.0-rc.17",
69-
"everything-dev": "^2.0.0-rc.43",
68+
"every-plugin": "^3.0.0-rc.18",
69+
"everything-dev": "^2.0.0-rc.44",
7070
"near-kit": "^0.20.2",
7171
pg: "^8.12.0",
7272
react: "19.3.1",

‎pnpm-workspace.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,8 @@ catalog:
6868
drizzle-kit: ^0.31.11
6969
drizzle-orm: ^0.45.4
7070
effect: 4.0.0-rc.118
71-
every-plugin: ^3.0.0-rc.17
72-
everything-dev: ^2.0.0-rc.43
71+
every-plugin: ^3.0.0-rc.18
72+
everything-dev: ^2.0.0-rc.44
7373
near-kit: ^0.20.2
7474
pg: ^8.12.0
7575
react: 19.3.1

0 commit comments

Comments
 (0)