Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 0 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,6 @@ jobs:
run: opam list --installed --columns=name,installed-version --short --color=never > .ci-reports/packages.txt
- name: Build all targets and native embed
run: |
# OCaml's partial linker does not use the C compiler's multiarch paths.
# Expose archives only so the complete object cannot select a shared library.
if [ "$(uname -s)" = Linux ]; then
static_directory="$PWD/.ci-deps/system-static-libs"
mkdir -p "$static_directory"
for library in rt sqlite3; do
archive="$(cc -print-file-name="lib${library}.a")"
test -f "$archive"
ln -s "$archive" "$static_directory/lib${library}.a"
done
export OCAMLPARAM="_,cclib=-L$static_directory"
fi
opam exec -- dune build @all app/native_embed.exe.o
- name: Run full regression suite
run: opam exec -- dune runtest --force
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@
/.dir-locals.el
app/journal_complete_iossim.o

# Generated Python bytecode
__pycache__/
*.pyc

# Local validation reports and evidence
/docs/test-reports/
/.ci-deps/
Expand Down
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
- Use spec-dev-tool to manage agent decision documents; run `spec-dev-tool --help` and follow its AGENT WORKFLOW.
- All changes must comply with `docs/ux-guidelines.md`.
- Keep temporary review and test evidence, experiments, reports, screenshots, and generated hosts outside this repository in the current task's external evidence directory. Do not create a repository `review/` directory or temporary test directories. Reusable formal test source belongs in the existing test directories.
- Before adding a bug regression test, identify the production state owner and attempt reproduction through its public pure reducer events, completions, state, and effects. If that boundary reproduces the defect, add only pure reducer regression tests for it; do not duplicate coverage in effect-runner, persistence, transport, integration, E2E, or UI tests. If it cannot, document the missing ownership boundary and test only the narrowest layer that executes the defect. Injecting an already incorrect external result is not a pure reproduction. Use deterministic public interfaces without bypassing `.mli` files or copying implementation logic. This rule does not authorize removing existing tests or moving production ownership for test classification.
- When asked to find simplifications, run `spec-dev-tool guide find-simplifications` from inside this Git worktree and follow the emitted workflow.
- When asked to find test simplifications, run `spec-dev-tool guide find-test-simplifications` from inside this Git worktree and follow the emitted workflow.
Expand Down
1 change: 0 additions & 1 deletion app/application.mli
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ val sync_phase_name
: Logseq_db_worker_lui.Logseq_db_worker_lui_service.sync_phase
-> string

val startup_phase_name : Journal_startup.startup_phase -> string
val graph_phase_name : Logseq_db_worker.graph_phase -> string

val diagnostic_phase_rows
Expand Down
7 changes: 0 additions & 7 deletions app/journal_asset_import.ml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@ let source_to_string = function
| Camera -> "camera"
;;

let source_of_string = function
| "files" -> Some Files
| "photos" -> Some Photos
| "camera" -> Some Camera
| _ -> None
;;

(* [request] mirrors the extension's request prop; [staged] requests copy the
pick into a temp file on the host so the path outlives the picker's
security scope — needed when the selection is attached later (composer). *)
Expand Down
2 changes: 0 additions & 2 deletions app/journal_asset_import.mli
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ type source =
| Photos
| Camera

val source_to_string : source -> string
val source_of_string : string -> source option

(** Picker arm request: [source] selects the picker, [staged] makes the host
copy the pick into a temp file so it survives until a later import. *)
Expand Down
4 changes: 0 additions & 4 deletions app/journal_asset_runtime.ml
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,3 @@ let notice
| Asset_availability { consumer; asset; availability } ->
dispatch t (Availability { consumer; asset; availability }))
;;

let visible t ~consumer assets = dispatch t (Visible { consumer; assets })
let hidden t ~consumer = dispatch t (Hidden consumer)
let progress t reason = Policy.progress t.policy reason
3 changes: 0 additions & 3 deletions app/journal_asset_runtime.mli
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,5 @@ val notice
-> Logseq_db_worker_lui.Logseq_db_worker_lui_service.asset_notice
-> unit

