Commit Graph
959 Commits
Author SHA1 Message Date
DarkSky a6bb03e702 feat(editor): restore 0.27.5 mobile keyboard toolbar, native previews, and fold CRDT codecs 2026-11-27 08:18:25 +09:00
DarkSky 65a2c9b097 refactor(mobile): remove duplicated logic across store and hosts
Remove eight duplicated or defensive code paths across affine-store,
affine-client, affine-mobile, and the web, iOS, and Android hosts:

- Remove explicit create recovery journals in store and client, and
  require WorkspaceDb::from_root_update_v1 to receive initial db$*
  tables at construction time instead of returning DbTableNotResolved.
- Consolidate auth protocol parsing, url::Url canonicalization,
  legacy_storage_endpoint_key (unbracketed IPv6 for 0.27.5 storage
  keys), chrono RFC3339 UTC Z normalization, Bearer checks, and
  permanent error codes into affine_store::auth while keeping iOS and
  Android 0.27.5 storage formats.
- Replace the duplicated legacy storage engine in affine-ios-host with
  affine-legacy-import, preserve malformed affine-local-workspace raw
  strings in one place, propagate iOS write-back serialization errors,
  delegate Android sentinel evaluation and probe filtering to Rust via
  a single JNI entry, and remove hardcoded Swift and Kotlin key lists.
- Remove the pure JS Yjs v1 decoder from hosts/web/src/idb-storage.js,
  expose a safe Rust wasm-codec cdylib from affine-store reusing
  merge_crdt_updates_v1, share a strict wasm-scalar-rpc.js loader with
  preview workers, wire crdt-wasm-client through index.html,
  worker-loader, host.js, stage-preview-workers, CI, and real-browser
  IDB E2E, and migrate real Yjs v1 fixtures to affine-store tests.
- Remove the 12-iteration blind SQLite retry loop in sqlite/doc.rs
  while preserving single-row empty-update registration.
- Upgrade SqliteDocStorage::checkpoint_passive to return WAL counts and
  remove duplicate maintenance pools from iOS and Android hosts.
- Remove top-level mirrored workspace fields and workspace-switch
  cloning in MobileAppState, and use generate_key_between for ordering.
- Remove pixel-fallback selection drag paths in iOS and Android hosts
  so text-layout endpoints remain the single drag authority.
2026-11-27 06:55:48 +09:00
DarkSky e88ee8e9fe feat(web): add GPU recovery, canvas selection menu, lazy PDF client, and zero-3p-JS gate
Add WebGL2 context loss recovery, epoch-guarded async restore, single-flight fallback locking, and WebGPU canvas compositing to the Web Mobile host.
Flush pending IndexedDB writes before legacy shell navigation and recreate a visible retry banner on flush failure.

Add canvas-drawn selection highlights, teardrop handles, pointerup action triggers, and selection-guarded clipboard actions.
Add a lazy hayro PDF worker client with crash recovery, clamped scale rendering, transfer-safe deduplication, and asset root pinning.
Add a static zero-third-party-JS gate script and wire both web host gates into mobile CI.
2026-11-27 06:55:48 +09:00
DarkSky 9a3195bf81 feat(mobile): add S3 mobile shell, breadcrumb engine, and outbound doc refs
Implement the S3-Shell deliverables across L1 to L4:
- Add read-only outbound document reference extraction in `blocksuite/crates/doc/src/refs.rs` with zero-writeback tests.
- Add baked keyframe micro-icons, domain-neutral Breadcrumb layout, and RTL mirror tests in `packages/ui/kit`.
- Add sanitized FolderForest caching, NavHistory with 128-entry cap, pure breadcrumb derivation, and LinkGraph backlinks in `packages/frontend/client`.
- Add `affine-mobile` with interactive 4-TabBar routes, 10-section Settings, Location and Trail sheet, and `mobile-harness`.
2026-11-27 06:55:48 +09:00
DarkSky 0036df69b5 fix(frontend): close S2.1 parity gaps across editor, web, and CI
Close the S2.1 parity and review items across the editor, web host,
and CI workflows.

- Add affine:latex block layout and the equation editor popover.
- Support Space and Enter triggers, inline rendering, click-to-edit
  chips, IME commit on Done, and Web slash copy.
- Guard open equations with zero-width CRDT identity checks and skip
  writes when closing an unchanged equation.

- Align web sign-in OTP validation, resend state, anti-reentry,
  cross-Back cooldown, preflight races, and initial OTP errors.
- Align step-bound email submit, deployment Terms display, and native
  Chromium discovery in verify-idb-real-browser.

- Key WebTextSystem Canvas fallback descriptors by logical font ID so
  static single-face fonts preserve requested weights.
- Keep Release LTO active for s1-probes-bench in np-mobile.yml.
2026-11-27 06:55:48 +09:00
DarkSky 698c268e3a feat(android-host): implement S2 Android surface, SQLite co-storage, and auth bridge
Upgrade the thin Android host from S1 to S2 across four areas:

