chore: small cleanups from the 2026-09 code review (checklist)
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 25/100
Hướng nghiên cứu
The checklist names entry points across the project, including App.axaml.cs, MainActivity.OnPause, SystemAlarmService.cs, IncidentFile.SanitizeFileName, and DispatcherTimerTicker; read the relevant unchecked item and its referenced code first. Several items involve concurrency, lifecycle, security, or cancellation across subsystems, so select a narrowly scoped item and check whether it has already been split into another issue. Done means the chosen item is implemented and its behavior is covered by appropriate tests.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
From the 2026-09-09 code review of main (35d86e1). Small, independent items; each is a short PR. Tick them off here.
- Four copy-paste JSON stores (
JsonRecentFilesStore,JsonLastSaveFolderStore,JsonLastPdfExportStorein AppLogic,JsonTrustStorein Sync) repeat the same read/deserialise/catch (JsonException)/write scaffolding. Extract one genericJsonFileStore<T>with the atomic temp+rename write that #286 added to the trust store. — #329 -
JsonTrustStore.Persist()mutates_cachebefore the disk write; ifFile.Movethrows, memory and disk diverge until the next write. Write first, then commit the in-memory change (noted in the #286 review). — #331 -
AboutViewModel.cs:68-77andLinksViewModel.cs:103-112are byte-identicalOpenUrlAsynctry/catch blocks; share one helper (also listed in #167 as "URL validation + opening duplicated"). — #332 -
RemoteIncidentSession.cs:496-501: a three-line comment block is duplicated verbatim. — #331 -
TasksSection.cs:54(PDF) usesDateTimeOffset.Nowto render "overdue", so the same incident exports differently depending on wall-clock time and the section is untestable. Pass theIClock(or an explicit "as of" timestamp) into the report. — #334 -
ForceUnit.StatusandRoleAssignment.Roleare free strings validated against nothing;Incident.StatusChangeText(:666) switches on the string, so a typo in master data silently falls through. Validate againstMasterDataSetat the session boundary, or model status as a small value type. — #355 -
App.CreateMainViewModel(App.axaml.cs:25) is a mutable public static delegate, a service-locator seam in an otherwise constructor-injected design. Pass the factory intoAppexplicitly. -
MainView.axaml.cs:19-32re-attachesPropertyChanged/Cancelled/… handlers to every newPendingPromptwithout detaching from the previous one. Same shape inIncidentWorkspaceView.axaml.cs:38,45. — #371 -
MainActivity.OnPausefires_ = _store?.FlushAsync()without awaiting; the last save can be lost when Android kills the process. Block briefly (with a timeout) as the desktopExithandler does. -
SystemAlarmServiceis never disposed on Android, so its temp WAV files leak. -
SystemAlarmService._voiceTempFilesis an unsynchronizedDictionarywritten byTempFileForonSerialAudioQueue's worker thread (SystemAlarmService.cs:107-125, reached fromPlayBlocking:80) and enumerated byDisposeon the UI thread at exit (:152) — a cue in flight during shutdown enumerates while the other thread mutates. Same class as theDispatcherTimerTickeritem below, but unlike that one this is genuinely cross-thread. While there: the temp path is a fixedlagebuch-{sound}.wavin the world-writable system temp dir (:116), with none of the per-open GUID directory and symlink refusalAttachmentTempPathsgives attachments — another local user can pre-create or symlink that path. (Found re-auditing #167.) - No
CancellationTokenSourceexists anywhere insrc/; tokens are only forwarded. A slow join, a large upload or a long PDF export cannot be cancelled by the user. Wire a cancel button on the join and export flows to a real CTS. -
IncidentFile.SanitizeFileName(#285) strips control characters but not Unicode format characters (e.g. U+202E RLO), so a display-name spoof is still possible in the Dateien list. StripUnicodeCategory.Formattoo. -
DispatcherTimerTickerallocates_subscribers.ToArray()on every tick and a throwing subscriber aborts the rest of the tick on the UI thread; isolate subscribers (also listed in #167). -
RemoteIncidentSession's per-device attachment cache underattachment-cache/is never evicted (also listed in #167). — split out as #382, tracked there. -
HttpClientHandlercreated inRemoteIncidentSessionis now disposed (#286); checkSystemAlarmService._voiceTempFilesandPdfLicense._configuredstatic state for testability while there.
- Ngôn ngữ chính
- C#
- Star
- 1
- Fork
- 3
- Merge trung bình
- 4 giờ 49 phút
- Pull request đã merge (30 ngày)
- 177
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của CodeForFire/lagebuch
-
Stammdaten: in the Checkliste editor the PFLICHT header is not aligned with its columnCó thể đã có người làm @Saad-elnagar đã nhận hôm nay. Đang mởbug ux
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
CodeForFire/lagebuch#714 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Stammdaten: on a phone the Fahrzeuge editor squeezes Wache and Funkrufname to nothingCó thể đã có người làm @Saad-elnagar đã nhận 1 ngày trước. Đang mởbug ux
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
CodeForFire/lagebuch#713 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
CodeForFire/lagebuch#405 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
documentation good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
CodeForFire/lagebuch#349 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
documentation good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
CodeForFire/lagebuch#348 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của CodeForFire/lagebuch
Issue tương tự
-
area: client bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
bug mcp misleading small
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Bug Platform: Android
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
getsentry/sentry-dotnet#5764 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
microsoft/SimpleL7Proxy#287 ·
Maintainer thường phản hồi trong vòng 1 ngày