val visible : t -> consumer:string -> Logseq_db_types.Asset_descriptor.t list -> unit
val hidden : t -> consumer:string -> unit
val progress : t -> Journal_asset_policy.reason -> Journal_asset_policy.progress
val pump : t -> unit
val reject : t -> request_id:Logseq_db_types.Graph_types.Uuid.t -> unit
15 changes: 0 additions & 15 deletions app/journal_lui_native.ml
Original file line number Diff line number Diff line change
Expand Up @@ -118,21 +118,6 @@ let mount ?key ~payload ~children ?on_event identifier context parent =
node
;;

let chrome ?key ~payload ?on_event children : Lui_elements.t =
fun context parent ->
mount ?key ~payload ~children ?on_event chrome_identifier context parent
;;

let asset_import ?key ~payload ?on_event children : Lui_elements.t =
fun context parent ->
mount ?key ~payload ~children ?on_event asset_import_identifier context parent
;;

let asset_settings ?key ~payload ?on_event children : Lui_elements.t =
fun context parent ->
mount ?key ~payload ~children ?on_event asset_settings_identifier context parent
;;

let list ?key ~payload ?on_event children : Lui_elements.t =
fun context parent ->
mount ?key ~payload ~children ?on_event list_identifier context parent
Expand Down
26 changes: 0 additions & 26 deletions app/journal_lui_native.mli
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ val chrome_identifier : string
val asset_import_identifier : string
val asset_settings_identifier : string
val list_identifier : string
val image_preview_identifier : string

(** Extension schemas shared with the Apple iOS/macOS hosts. *)
val registry : Lui_extension.extension_registry
Expand All @@ -28,10 +27,6 @@ type event =
; payload : string
}

(** Decodes a lui [ExtensionEvent] into a journal [event]; returns [None] for
events that are not journal extension events or are malformed. *)
val decode_event : Lui_protocol.event -> event option

