Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
f693019
e2e: dismiss system ANR dialogs during Android flows
tiensonqin Sep 25, 2026
7e99897
e2e: harden iOS setup against system-browser hierarchy stalls
tiensonqin Sep 25, 2026
09e64da
e2e: widen Cognito hosted-UI wait to 240s on iOS
tiensonqin Sep 25, 2026
1508467
e2e: force-close ANR'd apps instead of tapping Wait + more AVD RAM
tiensonqin Sep 25, 2026
2b904d2
Revert "e2e: raise AVD RAM for launcher ANR headroom"
tiensonqin Sep 25, 2026
481482b
e2e: extend Android driver startup budget + retry each flow once
tiensonqin Sep 25, 2026
b5f452d
apple: route patch-apply diagnostics through os.Logger
tiensonqin Sep 25, 2026
fd809c7
apple: elevate patch diagnostics to notice/error + trace effect failures
tiensonqin Sep 25, 2026
a04894a
ffi: route OCaml exception logging through os_log on Apple
tiensonqin Sep 25, 2026
53e53d3
e2e: raise Android driver startup budget to 300s
tiensonqin Sep 25, 2026
8fa6afe
ios: surface core-action boundaries and effect lifecycle in sim log
tiensonqin Sep 25, 2026
bcd8fc0
ffi: bracket every lui_*/rpc entry with enter/acquired/done logs
tiensonqin Sep 25, 2026
282b228
ocaml-signal: repin to stabilize round-cap branch + sign-in resolve r…
tiensonqin Sep 25, 2026
a022aec
e2e: pin lui_flutter_backend to semantics-freeze fix for validation
tiensonqin Sep 25, 2026
7dfbb6f
merge main: take lui pin 88f9b4a (theme-scope fix)
tiensonqin Sep 25, 2026
b4b3092
e2e: pin lui_flutter_backend to semantics-heal fix (498bd22) for vali…
tiensonqin Sep 25, 2026
668c48a
e2e: pin lui_flutter_backend to extended semantics-heal fix (d055aa4)
tiensonqin Sep 25, 2026
dbdab79
e2e: pin lui_flutter_backend to throttled semantics-heal (ed44ebc)
tiensonqin Sep 25, 2026
bd49268
e2e: build Android profile APK + pin lui 62e2e69 (toolbar a11y identi…
tiensonqin Sep 25, 2026
f177c51
e2e: bump lui_flutter_backend pin for context-menu identifier fix (e3…
tiensonqin Sep 25, 2026
632d725
e2e: recover dead adb/emulator between flow retries
tiensonqin Sep 25, 2026
5326828
e2e: fix android-local-graph-setup post-create assert
tiensonqin Sep 25, 2026
2d6b5c8
e2e: pin flutter backend to semantics-heal v2 + contextmenu id fix
tiensonqin Sep 25, 2026
41fbd44
e2e: robust adb recovery, safer ANR dismissals, semantics-heal v3 pin
tiensonqin Sep 25, 2026
82fb8b4
e2e: free stale Maestro UiAutomation binding; soften watchdog poll
tiensonqin Sep 25, 2026
0bb4fc4
flutter: repin lui to 11668eb (anchored-stack semantics boundary fix)
tiensonqin Sep 25, 2026
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
2 changes: 1 addition & 1 deletion apple/Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion apple/Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ let package = Package(
.library(name: "LogseqChatModel", type: .dynamic, targets: ["LogseqChatModel"]),
],
dependencies: [
.package(url: "ssh://git@github.com/logseq/lui.git", revision: "88f9b4a4c8fd9f0227656a986655479c495c0232"),
.package(url: "ssh://git@github.com/logseq/lui.git", revision: "62e2e69d0c01281947afbb0f39ffa4c550b7ca3b"),
.package(url: "https://github.com/gonzalezreal/swiftui-math", from: "0.1.0"),
.package(url: "https://github.com/appstefan/highlightswift.git", from: "1.1.0")
],
Expand Down
30 changes: 14 additions & 16 deletions apple/Sources/LogseqChat/LGChatRuntime.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import Foundation
import LUIAppleBackend
import Observation
import LogseqChatModel
import os

private struct LGChatPatchMetadata: Decodable {
let generation: Int
Expand Down Expand Up @@ -113,6 +114,8 @@ public final class LGChatRuntime {
@ObservationIgnored
private let outlinerAutosaveDelayNanoseconds: UInt64

private static let log = Logger(subsystem: "com.logseq.chat", category: "runtime")

@ObservationIgnored
private var patchTail: Task<Void, Never>?

Expand Down Expand Up @@ -191,6 +194,7 @@ public final class LGChatRuntime {
}
let envelope = decodeCoreResponse(response)
guard shouldApplyCoreResponse(response, envelope: envelope) else {
Self.log.notice("skipped core response (deduped) pendingSync=\(envelope?.result?.isPendingSyncPatch ?? false, privacy: .public) outliner=\(envelope?.result?.isOutlinerPatch ?? false, privacy: .public)")
deliverPlatformCommands(envelope)
return
}
Expand Down Expand Up @@ -390,15 +394,12 @@ public final class LGChatRuntime {
}

cancelOutlinerAutosaveBeforeExecuting(effect)
Self.log.notice("effect start id=\(effect.id, privacy: .public) kind=\(effect.kind, privacy: .public)")
let resolution = await effectExecutor.execute(effect)
#if DEBUG
Self.log.notice("effect resolved id=\(effect.id, privacy: .public) kind=\(effect.kind, privacy: .public) succeeded=\(resolution.succeeded, privacy: .public)")
if !resolution.succeeded {
print(
"LOGSEQ_LG_EFFECT failed id=\(effect.id)"
+ " kind=\(effect.kind) message=\(resolution.message)"
)
Self.log.error("effect failed id=\(effect.id, privacy: .public) kind=\(effect.kind, privacy: .public) message=\(resolution.message, privacy: .public)")
}
#endif
if resolution.succeeded,
case .coreResponse = resolution.output {
enqueueApply(native.applySnapshot(resolution.message))
Expand All @@ -420,6 +421,7 @@ public final class LGChatRuntime {
let syncResolution = await startSyncIfNeeded(
envelope: envelope
)
Self.log.notice("startSync resolved id=\(effect.id, privacy: .public) succeeded=\(syncResolution.succeeded, privacy: .public)")
if !syncResolution.succeeded {
lastError = syncResolution.message
return
Expand Down Expand Up @@ -563,21 +565,17 @@ public final class LGChatRuntime {
guard let self else { return }
do {
let decoded = try await decodeTask.value
guard epoch == self.patchApplyEpoch else { return }
#if DEBUG
print(
"LOGSEQ_LG_PATCH apply generation="
+ String(Self.patchGeneration(patch) ?? -1)
)
#endif
guard epoch == self.patchApplyEpoch else {
Self.log.warning("dropped stale patch generation=\(Self.patchGeneration(patch) ?? -1, privacy: .public) epoch=\(epoch, privacy: .public) current=\(self.patchApplyEpoch, privacy: .public)")
return
}
Self.log.notice("apply patch generation=\(Self.patchGeneration(patch) ?? -1, privacy: .public)")
try self.renderer.apply(decoded: decoded)
self.lastError = nil
} catch {
guard epoch == self.patchApplyEpoch else { return }
self.lastError = String(describing: error)
#if DEBUG
print("LogseqChat renderer apply failed: \(self.lastError ?? "unknown")")
#endif
Self.log.error("renderer apply failed: \(self.lastError ?? "unknown", privacy: .public)")
}
}
}
Expand Down
4 changes: 3 additions & 1 deletion apple/Sources/LogseqChatModel/ViewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ private struct LogseqModelLogger {
#if os(Android)
print(message)
#else
logger.info("\(message, privacy: .public)")
// notice so the line survives the sim's unified-log filtering (info
// is dropped from device-simulator.log captures).
logger.notice("\(message, privacy: .public)")
#endif
}

Expand Down
4 changes: 2 additions & 2 deletions flutter/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -159,8 +159,8 @@ packages:
dependency: "direct main"
description:
path: "platform/flutter"
ref: 2a2cc62dd4583734b7b7f6c226c587e950c5985e
resolved-ref: 2a2cc62dd4583734b7b7f6c226c587e950c5985e
ref: 11668eb7e5e26af8974901c5d158c1c0cafa40b3
resolved-ref: 11668eb7e5e26af8974901c5d158c1c0cafa40b3
url: "ssh://git@github.com/logseq/lui.git"
source: git
version: "0.1.0"
Expand Down
2 changes: 1 addition & 1 deletion flutter/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ dependencies:
lui_flutter_backend:
git:
url: ssh://git@github.com/logseq/lui.git
ref: 88f9b4a4c8fd9f0227656a986655479c495c0232
ref: 11668eb7e5e26af8974901c5d158c1c0cafa40b3
path: platform/flutter
webview_flutter: ^4.14.1

Expand Down
4 changes: 2 additions & 2 deletions logseq_chat.opam
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ pin-depends: [
["melange-transit-core.0.1.2" "git+https://github.com/logseq/melange-transit.git#main"]
["melange-transit-native.0.1.2" "git+https://github.com/logseq/melange-transit.git#main"]
["melange-transit-melange.0.1.2" "git+https://github.com/logseq/melange-transit.git#main"]
["lui.0.1.0" "git+ssh://git@github.com/logseq/lui.git#88f9b4a4c8fd9f0227656a986655479c495c0232"]
["lui.0.1.0" "git+ssh://git@github.com/logseq/lui.git#62e2e69d0c01281947afbb0f39ffa4c550b7ca3b"]
["drive.dev" "git+https://github.com/logseq/drive.git#7f407b07f18e68596cb0dcb3ba1781cb0572a2bb"]
["ocaml-signal.0.1.0" "git+https://github.com/logseq/ocaml-signal.git#976b40f1770a65b3464df1ef38d1550f1d8a43dd"]
["ocaml-signal.0.1.0" "git+https://github.com/logseq/ocaml-signal.git#b9cb81fc910519fc579a90960267acb851483bca"]
["mldoc.dev" "git+https://github.com/logseq/mldoc.git#553dea6ed8694352527a189747f787365469c9cb"]
["angstrom.dev" "git+https://github.com/logseq/angstrom.git#3be9b966dc2bc9ccf9948d17a7b0df1cb526de15"]
["xmlm.dev" "git+https://github.com/logseq/xmlm.git#eb469d536e98c98f2754c0ff8813c92b3a17fe9f"]
Expand Down
4 changes: 2 additions & 2 deletions logseq_chat.opam.locked
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ pin-depends: [
]
[
"ocaml-signal.0.1.0"
"git+https://github.com/logseq/ocaml-signal.git#976b40f1770a65b3464df1ef38d1550f1d8a43dd"
"git+https://github.com/logseq/ocaml-signal.git#b9cb81fc910519fc579a90960267acb851483bca"
]
[
"ocaml-syntax-shims.1.0.0"
Expand Down Expand Up @@ -1490,7 +1490,7 @@ x-opam-monorepo-duniverse-dirs: [
"ocaml-fsrs"
]
[
"git+https://github.com/logseq/ocaml-signal.git#976b40f1770a65b3464df1ef38d1550f1d8a43dd"
"git+https://github.com/logseq/ocaml-signal.git#b9cb81fc910519fc579a90960267acb851483bca"
"ocaml-signal"
]
[
Expand Down
30 changes: 28 additions & 2 deletions scripts/test-android-e2e-runner.sh
Original file line number Diff line number Diff line change
Expand Up @@ -189,8 +189,8 @@ PATH="$mock_bin:$PATH" \
LOGSEQ_CHAT_ANDROID_E2E_SKIP_INSTALL=1 \
LOGSEQ_CHAT_ANDROID_E2E_SKIP_VISUAL_GATES=1 \
"$runner" signed-out >/dev/null
[[ $(<"$flutter_args") == "$repo_root/flutter|build apk --debug" ]] \
|| die "Android E2E runner did not build the Flutter debug APK"
[[ $(<"$flutter_args") == "$repo_root/flutter|build apk --profile" ]] \
|| die "Android E2E runner did not build the Flutter profile APK"

: >"$adb_args"
PATH="$mock_bin:$PATH" \
Expand Down Expand Up @@ -400,6 +400,32 @@ expected_node_tag_args=$(printf '%s\n' \
[[ $(<"$maestro_args") == "$expected_node_tag_args" ]] \
|| die "Android E2E runner did not preserve the node and tag parity flow"

: >"$adb_args"
cat >"$mock_bin/adb" <<'EOF'
#!/usr/bin/env bash
if [[ -n ${LOGSEQ_CHAT_ADB_ARGS:-} ]]; then
printf '%s\n' "$*" >>"$LOGSEQ_CHAT_ADB_ARGS"
fi
case "$*" in
*"exec-out uiautomator dump"*)
printf '%s\n' \
'<hierarchy><node text="Pixel Launcher isn'"'"'t responding" bounds="[28,979][1052,1485]"/><node text="Close app" bounds="[136,879][314,945]"/><node text="Wait" bounds="[400,879][578,945]"/></hierarchy>'
;;
esac
EOF
printf '#!/usr/bin/env bash\nsleep 1\nprintf "%%s\\n" "$@" >"$LOGSEQ_CHAT_MAESTRO_ARGS"\n' >"$mock_bin/maestro"
chmod +x "$mock_bin/adb" "$mock_bin/maestro"
PATH="$mock_bin:$PATH" \
ANDROID_SERIAL=test-device \
LOGSEQ_CHAT_ADB_ARGS="$adb_args" \
LOGSEQ_CHAT_MAESTRO_ARGS="$maestro_args" \
LOGSEQ_CHAT_ANDROID_E2E_SKIP_BUILD=1 \
LOGSEQ_CHAT_ANDROID_E2E_SKIP_INSTALL=1 \
LOGSEQ_CHAT_ANDROID_E2E_SKIP_SEED=1 \
"$runner" settings >/dev/null
grep -Fq -- '-s test-device shell input tap 225 912' "$adb_args" \
|| die "Android E2E runner's ANR watchdog did not tap the dialog's Close app button"

PATH="$mock_bin:$PATH" \
ANDROID_SERIAL=test-device \
LOGSEQ_CHAT_MAESTRO_ARGS="$maestro_args" \
Expand Down
Loading
Loading