Compare commits

...

7 Commits

Author SHA1 Message Date
Guido D'Orsi
11dcfd703d Merge pull request #2616 from garden-co/changeset-release/main
Version Packages
2025-07-07 18:16:58 +02:00
github-actions[bot]
879b726537 Version Packages 2025-07-07 16:06:32 +00:00
Guido D'Orsi
66bbd03262 Merge pull request #2614 from garden-co/fix/inspector-element
fix: react bundling in jazz-tools/inspector/register-custom-element
2025-07-07 18:04:30 +02:00
Guido D'Orsi
c09b63698f fix: react bundling in jazz-tools/inspector/register-custom-element 2025-07-07 18:03:18 +02:00
Guido D'Orsi
700a4f1ba1 fix: restore sync url in todo main 2025-07-07 16:46:18 +02:00
Guido D'Orsi
844cdc907f Merge pull request #2612 from garden-co/chore/playwright-tests
perf(ci): batch the e2e tests execution in 2 workflow runs
2025-07-07 16:02:45 +02:00
Guido D'Orsi
9e32d4cb92 perf(ci): batch the e2e tests execution in 2 workflow runs 2025-07-07 16:01:12 +02:00
34 changed files with 254 additions and 113 deletions

View File

@@ -1,52 +0,0 @@
name: Playwright Tests - Homepage
concurrency:
# For pushes, this lets concurrent runs happen, so each push gets a result.
# But for other events (e.g. PRs), we can cancel the previous runs.
group: ${{ github.workflow }}-${{ github.event_name == 'push' && github.sha || github.ref }}
cancel-in-progress: true
on:
push:
branches: ["main"]
pull_request:
types: [opened, synchronize, reopened]
jobs:
test:
timeout-minutes: 60
runs-on: blacksmith-4vcpu-ubuntu-2404
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Setup Source Code
uses: ./.github/actions/source-code/
- name: Install root dependencies
run: pnpm install && pnpm exec turbo build --filter="./packages/*"
- name: Install project dependencies
run: pnpm install
working-directory: ./homepage/homepage
- name: Pnpm Build
run: pnpm exec turbo build
working-directory: ./homepage/homepage
- name: Install Playwright Browsers
run: pnpm exec playwright install
working-directory: ./homepage/homepage
- name: Run Playwright tests
run: pnpm exec playwright test
working-directory: ./homepage/homepage
- uses: actions/upload-artifact@v4
if: failure()
with:
name: homepage-playwright-report
path: ./homepage/homepage/playwright-report/
retention-days: 30

View File