- Present real pixel frames via NDK EGL/GLES3 (`glClear` + `eglSwapBuffers`)
  with automatic `EGLSurface` teardown and `CpuFallback` downgrade when EGL
  is unavailable, retaining `pending_frame` on failure until a frame presents.
  Full `wgpu` Vulkan-to-GLES3 rendering lands in `S3-Android`.
- Open in-place `0.27.5` SQLite WAL databases through `affine-store` with
  `busy_timeout = 5000ms` and `onStop()` `PASSIVE` checkpoints. Gate local
  workspaces by the ordered `affine-local-workspace` allowlist with zero disk
  scanning, evict unlisted local handles on shrink, and allow cloud workspaces
  and userspaces directly.
- Implement a file-locked atomic Jetpack Preferences DataStore protobuf codec
  with zero silent corruption wipes, single-lock `getOrCreateInstallationId`,
  pure-Kotlin RFC 4648 Base64 for API 24+, `v1:` AES-GCM envelopes, process-wide
  single-flight `refreshSession` with idempotent `x-affine-refresh-attempt`
  reuse and disk-write retry caching, a default `HttpUrlConnectionRefreshTransport`
  sending `refreshToken` only in the JSON body, `INTERNET` manifest permission,
  and exact `0.27.5` three-cookie plus `affine.preferences_pb` auth cleanup.
- Wire `AndroidBootstrapCoordinator` in `MainActivity.onCreate` with unified
  `WebViewStorageSentinel` validation, active `indexedDB` interception,
  lossless raw preservation of malformed workspace lists, and explicit partial
  mount failure reporting with allowlist-synced retry and write-back gating.
2026-11-27 06:55:48 +09:00
DarkSky b1fdf08a73 feat(web-host): add IDB v3/V1 bridge, auth routes, and a11y tree
Add the same-origin IndexedDB v3 (12 object stores, frozen version 3),
V1 read-only fallback, and BroadcastChannel bridge in `src/idb-storage.js`.
Keep local workspace enumeration strictly on `localStorage['affine-local-workspace']`
and commit pending CRDT writes before navigation or handoff.

Complete standalone authentication routes (`/sign-in`, `/magic-link`,
`/oauth/*`, `/redirect-proxy`, and `/open-app/*`) in `src/sign-in.js`
with `x-affine-client-kind: web`, double-submit CSRF headers, single-use
code guards, and on-demand Turnstile loading.

Add the first-frame write-only ARIA semantic subtree in `src/a11y.js`
with incremental attribute patching and mutual focus exclusion across
`#a11y-tree`, `#ime`, and `#embed-layer`.
2026-11-27 06:55:48 +09:00
DarkSky ed72cca4a3 feat(mobile): deliver S1 thin hosts, Mermaid font measurer, and release probes
Add thin Web, iOS, and Android mobile hosts, harden the blocksuite-preview
Mermaid renderer and Wasm exports, and add S1 release performance probes
with CI artifact and native host linking gates.

- Preview: use FontPoolWidthMeasurer with variable-font HVAR weight
  instantiation, integer pixel ceil widths, front-matter theme injection,
  high-contrast Light and Dark palettes, premultiplied RGBA PNG compositing,
  and Wasm theme parameters.
- Probes and CI: add s1_sqlite_probe and s1_probes release tests, record
  measured latency and peak RSS in BENCHMARK.md, add timeout-minutes on all
  np-mobile jobs, upload s1-probes-artifacts, and link Android NDK .so,
  kotlinc Activity, and iOS Simulator swiftc executable in CI.
- Web host: use an offscreen canvas GPU probe, add OAuth redirect-loop and
  runtime GPU loss guards, restrict embed URLs and sandbox tokens, match
  /api/auth/captcha Turnstile headers, and launch four independent ES module
  Blob workers pinned to site root.
- iOS host: add affine-ios-host staticlib crate implementing all C-ABI
  functions with surrogate-pair safe UTF-16 editing, weak DisplayLinkProxy,
  absolute ime_bottom contract, and in-memory LegacyCapacitorSchemeHandler.
- Android host: implement hand-written JNI bridge with absolute ime_bottom
  logical-dp conversion, predictive and legacy back gesture handling, and a
  pure Android platform SDK MainActivity and LegacyLocalStorageProbe.
2026-11-27 06:55:47 +09:00
DarkSky 8e0b345036 feat(editor): extract ui-tokens, ui-kit, and blocksuite-editor crates
Add the zero-dependency ui-tokens crate to export generated theme tokens,
icon definitions, and bundled font bytes without cross-tree include_bytes!
paths.

Add the domain-neutral ui-kit crate with logical geometry helpers, SafeArea,
VirtualList, SwipeDialog, and SwipeMenu state machines backed by scheduler
time and four-rate replay invariance tests.