(** Low-level mount helper shared by the element constructors and the
[Journal_view.Native_widget] shim. [payload] is the JSON-encoded
properties object (the same JSON the previous [~encode_props] produced);
Expand All @@ -44,27 +39,6 @@ val mount
-> string
-> Lui_elements.t

val chrome
: ?key:string
-> payload:string
-> ?on_event:(event -> unit)
-> Lui_elements.t list
-> Lui_elements.t

val asset_import
: ?key:string
-> payload:string
-> ?on_event:(event -> unit)
-> Lui_elements.t list
-> Lui_elements.t

val asset_settings
: ?key:string
-> payload:string
-> ?on_event:(event -> unit)
-> Lui_elements.t list
-> Lui_elements.t

(** Native virtualized collection (grouped sections, scroll positioning,
visible-range paging, context actions). Section and row structure rides in
[payload]; each row's content element mounts as an extension child in the
Expand Down
6 changes: 0 additions & 6 deletions app/journal_model.ml
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,6 @@ let status_name = function
| Later -> "Later"
;;

let status_default_value = function
| No_status -> None
| In_review -> Some "In Review"
| status -> Some (status_name status)
;;

type t =
{ id : string
; page_id : string
Expand Down
1 change: 0 additions & 1 deletion app/journal_model.mli
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ type status_category =

val status_category : task_state -> status_category option
val status_name : task_state -> string
val status_default_value : task_state -> string option

type t

Expand Down
4 changes: 0 additions & 4 deletions app/journal_time.ml
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,6 @@ let of_instant_unix_ms_with ~localtime ~instant_unix_ms =
| exn -> Error ("local time conversion failed: " ^ Printexc.to_string exn)
;;

let of_instant_unix_ms ~instant_unix_ms =
of_instant_unix_ms_with ~localtime:Unix.localtime ~instant_unix_ms
;;

let of_calendar calendar =
create
~instant_unix_ms:(Journal_calendar.instant_unix_ms calendar)
Expand Down
2 changes: 0 additions & 2 deletions app/journal_time.mli
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ val create
-> local_minute_of_day:int
-> (t, string) result

val of_instant_unix_ms : instant_unix_ms:int64 -> (t, string) result

val of_instant_unix_ms_with
: localtime:(float -> Unix.tm)
-> instant_unix_ms:int64
Expand Down
19 changes: 0 additions & 19 deletions app/journal_validation.ml
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,6 @@ let is_valid_utf_8 value =
loop 0
;;

let utf_8_scalar_count value =
let rec loop offset count =
if offset = String.length value
then Some count
else (
let decoded = String.get_utf_8_uchar value offset in
if Uchar.utf_decode_is_valid decoded
then loop (offset + Uchar.utf_decode_length decoded) (count + 1)
else None)
in
loop 0 0
;;

let contains_nul value = String.contains value '\000'

let validate_block_source value =
Expand All @@ -48,12 +35,6 @@ let validate_block_source value =
else Ok ()
;;

let validate_source value =
if String.equal (String.trim value) ""
then Error "source must not be blank"
else validate_block_source value
;;

let is_leap_year year = year mod 4 = 0 && (year mod 100 <> 0 || year mod 400 = 0)

let is_journal_day day =
Expand Down
2 changes: 0 additions & 2 deletions app/journal_validation.mli
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@

val is_uuid : string -> bool
val is_valid_utf_8 : string -> bool
val utf_8_scalar_count : string -> int option
val is_journal_day : int -> bool
val contains_nul : string -> bool
val validate_block_source : string -> (unit, string) result
val validate_source : string -> (unit, string) result
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Journal 已完成 LUI、局部媒体订阅与 typed native NavigationStack 迁

原始证据:[完整 UI review](/Users/rcmerci/Documents/Codex/2026-10-03/task-8/journal-ui-review.md)、[wrapper](/Users/rcmerci/Documents/Codex/2026-10-03/task-8/view-review.md)、[list](/Users/rcmerci/Documents/Codex/2026-10-03/task-8/list-review.md)、[media](/Users/rcmerci/Documents/Codex/2026-10-03/task-8/media-review.md)、[native](/Users/rcmerci/Documents/Codex/2026-10-03/task-8/native-review.md)、[媒体闪烁诊断](/Users/rcmerci/Documents/Codex/2026-10-03/task-8/media-flicker-diagnosis.md)。这些是本机 Git 外报告,不是已提交附件;其它机器需取得原证据。本文件重核源码树、消费者和规范,复用原诊断并标明限制,探索阶段没有重新运行原实验或声称新 UI PASS;后续新版本验收独立记录。

原 review/native 的 LUI 基线为 `67ea3e8a9787cd80b1106a11a2504a6735f96d30`;当时看到的 main `1db993d4e2eaa2ec844620e374c736829798a2d0` 不是其 native 输入。探索阶段没有 fetch/升级 LUI;实施阶段已隔离解析 main(见实施记录)。实施按 [composer integration](../../../development/composer-integration.md) 解析一致的 OCaml/LUI/Apple package,记录完整 SHA/ABI,不混用新 backend 和旧实验。
原仓库外 native 审查的 LUI 基线为 `67ea3e8a9787cd80b1106a11a2504a6735f96d30`;当时看到的 main `1db993d4e2eaa2ec844620e374c736829798a2d0` 不是其 native 输入。探索阶段没有 fetch/升级 LUI;实施阶段已隔离解析 main(见实施记录)。实施按 [composer integration](../../../development/composer-integration.md) 解析一致的 OCaml/LUI/Apple package,记录完整 SHA/ABI,不混用新 backend 和旧实验。

生产入口 [native_embed](https://github.com/logseq/logseq_journal/blob/953f71b5852b5ffd094bf75a040e46656ab8a1c9/app/native_embed.ml#L1) → `Application.native_hooks` → Application/LUI/C → Apple;固定审查基线的 Flutter 也使用同一 Journal 协议,Q1=B 已决定其后续退役。检索包括 app/test/review、registration/schema/fingerprint、wire 字符串与 kind 映射。测试/static fixture 是实际消费者,不能按“非生产”便删除。[app library](https://github.com/logseq/logseq_journal/blob/953f71b5852b5ffd094bf75a040e46656ab8a1c9/app/dune#L1) 无 `public_name`,Journal_view 不是公开安装 widget 包,但 `.mli`、host wire、测试仍是成套合同。未找到受支持的外部 Journal_view/journal-media mount;这是仓库证据边界,不证明所有外部源码不存在。实施发现真实受支持消费者须补证据、暂停相应删除,不私加 fallback。

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ All required scope decisions are answered by the user's explicit fix authorizati

## Evidence

Five deterministic public-mailbox regressions failed for notification loss or silent overflow before implementation. All eight service tests now pass. The complete build passes; full runtest retains the one pre-existing V.progress source-text mismatch. A real graph file now shows ML and actual 47.2 KB, its camera image renders, and tapping that image shows full Quick Look content. The ML type uses Quick Look's system fallback; it is not claimed to render source text. Both previews were dismissed back to the timeline. Screenshots: review/real-assets-fixed.png and review/real-image-preview-fixed.png. GitHub main was fetched before both test and implementation edits and remains a33d782; the isolated branch includes it.
Five deterministic public-mailbox regressions failed for notification loss or silent overflow before implementation. All eight service tests now pass. The complete build passes; full runtest retains the one pre-existing V.progress source-text mismatch. A real graph file now shows ML and actual 47.2 KB, its camera image renders, and tapping that image shows full Quick Look content. The ML type uses Quick Look's system fallback; it is not claimed to render source text. Both previews were dismissed back to the timeline. The historical screenshots were task-local validation evidence, retained outside the repository. GitHub main was fetched before both test and implementation edits and remains a33d782; the isolated branch includes it.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ The existing native host remains required. Named tag metadata becomes an optiona

## Implementation evidence

Implemented in OCaml/LUI and validated by nine mounted-UI checks, fourteen Worker application integration cases, protocol round trips, and successful workspace build. Actual iOS simulator screenshots and native PDF preview, expansion and collapse were reviewed. See review/README.md for local artifacts, base/PR dependencies, and reproducible host linking. Full runtest has the unchanged baseline V.progress source assertion failure. Horizontal gallery drag remains an explicit manual verification item because the mouse-control tool reports noWindowsAvailable. File names are unavailable from the descriptor; type and optional actual size are used honestly. Draft PR publication is authorized; no physical-device installation or merge occurs.
Implemented in OCaml/LUI and validated by nine mounted-UI checks, fourteen Worker application integration cases, protocol round trips, and successful workspace build. Actual iOS simulator screenshots and native PDF preview, expansion and collapse were reviewed. The repository review artifacts were retired by the 2026-10-08 cleanup; historical validation evidence is retained outside the repository. See the development composer integration guide for the maintained host workflow. Full runtest has the unchanged baseline V.progress source assertion failure. Horizontal gallery drag remains an explicit manual verification item because the mouse-control tool reports noWindowsAvailable. File names are unavailable from the descriptor; type and optional actual size are used honestly. Draft PR publication is authorized; no physical-device installation or merge occurs.


## Follow-up validation
Expand Down
4 changes: 0 additions & 4 deletions dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,6 @@
(melange-transit-native (= 0.1.2))
(ppx_deriving_yojson (>= 3.9.1))
(sqlite3 (= 5.4.0))
(uucp (= 17.0.0))
(uunf (= 17.0.0))
(uutf (= 1.0.4))
(yojson (= 3.0.0))))

Expand Down Expand Up @@ -112,8 +110,6 @@
(logseq_db_types (= 0.1.0))
(logseq_overlay_db (= 0.1.0))
(logseq_sync (= 0.1.0))
(base (= v0.17.3))
(core (= v0.17.2))
(eio (= 1.2))
(eio_main (and :with-test (= 1.2)))
(melange-transit-native (= 0.1.2))
Expand Down
2 changes: 0 additions & 2 deletions logseq_db_worker.opam
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ depends: [
"logseq_db_types" {= "0.1.0"}
"logseq_overlay_db" {= "0.1.0"}
"logseq_sync" {= "0.1.0"}
"base" {= "v0.17.3"}
"core" {= "v0.17.2"}
"eio" {= "1.2"}
"eio_main" {with-test & = "1.2"}
"mtime" {= "2.1.0"}
Expand Down

This file was deleted.

Loading
Loading