@@ -19,21 +19,7 @@ jobs:
continue-on-error: true
strategy:
matrix:
project: [
"tests/e2e",
"examples/chat",
"examples/chat-svelte",
"examples/clerk",
"examples/betterauth",
"examples/file-share-svelte",
"examples/form",
"examples/inspector",
"examples/music-player",
"examples/organization",
"starters/react-passkey-auth",
"starters/svelte-passkey-auth",
"tests/jazz-svelte"
]
shard: ["1/2", "2/2"]
steps:
- uses: actions/checkout@v4
@@ -43,25 +29,129 @@ jobs:
- name: Setup Source Code
uses: ./.github/actions/source-code/
- name: Pnpm Build
run: |
if [ -f .env.test ]; then
cp .env.test .env
fi
pnpm turbo build
working-directory: ./${{ matrix.project }}
- name: Install Playwright Browsers
run: pnpm exec playwright install
working-directory: ./${{ matrix.project }}
- name: Run Playwright tests
run: pnpm exec playwright test
working-directory: ./${{ matrix.project }}
- uses: actions/upload-artifact@v4
if: failure()
with:
name: ${{ hashFiles(format('{0}/package.json', matrix.project)) }}-playwright-report
path: ./${{ matrix.project }}/playwright-report/
retention-days: 30
- name: Run Playwright tests for shard ${{ matrix.shard }}
run: |
# Parse shard information (e.g., "1/2" -> shard_num=1, total_shards=2)
IFS='/' read -r shard_num total_shards <<< "${{ matrix.shard }}"
shard_index=$((shard_num - 1)) # Convert to 0-based index
# Debug: Print parsed values
echo "Parsed shard_num: $shard_num"
echo "Parsed total_shards: $total_shards"
echo "Calculated shard_index: $shard_index"
# Define all projects to test
all_projects=(
"tests/e2e"
"examples/chat"
"examples/chat-svelte"
"examples/clerk"
"examples/betterauth"
"examples/file-share-svelte"
"examples/form"
"examples/inspector"
"examples/music-player"
"examples/organization"
"starters/react-passkey-auth"
"starters/svelte-passkey-auth"
"tests/jazz-svelte"
)
# Calculate which projects this shard should run
shard_projects=()
for i in "${!all_projects[@]}"; do
if [ $((i % total_shards)) -eq $shard_index ]; then
shard_projects+=("${all_projects[i]}")
fi
done
# Track project results
overall_exit_code=0
failed_projects=()
passed_projects=()
echo "=== Running tests for shard ${{ matrix.shard }} ==="
echo "Projects in this shard:"
printf '%s\n' "${shard_projects[@]}"
echo
# Run tests for each project
for project in "${shard_projects[@]}"; do
echo "=== Testing project: $project ==="
# Check if project directory exists
if [ ! -d "$project" ]; then
echo "❌ FAILED: Project directory $project does not exist"
failed_projects+=("$project (directory not found)")
overall_exit_code=1
continue
fi
# Check if project has package.json
if [ ! -f "$project/package.json" ]; then
echo "❌ FAILED: No package.json found in $project"
failed_projects+=("$project (no package.json)")
overall_exit_code=1
continue
fi
# Build the project
echo "🔨 Building $project..."
cd "$project"
if [ -f .env.test ]; then
cp .env.test .env
fi
if ! pnpm turbo build; then
echo "❌ BUILD FAILED: $project"
failed_projects+=("$project (build failed)")
overall_exit_code=1
cd - > /dev/null
continue
fi
# Run Playwright tests
echo "🧪 Running Playwright tests for $project..."
if ! pnpm exec playwright test; then
echo "❌ TESTS FAILED: $project"
failed_projects+=("$project (tests failed)")
overall_exit_code=1
else
echo "✅ TESTS PASSED: $project"
passed_projects+=("$project")
fi
cd - > /dev/null
echo "=== Finished testing $project ==="
echo
done
# Print summary report
echo "=========================================="
echo "📊 TEST SUMMARY FOR SHARD ${{ matrix.shard }}"
echo "=========================================="
if [ ${#passed_projects[@]} -gt 0 ]; then
echo "✅ PASSED (${#passed_projects[@]}):"
printf ' - %s\n' "${passed_projects[@]}"
echo
fi
if [ ${#failed_projects[@]} -gt 0 ]; then
echo "❌ FAILED (${#failed_projects[@]}):"
printf ' - %s\n' "${failed_projects[@]}"
echo
fi
echo "Total projects in shard: ${#shard_projects[@]}"
echo "Passed: ${#passed_projects[@]}"
echo "Failed: ${#failed_projects[@]}"
echo "=========================================="
# Exit with overall status
exit $overall_exit_code

View File

@@ -1,5 +1,12 @@
# passkey-svelte
## 0.0.96
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
## 0.0.95
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "chat-svelte",
"version": "0.0.95",
"version": "0.0.96",
"type": "module",
"private": true,
"scripts": {

View File

@@ -17,6 +17,7 @@ import React from "react";
import { TodoAccount, TodoProject } from "./1_schema.ts";
import { NewProjectForm } from "./3_NewProjectForm.tsx";
import { ProjectTodoTable } from "./4_ProjectTodoTable.tsx";
import { apiKey } from "./apiKey.ts";
import {
Button,
ThemeProvider,
@@ -41,7 +42,7 @@ function JazzAndAuth({ children }: { children: React.ReactNode }) {
return (
<JazzReactProvider
sync={{
peer: `ws://localhost:4200`,
peer: `wss://cloud.jazz.tools/?key=${apiKey}`,
}}
AccountSchema={TodoAccount}
>

View File

@@ -1,5 +1,12 @@
# cojson-storage-indexeddb
## 0.15.7
### Patch Changes
- cojson@0.15.7
- cojson-storage@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "cojson-storage-indexeddb",
"version": "0.15.6",
"version": "0.15.7",
"main": "dist/index.js",
"type": "module",
"types": "dist/index.d.ts",

View File

@@ -1,5 +1,12 @@
# cojson-storage-sqlite
## 0.15.7
### Patch Changes
- cojson@0.15.7
- cojson-storage@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,13 +1,13 @@
{
"name": "cojson-storage-sqlite",
"type": "module",
"version": "0.15.6",
"version": "0.15.7",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"license": "MIT",
"dependencies": {
"better-sqlite3": "^11.7.0",
"cojson": "workspace:0.15.6",
"cojson": "workspace:0.15.7",
"cojson-storage": "workspace:*"
},
"devDependencies": {

View File

@@ -1,5 +1,11 @@
# cojson-storage
## 0.15.7
### Patch Changes
- cojson@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "cojson-storage",
"version": "0.15.6",
"version": "0.15.7",
"main": "dist/index.js",
"type": "module",
"types": "dist/index.d.ts",

View File

@@ -1,5 +1,11 @@
# cojson-transport-nodejs-ws
## 0.15.7
### Patch Changes
- cojson@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,7 +1,7 @@
{
"name": "cojson-transport-ws",
"type": "module",
"version": "0.15.6",
"version": "0.15.7",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"license": "MIT",

View File

@@ -1,5 +1,7 @@
# cojson
## 0.15.7
## 0.15.6
## 0.15.5

View File

@@ -25,7 +25,7 @@
},
"type": "module",
"license": "MIT",
"version": "0.15.6",
"version": "0.15.7",
"devDependencies": {
"@opentelemetry/sdk-metrics": "^2.0.0",
"typescript": "catalog:"

View File

@@ -1,5 +1,14 @@
# jazz-auth-betterauth
## 0.15.7
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
- jazz-betterauth-client-plugin@0.15.7
- cojson@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "jazz-auth-betterauth",
"version": "0.15.6",
"version": "0.15.7",
"type": "module",
"main": "dist/index.js",
"types": "src/index.ts",

View File

@@ -1,5 +1,11 @@
# jazz-betterauth-client-plugin
## 0.15.7
### Patch Changes
- jazz-betterauth-server-plugin@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "jazz-betterauth-client-plugin",
"version": "0.15.6",
"version": "0.15.7",
"type": "module",
"main": "dist/index.js",
"types": "src/index.ts",

View File

@@ -1,5 +1,13 @@
# jazz-betterauth-server-plugin
## 0.15.7
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
- cojson@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "jazz-betterauth-server-plugin",
"version": "0.15.6",
"version": "0.15.7",
"type": "module",
"main": "dist/index.js",
"types": "src/index.ts",

View File

@@ -1,5 +1,15 @@
# jazz-react-auth-betterauth
## 0.15.7
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
- jazz-auth-betterauth@0.15.7
- jazz-betterauth-client-plugin@0.15.7
- cojson@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "jazz-react-auth-betterauth",
"version": "0.15.6",
"version": "0.15.7",
"type": "module",
"main": "dist/index.js",
"types": "src/index.tsx",

View File

@@ -1,5 +1,15 @@
# jazz-run
## 0.15.7
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
- cojson@0.15.7
- cojson-storage-sqlite@0.15.7
- cojson-transport-ws@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -3,7 +3,7 @@
"bin": "./dist/index.js",
"type": "module",
"license": "MIT",
"version": "0.15.6",
"version": "0.15.7",
"exports": {
"./startSyncServer": {
"import": "./dist/startSyncServer.js",
@@ -28,11 +28,11 @@
"@effect/printer-ansi": "^0.34.5",
"@effect/schema": "^0.71.1",
"@effect/typeclass": "^0.25.5",
"cojson": "workspace:0.15.6",
"cojson-storage-sqlite": "workspace:0.15.6",
"cojson-transport-ws": "workspace:0.15.6",
"cojson": "workspace:0.15.7",
"cojson-storage-sqlite": "workspace:0.15.7",
"cojson-transport-ws": "workspace:0.15.7",
"effect": "^3.6.5",
"jazz-tools": "workspace:0.15.6",
"jazz-tools": "workspace:0.15.7",
"ws": "^8.14.2"
},
"devDependencies": {

View File

@@ -1,5 +1,15 @@
# jazz-tools
## 0.15.7
### Patch Changes
- c09b636: Fix react bundling in jazz-tools/inspector/register-custom-element
- cojson@0.15.7
- cojson-storage@0.15.7
- cojson-storage-indexeddb@0.15.7
- cojson-transport-ws@0.15.7
## 0.15.6
### Patch Changes

View File

@@ -139,7 +139,7 @@
},
"type": "module",
"license": "MIT",
"version": "0.15.6",
"version": "0.15.7",
"dependencies": {
"@manuscripts/prosemirror-recreate-steps": "^0.1.4",
"@scure/base": "1.2.1",

View File

@@ -1,6 +1,6 @@
import { Account } from "jazz-tools";
import { JazzInspectorInternal } from "jazz-tools/inspector";
import { createRoot } from "react-dom/client";
import { JazzInspectorInternal } from "./index.js";
export class JazzInspectorElement extends HTMLElement {
private root: ReturnType<typeof createRoot> | null = null;

View File

@@ -60,7 +60,7 @@ export default defineConfig([
"register-custom-element": "src/inspector/register-custom-element.ts",
},
// This is a custom element meant to be used on non-react apps
noExternal: ["react", "react-dom"],
noExternal: ["react", "react-dom", "react-dom/client", "react/jsx-runtime"],
outDir: "dist/inspector",
},
{

10
pnpm-lock.yaml generated
View File

@@ -1620,7 +1620,7 @@ importers:
specifier: ^11.7.0
version: 11.10.0
cojson:
specifier: workspace:0.15.6
specifier: workspace:0.15.7
version: link:../cojson
cojson-storage:
specifier: workspace:*
@@ -1797,19 +1797,19 @@ importers:
specifier: ^0.25.5
version: 0.25.8(effect@3.11.9)
cojson:
specifier: workspace:0.15.6
specifier: workspace:0.15.7
version: link:../cojson
cojson-storage-sqlite:
specifier: workspace:0.15.6
specifier: workspace:0.15.7
version: link:../cojson-storage-sqlite
cojson-transport-ws:
specifier: workspace:0.15.6
specifier: workspace:0.15.7
version: link:../cojson-transport-ws
effect:
specifier: ^3.6.5
version: 3.11.9
jazz-tools:
specifier: workspace:0.15.6
specifier: workspace:0.15.7
version: link:../jazz-tools
ws:
specifier: ^8.14.2

View File

@@ -1,5 +1,12 @@
# jazz-react-tailwind-starter
## 0.0.127
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
## 0.0.126
### Patch Changes

View File

@@ -1,7 +1,7 @@
{
"name": "jazz-react-passkey-auth-starter",
"private": true,
"version": "0.0.126",
"version": "0.0.127",
"type": "module",
"scripts": {
"dev": "vite",

View File

@@ -1,5 +1,12 @@
# svelte-passkey-auth
## 0.0.101
### Patch Changes
- Updated dependencies [c09b636]
- jazz-tools@0.15.7
## 0.0.100
### Patch Changes

View File

@@ -1,6 +1,6 @@
{
"name": "svelte-passkey-auth",
"version": "0.0.100",
"version": "0.0.101",
"type": "module",
"private": true,
"scripts": {