Extract blocksuite-editor from playground with the WorkspaceDocDirectory
host port, exact substring UTF-16 highlight matching, and LTR/RTL logical
start/end block flow layout. Slim playground to the demo and harness host.
Update workspace manifests, static invariant guards, CI workflows, and
AGENTS.md files.
2026-11-27 06:55:47 +09:00
DarkSky d619bfbcda feat(preview): add pure-Rust offline preview kernel crate 2026-11-27 06:55:47 +09:00
DarkSky 0c9e634d08 feat(ui): add L0 mobile logical layout, bidi shaping, gestures, motion, web safe-area and iOS foundation
- Add logical geometry helpers on Edges, Corners, Svg, and scroll offsets, and propagate inherited LayoutDirection through Taffy and fast splice rebuilds with a zero-clone LTR fast path.
- Propagate explicit BaseDirection through LineLayoutCache and all platform shapers (Apple CoreText, CosmicText, and Web), sort visual clusters by x_start, add UAX #9 multi-line soft-wrap bidi reordering, preserve contextual Arabic joining across same-font runs, and align text truncation on shaped glyph-cluster boundaries (`UI_LOC_CEILING = 95200`).
- Add scheduler-clock TouchGestureRecognizer with tap, long-press timer wakeup, pan cancellation, pinch re-anchoring, and closed-form MotionCurve presets including SwipeMenu InOutSine and SwipeDialog cubic-bezier/outQuad.
- Replace Web four-element safe-area probing with a single hidden probe and exact per-edge float comparison, preserving non-double-subtracted IME insets.
- Align the iOS platform stub traits and PlatformInfo, update packages/ui/AGENTS.md, and add aarch64-apple-ios and aarch64-apple-ios-sim compile guards to native-playground CI.
2026-11-27 06:55:47 +09:00
DarkSky eff3ff6d56 feat(store): integrate affine-store into frontend workspace and harden sync
Integrate `packages/common/store` (`affine-store`) into the unified
`packages/frontend` workspace and close cross-client compatibility and
crash-recovery invariants against `0.27.5`:

- Encode page creation identity via `PageIdSource` and `CreateDocId`
  (`DerivedFromOp` vs `Explicit`), derive deterministic 10-character
  URL-safe NanoIDs from `(space_id, op_id)` without sidecar tables or
  extra keys in shared Yjs `meta.pages`, and reject `page_id` collisions
  with the root `space_id`.
- Keep `DocMode::Page` writing only the root document, require
  `db$docProperties` to be resolved before non-`Page` creation
  (returning `StoreError::DbTableNotResolved` so retry intent survives
  restarts), gate explicit non-`Page` crash-replay backfill on a
  client-local `export_explicit_create_journal` /
  `import_explicit_create_journal` record so legacy `0.27.5` pages
  without `DocProperties` rows keep `DocMode::Page`, preserve existing
  live or soft-deleted `DocProperties` rows independently of root page
  repair, and start `SqliteDocStorage::push_updates_batch` with
  `BEGIN IMMEDIATE` to prevent `SQLITE_BUSY_SNAPSHOT` on pooled WAL
  connections.
- Capture unacknowledged `in_flight` and deferred `JoinDocs` updates in
  `SpaceSyncEngine::snapshot()` ahead of `offline_queue` while keeping
  live local writes gated on `waiting_for_id_converter`.
- Wire `vars.NP_ALLOW_PERF_BOOTSTRAP` in `native-playground.yml` and
  document the three `perf/accepted.json` lifecycle actions in
  `packages/frontend/AGENTS.md`.
2026-11-27 06:55:47 +09:00
DarkSky 6f9f1cace5 refactor(workspace): dissolve native-playground into domain directories 2026-11-27 06:55:47 +09:00
DarkSky 1d6fd58258 feat(backend): add doc sharing, histories, comments, notifications, open-app, and license
Add Rust domain services, GraphQL resolvers, REST routes, and realtime RPC
handlers for public docs, grants, histories, comments, notifications, user
settings, Open-App sign-in, and self-hosted licenses.

- Add DocSharingService, public-docs routes, y-octo root-doc filtering, and
  realtime share-state and grants RPCs.

- Add DocHistoryService, snapshot recovery, update compaction, and expired
  record cleanup.

- Add CommentService, NotificationService, user settings, Open-App codes,
  SelfhostLicenseService, and BillingSpi.

- Run 9 deterministic Cloud E2E specs in CI, remove waitForTimeout calls,
  and add collaboration parity checks.
2026-11-24 17:25:29 +09:00
DarkSky ae1bd232db feat(server): add public API parity and cloud E2E cutover for affine-server
Add public-repo API parity to `affine-server` and run the core cloud
Playwright suite against the Rust all-in-one server.

- Add HS256 Bearer access tokens, native session exchange, refresh,
  revoke, and list REST endpoints, login preflight, profile updates,
  WebP avatar transcoding and safe removal, and a distributed-locked
  expired-session cleanup worker with background lease renewal.

