fix(workspace): canonicalize common-plat path to ../learning_ai_common_plat
Restores green build after the May 12 Docker/UI regression. Root cause: pnpm-workspace.yaml referenced a sibling path (../learning_ai/learning_ai_common_plat/...) that did not exist on dev/CI hosts. .pnpmfile.cjs fell back to ../learning_ai_common_plat for some packages but missed others, so @bytelyst/ui was pulled from a stale Gitea 0.1.0 tarball with zero exports (breaking web typecheck + 26 tests) and @bytelyst/monitoring was never linked into node_modules (breaking backend typecheck + 2 test suites). Changes: - pnpm-workspace.yaml now references ../learning_ai_common_plat/packages/* directly - .pnpmfile.cjs swaps DEFAULT/LEGACY common-plat roots so the canonical path is the default and the older nested path is the fallback - scripts/docker-prep.sh, scripts/local-smoke.sh, scripts/release-guard-audit.sh follow the same canonical-first / legacy-fallback pattern - .github/workflows/ci.yml symlinks directly to ../learning_ai_common_plat - pnpm-lock.yaml regenerated with @bytelyst/ui@0.1.9 and @bytelyst/monitoring@0.1.5 linked to the local common-plat checkout Verified: - pnpm run verify: backend 373/373, web 96/96, mobile 97/97 - pnpm run audit:release-guards: passes - backend, web, mobile lint all exit 0 (advisory warnings retained)
This commit is contained in:
parent
3dd981198e
commit
b2d824c8c6
18
.github/workflows/ci.yml
vendored
18
.github/workflows/ci.yml
vendored
@ -26,8 +26,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Link common-platform workspace path
|
- name: Link common-platform workspace path
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ../learning_ai
|
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai_common_plat
|
||||||
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai/learning_ai_common_plat
|
|
||||||
|
|
||||||
- name: Install audit tools
|
- name: Install audit tools
|
||||||
run: sudo apt-get update && sudo apt-get install -y ripgrep
|
run: sudo apt-get update && sudo apt-get install -y ripgrep
|
||||||
@ -50,8 +49,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Link common-platform workspace path
|
- name: Link common-platform workspace path
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ../learning_ai
|
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai_common_plat
|
||||||
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai/learning_ai_common_plat
|
|
||||||
|
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
@ -101,8 +99,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Link common-platform workspace path
|
- name: Link common-platform workspace path
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ../learning_ai
|
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai_common_plat
|
||||||
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai/learning_ai_common_plat
|
|
||||||
|
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
@ -150,8 +147,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Link common-platform workspace path
|
- name: Link common-platform workspace path
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ../learning_ai
|
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai_common_plat
|
||||||
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai/learning_ai_common_plat
|
|
||||||
|
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
@ -211,8 +207,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Link common-platform workspace path
|
- name: Link common-platform workspace path
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ../learning_ai
|
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai_common_plat
|
||||||
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai/learning_ai_common_plat
|
|
||||||
|
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
@ -273,8 +268,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Link common-platform workspace path
|
- name: Link common-platform workspace path
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ../learning_ai
|
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai_common_plat
|
||||||
ln -sfn "$GITHUB_WORKSPACE/learning_ai_common_plat" ../learning_ai/learning_ai_common_plat
|
|
||||||
|
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
|
|||||||
@ -3,8 +3,8 @@ const path = require('node:path');
|
|||||||
|
|
||||||
const PACKAGE_SCOPE = '@bytelyst/';
|
const PACKAGE_SCOPE = '@bytelyst/';
|
||||||
const PACKAGE_SOURCE = process.env.BYTELYST_PACKAGE_SOURCE || 'common-plat';
|
const PACKAGE_SOURCE = process.env.BYTELYST_PACKAGE_SOURCE || 'common-plat';
|
||||||
const DEFAULT_COMMON_PLAT_ROOT = path.resolve(__dirname, '..', 'learning_ai', 'learning_ai_common_plat');
|
const DEFAULT_COMMON_PLAT_ROOT = path.resolve(__dirname, '..', 'learning_ai_common_plat');
|
||||||
const LEGACY_COMMON_PLAT_ROOT = path.resolve(__dirname, '..', 'learning_ai_common_plat');
|
const LEGACY_COMMON_PLAT_ROOT = path.resolve(__dirname, '..', 'learning_ai', 'learning_ai_common_plat');
|
||||||
const COMMON_PLAT_ROOT =
|
const COMMON_PLAT_ROOT =
|
||||||
process.env.BYTELYST_COMMON_PLAT_ROOT ||
|
process.env.BYTELYST_COMMON_PLAT_ROOT ||
|
||||||
(fs.existsSync(DEFAULT_COMMON_PLAT_ROOT) ? DEFAULT_COMMON_PLAT_ROOT : LEGACY_COMMON_PLAT_ROOT);
|
(fs.existsSync(DEFAULT_COMMON_PLAT_ROOT) ? DEFAULT_COMMON_PLAT_ROOT : LEGACY_COMMON_PLAT_ROOT);
|
||||||
|
|||||||
5123
pnpm-lock.yaml
generated
5123
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@ -2,4 +2,4 @@ packages:
|
|||||||
- backend
|
- backend
|
||||||
- web
|
- web
|
||||||
- mobile
|
- mobile
|
||||||
- ../learning_ai/learning_ai_common_plat/packages/*
|
- ../learning_ai_common_plat/packages/*
|
||||||
|
|||||||
@ -10,9 +10,9 @@ set -euo pipefail
|
|||||||
|
|
||||||
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||||
REPO_DIR="$(cd "$SCRIPT_DIR/.." && pwd)"
|
REPO_DIR="$(cd "$SCRIPT_DIR/.." && pwd)"
|
||||||
COMMON_PLAT="${COMMON_PLAT:-${REPO_DIR}/../learning_ai/learning_ai_common_plat}"
|
COMMON_PLAT="${COMMON_PLAT:-${REPO_DIR}/../learning_ai_common_plat}"
|
||||||
if [[ ! -d "$COMMON_PLAT" && -d "${REPO_DIR}/../learning_ai_common_plat" ]]; then
|
if [[ ! -d "$COMMON_PLAT" && -d "${REPO_DIR}/../learning_ai/learning_ai_common_plat" ]]; then
|
||||||
COMMON_PLAT="${REPO_DIR}/../learning_ai_common_plat"
|
COMMON_PLAT="${REPO_DIR}/../learning_ai/learning_ai_common_plat"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
TARBALL_DIR="${REPO_DIR}/.docker-deps"
|
TARBALL_DIR="${REPO_DIR}/.docker-deps"
|
||||||
|
|||||||
@ -2,7 +2,10 @@
|
|||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
||||||
COMMON_PLAT_DIR="${COMMON_PLAT_DIR:-${ROOT_DIR}/../learning_ai/learning_ai_common_plat}"
|
COMMON_PLAT_DIR="${COMMON_PLAT_DIR:-${ROOT_DIR}/../learning_ai_common_plat}"
|
||||||
|
if [[ ! -d "$COMMON_PLAT_DIR" && -d "${ROOT_DIR}/../learning_ai/learning_ai_common_plat" ]]; then
|
||||||
|
COMMON_PLAT_DIR="${ROOT_DIR}/../learning_ai/learning_ai_common_plat"
|
||||||
|
fi
|
||||||
|
|
||||||
NOTELETT_URL="${NOTELETT_URL:-http://localhost:4016}"
|
NOTELETT_URL="${NOTELETT_URL:-http://localhost:4016}"
|
||||||
NOTELETT_API_URL="${NOTELETT_API_URL:-${NOTELETT_URL}/api}"
|
NOTELETT_API_URL="${NOTELETT_API_URL:-${NOTELETT_URL}/api}"
|
||||||
|
|||||||
@ -6,9 +6,9 @@ set -euo pipefail
|
|||||||
ROOT="$(git rev-parse --show-toplevel)"
|
ROOT="$(git rev-parse --show-toplevel)"
|
||||||
cd "$ROOT"
|
cd "$ROOT"
|
||||||
|
|
||||||
COMMON_PLAT="${COMMON_PLAT:-$ROOT/../learning_ai/learning_ai_common_plat}"
|
COMMON_PLAT="${COMMON_PLAT:-$ROOT/../learning_ai_common_plat}"
|
||||||
if [[ ! -d "$COMMON_PLAT" && -d "$ROOT/../learning_ai_common_plat" ]]; then
|
if [[ ! -d "$COMMON_PLAT" && -d "$ROOT/../learning_ai/learning_ai_common_plat" ]]; then
|
||||||
COMMON_PLAT="$ROOT/../learning_ai_common_plat"
|
COMMON_PLAT="$ROOT/../learning_ai/learning_ai_common_plat"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "=== Secret scan ==="
|
echo "=== Secret scan ==="
|
||||||
|
|||||||
2
web/next-env.d.ts
vendored
2
web/next-env.d.ts
vendored
@ -1,6 +1,6 @@
|
|||||||
/// <reference types="next" />
|
/// <reference types="next" />
|
||||||
/// <reference types="next/image-types/global" />
|
/// <reference types="next/image-types/global" />
|
||||||
import "./.next/dev/types/routes.d.ts";
|
import "./.next/types/routes.d.ts";
|
||||||
|
|
||||||
// NOTE: This file should not be edited
|
// NOTE: This file should not be edited
|
||||||
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
|
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user