@omega.js/backend 0.1.0 → 0.50.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.
@@ -550,6 +550,11 @@ const SESSION_PATH = 'sessions/app';
550
550
  * @param {object} accounts - Every account definition, keyed (referrals name real personas)
551
551
  * @returns {Array|null} The persona's `affiliate.referrals`, or null when it referred nobody
552
552
  */
553
+ // One derivation per assembled table: the inbound half (buildInboundReferral)
554
+ // reads the SAME records the referrer carries, so both halves wear one stamp.
555
+ // A second build would call Date.now() again and disagree by a millisecond.
556
+ const REFERRAL_FIXTURES = new WeakMap();
557
+
553
558
  function buildReferralFixtures(key, accounts) {
554
559
  const referred = PERSONA_REFERRALS[key];
555
560
 
@@ -557,7 +562,18 @@ function buildReferralFixtures(key, accounts) {
557
562
  return null;
558
563
  }
559
564
 
560
- return referred.map((referredKey, index) => {
565
+ let perTable = REFERRAL_FIXTURES.get(accounts);
566
+
567
+ if (!perTable) {
568
+ perTable = new Map();
569
+ REFERRAL_FIXTURES.set(accounts, perTable);
570
+ }
571
+
572
+ if (perTable.has(key)) {
573
+ return perTable.get(key);
574
+ }
575
+
576
+ const referrals = referred.map((referredKey, index) => {
561
577
  const account = accounts[referredKey];
562
578
 
563
579
  // A referral pointing at nobody is a uid the emulator cannot resolve — the
@@ -571,6 +587,10 @@ function buildReferralFixtures(key, accounts) {
571
587
  timestamp: getDaysAgo(REFERRAL_DAYS_AGO[index % REFERRAL_DAYS_AGO.length]).timestamp,
572
588
  };
573
589
  });
590
+
591
+ perTable.set(key, referrals);
592
+
593
+ return referrals;
574
594
  }
575
595
 
576
596
  /**
@@ -1,9 +1,11 @@
1
1
  # Publishing — the runbook
2
2
 
3
- > The publish-proving checkpoint's script. Nothing here runs without Ian's explicit GO
4
- > (standing rule: zero npm publishes / GitHub releases until then). The latch is
5
- > mechanical: all seven publishables carry `private: true` npm itself refuses until
6
- > the unlatch step below.
3
+ > The publish-proving checkpoint's script, run for real on 2026-09-09: the seven
4
+ > publishables are on the registry ([#25](https://github.com/Omega-JS-Stack/omega/issues/25)) at 0.50.0, the
5
+ > monorepo's own number (0.1.0 went out first that night and is deprecated: the family
6
+ > carries ONE version, the root package.json's, by ruling 2026-09-10),
7
+ > each with `publishConfig.access: public`, and published is the new normal. The unlatch
8
+ > step below is history; versions move by changesets from here.
7
9
 
8
10
  ## What publishes, what never does
9
11
 
@@ -22,8 +24,9 @@ installable beside it — a real dependency, never vendored. It ships no docs tr
22
24
  plugin's launcher can deep-resolve `@omega.js/mcp-router/bin/mcp-router.js`.
23
25
 
24
26
  Registry-real internal ranges (everything else is workspace `*`): `@omega.js/client`
25
- `0.1.0` in backend/web/desktop/extension; `@omega.js/backend` and `@omega.js/mcp-router`
26
- `0.1.0` in manager — EXACT, not carets, because the family is lockstep (below).
27
+ in backend/web/desktop/extension; `@omega.js/backend` and `@omega.js/mcp-router` in
28
+ manager — the EXACT family version (0.50.0 today), not carets, because the family is
29
+ lockstep (below).
27
30
 
28
31
  ## Lockstep — the family ships ONE version ([#794](https://github.com/Omega-JS-Stack/omega/issues/794))
29
32
 
@@ -151,19 +154,18 @@ circumventing license-key functionality and removing notices.
151
154
  `VENDORABLE_PACKAGES` in [packages/devkit/tools/vendor.js](../../packages/devkit/tools/vendor.js)
152
155
  names them, so the list is never re-typed here).
153
156
  2. **Publish** each (changesets is configured lockstep + `access: public`, so the
154
- seven go out at ONE number; for the FIRST 0.1.0 the direct form per package is
155
- equally fine):
157
+ seven go out at ONE number; the direct form per package is equally fine):
156
158
  `npm publish --workspace=packages/<name>` — order matters only where a dependent
157
159
  waits on a dependency: **client and backend before their dependents**
158
160
  (web/desktop/extension need client on the registry; manager needs backend and
159
161
  mcp-router). Safe order: client → backend → mcp-router → extension → desktop →
160
- web → manager. 2FA/OTP prompts surface here on first publish.
162
+ web → manager.
161
163
  3. **Verify from the outside**: in an empty temp dir, `npm install @omega.js/web`
162
164
  (and one more, e.g. manager) — install + `require.resolve` must succeed with no
163
165
  overrides. That is the moment the untested-lane risk is retired.
164
- 4. **Flip omega-brand to registry specs**: from the brand root,
165
- `npx omega i live` — tree-wide `file:` → the EXACT `0.1.0` pin + one registry
166
- install (`restoreRegistrySpecs` writes the linked copy's version with no
166
+ 4. **Flip omega-brand to registry specs**: from any TARGET root (`targets/website`;
167
+ the manager has no `i` verb), `npx omega i live` — tree-wide `file:` → the EXACT
168
+ family pin + one registry install (`restoreRegistrySpecs` writes the linked copy's version with no
167
169
  caret, because the family is lockstep; `omega i local` is the way back for
168
170
  local-era work). Commit the brand's manifest+lock change.
169
171
  5. **Brand proof**: brand `npm run manage` (manage cycle) + a website build — the brand
@@ -178,6 +180,8 @@ circumventing license-key functionality and removing notices.
178
180
  changes bump minor and consumers move deliberately. A BRAND floats nothing: the
179
181
  manager pins every target exactly, so `omega update` is the one thing that moves
180
182
  a brand, and it moves the whole family ([updates.md](updates.md)).
181
- - 1.0.0 is a later, deliberate graduation (Ian's call), not an accumulation.
183
+ - **1.0.0 is NEVER published without Ian's explicit word** (ruling 2026-09-10): it is the
184
+ official release, and it waits until OMEGA has survived on its own with Ian's brands.
185
+ Every number below it is free to publish whenever he wants.
182
186
  - The publish is also the brand-CI-build unlock: no tarball vendoring exists by
183
187
  design — the registry is the lane CI installs from.
@@ -31,8 +31,8 @@ Only rows needing attention print; a fully-current tree reports one line. Rows s
31
31
  ## The @omega.js family is pinned, and `omega update` is its ONE mover ([#794](https://github.com/Omega-JS-Stack/omega/issues/794))
32
32
 
33
33
  Every `@omega.js/*` spec the manager writes into a brand is an EXACT pin, never a
34
- caret: `"@omega.js/manager": "0.1.0"` at the brand root, `"@omega.js/<framework>":
35
- "0.1.0"` in each target, all at the manager's own version (the family ships
34
+ caret: `"@omega.js/manager": "0.50.0"` at the brand root, `"@omega.js/<framework>":
35
+ "0.50.0"` in each target, all at the manager's own version (the family ships
36
36
  lockstep — [publishing.md](publishing.md)). A caret would let one target float
37
37
  ahead alone on somebody's `npm update`, which is how a brand ends up serving two
38
38
  copies of `@omega.js/client` and validating one omega.json5 with two validators.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@omega.js/backend",
3
- "version": "0.1.0",
3
+ "version": "0.50.0",
4
4
  "description": "OMEGA backend framework — build, test, and deploy Firebase Cloud Functions backends",
5
5
  "private": false,
6
6
  "publishConfig": {
@@ -88,7 +88,7 @@
88
88
  "@inquirer/prompts": "^8.5.2",
89
89
  "@modelcontextprotocol/sdk": "^1.29.0",
90
90
  "@octokit/rest": "^22.0.1",
91
- "@omega.js/client": "0.1.0",
91
+ "@omega.js/client": "0.50.0",
92
92
  "@resvg/resvg-js": "^2.6.2",
93
93
  "@sendgrid/mail": "^8.1.6",
94
94
  "@sentry/node": "^10.54.0",