- Unify workspace and per-document ACL evaluation (`acl.rs`), split
  REST and GraphQL modules, and add workspace member management,
  ownership transfer with readonly and quota invalidation guards, atomic
  invite links, `createWorkspace(init)` transactional root snapshots,
  `DocType`, `DocPermissions`, `createBlobUpload`, `calendarProviders`,
  and SocketIO realtime workspace access and config rooms.

- Extract reachable blob keys with `y-octo` bounded BFS under
  `REPEATABLE READ` snapshots with pre-merge budgets and bounded caching,
  check per-doc ACL and reserved doc isolation on source-scoped blob
  routes, paginate `readable-blob-manifest/v1` with SQL cursor pushdown,
  and reject legacy blob reads with `403 UNSUPPORTED_CLIENT_VERSION`.

- Keep fresh DB bootstrap on the default v1 sync protocol until
  activated, and accept both absent (v1) and active (v2) lifecycle
  checkpoints on existing databases.

- Add `AFFINE_E2E_RUST_SERVER=1` Playwright support and a
  `cloud-e2e-rust-server` CI job, extend the live parity scenario to
  23 steps, and lower `waitForTimeout` usage from 336 to 312 (ratchet
  from 324 to 316).
2026-11-24 07:59:26 +09:00
DarkSky c245d8e1f7 feat(server): add domain, mail, blob, sync services and writing rules
Add server-domain, server-mail, server-blob, and server-sync under packages/backend with y-octo 0.4.0.
Wire auth, blob, mail worker, and Socket.IO routes into server-http and affine-server.
Extend the parity harness and CSF frame audit checks.
Fix mail error redaction, expired terminal error codes, database clock reads in blob checks, and permission docs.
Add the STE writing skill and update AGENTS.md rules.
2026-11-23 16:04:20 +09:00
DarkSky b375374c7f refactor(server): move server crates under packages/backend and upgrade y-octo to 0.4.0
Move the server Rust workspace directly under packages/backend.
Exclude native and server from that workspace.
Move frame-audit to tools/frame-audit as a standalone crate.
Isolate packages/backend/native under the root workspace.
Upgrade y-octo to 0.4.0 in native-playground and remove the old removal workarounds.
Update CI workflows, static gates, and docs for the new paths.
2026-11-23 15:12:26 +09:00
DarkSky ec1093007c fix(ci): ignore bundled license in formatter, harden shared container startup, and select M1 crates in run.json
- .prettierignore: exclude pre-signed crates/server-types/assets/*.license.json from oxfmt/prettier.
- crates/test-db-harness/src/docker.rs & crates/AGENTS.md: raise SHARED_START_TIMEOUT from 10s to 60s
  to match PG READY_TIMEOUT on cold CI runners, serialize same-process ensure_shared calls with an
  in-process Mutex, and update last_error in SharedAction::Wait instead of surfacing stale Conflict.
- .github/workflows/native-playground.yml: include all six M1 server crates in run.json --select.
2026-11-23 13:58:04 +09:00
DarkSky 82e166f49b test(parity): frozen v0.27.5 self-parity run, web build lane, fewer waitForTimeout
Parity harness:
- `compare` re-runs the comparison on a recorded report offline through
  the same protocol/database/effects path as live runs, and like `run`
  rejects scenarios without steps.
- `require` lists per-side checks (equals, length, contains); an unmet one
  is a difference at /require/<side><pointer>, so two sides failing the
  same way are never green.
- Timestamps also accept RFC 2822 HTTP dates (cookie Expires), with both
  sides in the same format.
- Socket.IO `record_events` limits which pushed events are reported;
  `wait_event` still sees all of them.
- scripts/run-v0275-self-parity.mjs boots two @affine/server instances of
  the checkout given by --server-root (the frozen baseline,
  darksky/before-stable-fix c2929acf2d) on
  leased PG16 clones, two Redis containers, two SMTP capture ports and
  separate HOMEs, in a run directory of its own; runs the data migrations,
  validate-cutover and workspace lifecycle activation; replays
  scenarios/v0275-self-parity.json (/info, GraphQL setup/auth/workspace/
  quota, Socket.IO join/push/load, a real test mail) and requires 0
  differences across protocol, all user tables, SMTP and Redis plus every
  requirement (doc accepted and stored, schema_baseline_0275 checkpoint,
  one mail, invalidation and event bus messages), then a tampered
  right-side DB row and GraphQL field reported at exactly their paths.
  Only a passing run writes --record, atomically, with the server SHA;
  cleanup failures fail the run; a temporary static manifest is removed.
- tests/v0275_self_parity.rs replays a committed recording of the frozen
  baseline, injects one change per dimension and checks that both sides
  losing the same results fail their requirements.

CI:
- np-web-build.yml builds @affine/web, @affine/mobile and @affine/admin on
  ubuntu-24.04 without Electron/Playwright/Sentry downloads, each bundle
  within eight minutes, and checks the bundle entry exists;
  native-playground.yml calls it only when frontend sources change.

Test debt:
- Delete the unused blocksuite std inline test helper and the unused
  selectVisibilitySelector; drop sleeps already covered by auto-waiting
  assertions and click(); poll getIndexCoordinate per animation frame.
  waitForTimeout ceiling 378 -> 370.
2026-11-23 13:58:04 +09:00
DarkSky 4a08e49642 feat(ci): add crates/ test harness workspace, shared frame audit and fast CI lanes
- crates/: standalone server-side Rust workspace (resolver 3, edition
  2024, own lock and toolchain 1.98.1)
  - frame-audit: the one serde-only FrameSnapshot schema and audit
    engine; native-playground's ui depends on it by path and re-exports
    it. The six structural rules keep their ids; evidence rules (first-
    line baseline, footer reverse wrap, divider placement, static cursor,
    overlay z-order via renderer hit-test probes, text truncation) report
    missing evidence instead of skipping, and concentric radii reject
    negative and step-limited radii. Old snapshots still load.
  - test-db-harness / affine-test-env: a marker-checked PostgreSQL test
    cluster (explicit URL or a reused machine-wide pgvector container),
    read-only migration-digest templates with Prisma bookkeeping,
    template clones under owner-token leases, and an orphan reaper. Clone,
    heartbeat, release and reap serialize per database on an advisory
    lock and re-check under it; every maintenance connection re-checks
    the cluster marker. Private Redis or a prefix-isolated URL. Images
    pinned to multi-arch digests; only private harness containers of the
    expected run, by full id, can be removed. run.json reports.
- scripts/ci/check-l0-tier-a.mjs: dependency-free gates for crates/
  layering and hygiene, a waitForTimeout/.skip ratchet with per-file
  ceilings, workflow references, pinned test images and .gitignore.
- native-playground.yml: resolve the change base to a commit SHA, call
  np-web-fast.yml (lint, typecheck, Node-only Vitest projects without
  Electron, browser or Rust-binary dependencies) when web sources
  change, and always run L0, the frozen server contract checks, crates/
  and the parity harness (fmt, clippy, tests against real services).
- Web lint and format: the frozen contract artifacts and
  blocksuite/native-playground (checked by its own lane) are ignored via
  .prettierignore, from which .oxlintrc.json is generated; the server
  contract and parity harness scripts are formatted and lint-clean.
- tools/parity-harness/rustfmt.toml keeps the default style there.
- Remove the copilot cron workflows and the skipped migration spec;
  ignore test-results/ and .artifacts/.
2026-11-23 13:58:04 +09:00
DarkSky ebc5eb6fb2 feat(native-playground): add interactive edgeless authoring and polish 2026-11-23 13:58:04 +09:00
DarkSky 5565057fb6 feat(playground): read and render typed whiteboard surfaces 2026-11-23 13:58:04 +09:00
DarkSky 4e26a040ee feat(native-playground): add y-octo doc engine, binary room sync, and unified workspace
Unifies the 3-crate native-playground workspace (ui, doc, playground) with:
- crates/doc (#![forbid(unsafe_code)], y-octo 0.3.0, 53-bit JS-safe client IDs, full block & surface element schemas with 0-writeback defaults, blocks-scoped undo/redo with SelectionSnapshot, deterministic RoomAwareness with BlockSuite TextSelectionState, Sans-I/O binary room framing, Axum room hub / bs-relay with WS-only seed-claim FIFO waiter promotion & equal-clock awareness refcount hardening & permissive blob CORS, and bs_doc_driver).
- @blocksuite/sync DocPeer finishPull listener ordering (preserving 0-writeback while capturing mid-handshake edits) and pendingIncomingUpdates subdoc buffer.
- @blocksuite/playground RoomWebSocketClient (+2 awareness clock re-announce on reconnect, disconnect removal before detaching listener, socket-only detached offline fallback, in-place Proxy reuse for partial-seed recovery without destroying shared subdocs, winner flush & non-winner affine:page root wait, ?ws= relay origin forwarding to MockServerBlobSource) + live Rust-JS E2E convergence suite.
- Real doc_1k_edits_ms and room_sync_1k_ops_ms benchmarks in bs-harness bench.
- Updated check-invariants.sh (doc GUI isolation + forbid(unsafe_code)), AGENTS.md active invariants, and native-playground CI workflow (wasm32 doc check, macOS doc tests, and parallel js-room-coop job).
2026-11-23 13:58:03 +09:00
DarkSky 74bcafa70f feat(native-playground): add N-3 perf guardrail, theme/style oracle, and CI self-tests 2026-11-23 13:58:03 +09:00
DarkSky dbe1e2f2c7 feat(native-playground): headless GPUI harness, variable Inter weights, web bundle, and CI gates
- Prune undeclared cfg gates in crates/ui and enforce unexpected_cfgs = deny
- Restore lean HeadlessPlatform driving real PlaygroundView via Window::draw()
  and Element::paint() FrameSnapshot capture (removing shadow scene builder)
- Restore PlatformWindow::draw invocation in Window::present for desktop and web
- Support OpenType variable-font 'wght' axis across CosmicTextSystem (Linux and
  WebAssembly) and AppleTextSystem (macOS CoreText) with Bold vs Regular advance
  width and rasterized ink unit test
- Bundle tracked Inter variable font in crates/playground across macOS, Linux,
  and WebAssembly; add minimal Web HTML harness and headless Chromium smoke test
- Unify animation time onto TestScheduler / BackgroundExecutor::now() and verify
  60/120/24/7 fps PlaygroundView pill transitions with identical terminal snapshots
- Add warm 30-frame steady-state bench with schema-aligned ci_wall_ms object,
  optional unmeasured v1 metric fields, and strict 40-hex commit resolution
- Commit Cargo.lock, enforce --locked in CI, harden check-invariants.sh link-flag
  check, align CI wasm-bindgen CLI with Cargo.lock, and keep AGENTS.md exact
2026-11-23 13:58:03 +09:00
DarkSky 12df368ad6 fix(server): add forward compatibility for 0.27.5 cutover 2026-11-23 10:44:42 +08:00
DarkSky 577ae12b51 feat(mobile): bump xcode deps (#15885)
#### PR Dependency Tree


* **PR #15885** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved handling of app links and shared content when the iOS app
opens or returns to the foreground.
* iOS simulator tests now install and launch the app before running, and
verify that it stays open.
* **Chores**
* Updated the iOS build and release process to use Xcode 27 and require
an iOS SDK version of 27 or later.
* Adjusted release builds to preserve the required components for iOS
app packaging.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-11-22 22:30:44 +08:00
DarkSky 0d594345a3 fix(core): sync indicator style (#15863)
#### PR Dependency Tree


* **PR #15863** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Bug Fixes**
* The notification menu item no longer displays an active state solely
because the notification list is open; opening and closing the list
works as before.
* **Style**
* Refined the layout of the workspace sync-status button while
preserving its existing label and appearance details. The status content
now has more consistent spacing and alignment within the workspace card.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-11-17 13:41:13 +08:00
DarkSky 66bca643da fix: sync compatibility 2026-11-17 01:09:14 +08:00
DarkSky c471cfc9a5 feat(core): improve sync protocol (#15854)
#### PR Dependency Tree


* **PR #15854** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **New Features**
* Added workspace document lifecycle tracking, including trashed and
deleted states, with migration support.
* Added workspace inventory syncing and state refresh across cloud and
local storage, improving document discovery and offline synchronization.
* Added clearer messages for invalid or oversized document updates and
temporarily unavailable sync or validation.
* Added paused-upload diagnostics and a Quick Export shortcut for
relevant workspace sync issues.

* **Improvements**
* Search, indexing, and document metadata now reflect workspace
inventory and lifecycle state.
* Restoring from history preserves concurrent edits made during
recovery.
* Unused-blob checks now scan document content and detect changes during
scanning.

* **Bug Fixes**
* Invalid document updates are rejected without partially saving a
batch.
* Document reading handles missing or cyclic block relationships more
reliably.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-11-16 19:37:14 +08:00
DarkSky a37334a150 feat(server): improve order sync (#15802) 2026-11-08 12:24:01 +08:00
DarkSky 4db3ac8d6b fix(server): doc parse cycle (#15794)
#### PR Dependency Tree


* **PR #15794** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved search reliability when documents are changing, including
more consistent handling of invalid or incomplete document data.
* Prevented overlapping scheduled search updates, helping keep
background processing consistent.
* Improved coordination between search projections and payment
processing when both operate on document snapshots.
* Search processing now better isolates failures, helping other
documents continue to be processed and allowing recovery after source
data changes.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-11-06 01:55:27 +08:00
DarkSky 80e1c26815 fix(client): add aarch64 linux release (#15752)
fix #13701

#### PR Dependency Tree


* **PR #15752** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **New Features**
  * Linux ARM64 builds on ARM64 hosts now use the native build path.
* **Bug Fixes**
* Improved updater handling of Linux ARM64 installer filenames so
platform and architecture filtering can be verified for those packages.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-10-27 15:52:32 +08:00
DarkSky 21e07b6635 fix(client): glibc version & linux secret store (#15751)
fix #15732
fix #15750
fix #15548

#### PR Dependency Tree


* **PR #15751** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)
2026-10-27 15:47:55 +08:00
DarkSky b2e56529ee chore: improve ci (#15743) 2026-10-26 16:49:45 +08:00
DarkSky 733d839bcf chore: cleanup codes 2026-10-25 00:10:50 +08:00
DarkSky e32f8dce04 chore: bump deps (#15729)
#### PR Dependency Tree


* **PR #15729** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## Summary by CodeRabbit

* **Deployment**
* Updated the Cloud SQL Proxy image and integrated it with deployment
charts.
* Containers now run with stricter security settings, including non-root
execution and read-only filesystems.
* **Desktop**
* Updated Electron and Node versions and adjusted Windows builds to
support multiple architectures.
* **Maintenance**
  * Updated Vite and Storybook versions across development tools.
  * Improved production GraphQL schema handling.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-10-22 16:38:31 +08:00
DarkSky 7afb62d5b4 feat(server): improve config loading (#15649)
fix #15650
fix #15530
fix #15534
fix #15506


#### PR Dependency Tree


* **PR #15649** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

## Summary

* **New Features**
* Admin settings show configuration sources and secret status, conceal
secret values, and allow database-level overrides to be cleared.
* Self-hosted deployments can automatically upgrade existing
configuration files.
* **Improvements**
* Configuration changes apply without restarting the server, and storage
settings reload automatically.
* Uploads support runtime-managed proxy settings and signed upload
tokens.
  * Incomplete managed Copilot profiles are disabled during migration.
* Saving an AI response as a document more reliably targets the matching
editor.
* **Documentation**
* The CLI clarifies that imported configuration changes take effect
after the next server start.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-09-30 00:39:36 +08:00
DarkSky ca0ffc52f7 feat(nbstore): multi remote primitive (#15637) 2026-09-23 02:26:14 +08:00
keepClamDownandDarkSky 2af30773ae feat(ios): add stable Share Extension imports (#15547)
## Summary

The changes below are prepared locally and have not been committed or
pushed.

- Save original URLs, user titles, selected text, images and PDFs
through a versioned, file-backed Share Inbox. Stable document/attempt
IDs, serialized imports and committed receipts make retries preserve
user edits and recover native completion.
- Keep rich previews transient. Share previews request transcript
excerpts, clip optional display fields and bound response/image
downloads. Saving does not wait for preview requests or persist provider
metadata, transcript snapshots or dedicated preview blobs.
- Restore the minimal App Group workspace-mode snapshot and
`official`/`deferred` route. Official routes remain fixed for the
pending share; deferred self-hosted previews use the selected server
without a provider fallback.
- Let bookmark and YouTube details read the current workspace's Link
Preview API by URL. Full transcripts, chapters and timestamps load on
expansion without document writes. Reuse editor styles and the existing
portal for canvas details; isolate endpoint/base/transcript caches and
keep transcript results out of persistent cache.

## Validation

- Focused frontend suites: 128 tests passed; the 43 preview/details
cases also passed after the final portal change.
- `ShareInboxSafetyTests`: 57 tests passed on iOS 26.5 simulator.
- `yarn typecheck` and full `yarn lint` passed.
- iOS web bundle, Capacitor asset copy, and signed simulator App build
with embedded ShareExtension passed.
- Browser component checks: desktop, narrow viewport, light/dark themes,
full transcript scrolling, canvas portal positioning and Escape
dismissal.
- Simulator Safari share: rich preview, cancellation, native-to-app
handoff, workspace selection and successful save. The pending manifest
contained original content and routing only, and was removed after
import.

Physical-device and network-capture matrices remain manual. The
simulator YouTube iframe displayed player error 153; this is separate
from the successful preview/import checks and video playback is not
claimed as verified.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* iOS sharing now supports PDF files alongside images, with previews and
attachment validation.
* Share imports offer improved workspace selection, offline handling,
retry recovery, and clearer error messages.
* Link previews can display expandable metadata and transcript details
for bookmarks and YouTube embeds.
* Share inbox entries now identify unsupported versions and provide
safer attachment resolution.

* **Bug Fixes**
* Improved cancellation, cleanup, and stale-request handling during
sharing and importing.
* Enhanced link-preview validation and protection against oversized or
invalid responses.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: DarkSky <darksky2048@gmail.com>
2026-09-15 14:55:04 +08:00
DarkSky 51fdf602ba feat(core): adapt new lifecycle (#15575)
fix #15574


#### PR Dependency Tree


* **PR #15575** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

## New Features
* Added source-aware blob handling for current documents and page
history.
* Added document lifecycle support for trashing, restoring, and
permanently deleting documents.
* Copilot attachments now upload directly to session attachment
endpoints.

## Bug Fixes
* Document actions now complete before confirmations, notifications, and
navigation proceed.
* Improved cancellation, upload fallback, size-limit handling, and cloud
synchronization reliability.
* Invite-link expiration now remains reliable for long durations.
* Improved synchronization for document permissions and reserved
documents.

## Changes
* Blob management now displays attachment icons instead of image
previews.
* Cloud synchronization now uses a unified batch protocol.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-09-09 23:00:06 +08:00
DarkSky 8c5937111b feat(server): migrate legacy impl (#15571)
#### PR Dependency Tree


* **PR #15571** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Added Copilot session attachments, scoped access controls,
personal-workspace support, and automatic title generation.
- Added self-hosted license compatibility, license portal access, and
external license-key configuration.
- Added reservation-based storage uploads and workspace storage
reconciliation.
- Added permissions for previews, history, analytics, moderation, and
workspace storage.

- **Changes**
- Removed the admin queue dashboard and queue-based background
processing.
- Updated blob, comment-attachment, payment, and calendar
synchronization workflows.
- Improved redirect validation, preview indexing, and synchronization
error reporting.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-09-08 23:21:00 +08:00
DarkSky d6be85eaae feat: converage native module (#15570)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Added expanded authentication options, including password, magic-link,
OAuth, session management, and CAPTCHA verification.
* Added team licensing, subscription billing, payment-provider
integrations, and entitlement management.
* Added authorized blob browsing, streaming, storage reservations, seat
management, and quota visibility.
* Added document lifecycle actions, comments, publishing, history
recovery, and enhanced permission controls.
* Added safer redirect handling and improved search projection recovery.
* **Bug Fixes**
* Improved authorization, storage consistency, payment recovery, and
cross-instance cache invalidation.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-09-07 17:34:16 +08:00
DarkSky ea0e477033 chore(docs): update pr templates
Added additional checklist items for PR submissions regarding AI-generated edits and code quality agreement.
2026-09-02 20:59:52 +08:00
DarkSky bd095495da fix(server): index & gc queue & llm compatibility (#15528)
fix #15523
fix #15526

#### PR Dependency Tree


* **PR #15528** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **Bug Fixes**
- Improved search generation cleanup, provider error reporting, and
reconciliation reliability.
- Retired search resources are cleaned up safely, including after
credential changes.
- Prompt size checks now ignore tool parameters and provide clearer
errors.
- Reserved documents are protected from accidental cleanup, and
malformed identifiers are rejected.

- **Configuration**
- Managed Copilot profiles require explicit, non-duplicated model
assignments.
  - Improved managed provider profile migration.

- **Performance & Reliability**
- Reduced unnecessary search-history cleanup and adjusted
consistency-check intervals.
- Failed reconciliation jobs stop after one attempt and are removed
automatically.

- **Data Updates**
  - Updated legacy AI session prompt names to current labels.
  - Improved cloud load-balancer health-check configuration.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-08-26 15:57:06 +08:00
DarkSky b530198a3b feat(server): improve indexer perf (#15512)
#### PR Dependency Tree


* **PR #15512** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Search now supports generation-based indexing with embedded and remote
providers.
* Added automatic search reconciliation and improved handling of
document, workspace, and permission changes.
* Added clearer search status errors for unavailable, syncing, unready,
or failed indexes.
* Added Manticore Search end-to-end support and provider-specific search
behavior.

* **Improvements**
* Search and aggregate pagination now report returned results and
continuation status more accurately.
* Improved permission filtering to prevent inaccessible documents from
appearing in results.
  * Admin provider selection now consistently enables indexing.

* **Documentation**
* Clarified search pagination, aggregation counts, provider
configuration, and end-to-end setup.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-08-23 17:54:49 +08:00
donqu1xotevincent 3feb17cde3 docs: refresh contributing & building guides, surface CLA signing flow (#15503) 2026-08-21 08:15:26 +08:00
DarkSky c57004ea2c refactor(server): indexer & worker & sync perf (#15504) 2026-08-21 08:11:37 +08:00
DarkSky 0c7b20dc18 chore: migrate oxlint & oxfmt (#15464)
#### PR Dependency Tree


* **PR #15464** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Chores**
* Replaced the project’s formatting and linting workflow with Oxfmt and
Oxlint.
* Added shared formatting and linting configuration, editor integration,
and updated automated checks.
* Updated generated files, scripts, and lint guidance to use the new
tooling.

* **Style**
* Reformatted templates, source code, examples, and configuration files
for consistent readability.
  * No user-facing functionality or rendering behavior changed.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-08-10 23:51:28 +08:00
renovate[bot] fdfb6df826 chore: bump up actions/setup-python action to v7 (#15416)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[actions/setup-python](https://redirect.github.com/actions/setup-python)
| action | major | `v6` → `v7` |

---

### Release Notes

<details>
<summary>actions/setup-python (actions/setup-python)</summary>

###
[`v7.0.0`](https://redirect.github.com/actions/setup-python/compare/v6.3.0...v7.0.0)

[Compare
Source](https://redirect.github.com/actions/setup-python/compare/v7.0.0...v7.0.0)

###
[`v7`](https://redirect.github.com/actions/setup-python/compare/v6.3.0...v7.0.0)

[Compare
Source](https://redirect.github.com/actions/setup-python/compare/v6.3.0...v7.0.0)

</details>

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - At any time (no schedule defined)
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/toeverything/AFFiNE).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4zLjIiLCJ1cGRhdGVkSW5WZXIiOiI0NC4zLjIiLCJ0YXJnZXRCcmFuY2giOiJjYW5hcnkiLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIl19-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-08-02 22:59:24 +08:00