Repository navigation
Compile the opened source file instead of a project main file - #18
Conversation
DebelToni
left a comment
There was a problem hiding this comment.
Reviewed all 16 changed files at 03489ed against current main 66f6c6a. Needs attention before merge.
-
[P2] Keep the advertised legacy compile default valid (
apps/server/src/project-store.ts, deleteFile fallback). The new query chooses the first text file, while Compiler.request now rejects every non-.tex root. For example, with main.tex, references.bib and standalone.tex, deleting main.tex selects references.bib; POST /compile without a body now returns 400 although a valid standalone.tex remains. This contradicts the newly documented omit-body compatibility. Choose an eligible .tex fallback and add coverage for mixed .bib/.md/.tex files. Also cover deleting the last source and subsequently creating a new .tex: the default is currently left empty, with no remaining setter to repair it. -
[P2] Reject the retired entryFile PATCH instead of acknowledging a no-op (
apps/server/src/routes/project-routes.ts, PATCH input schema). z.object({name: optional}) strips the former entryFile key, so an existing owner client sending {entryFile: "other.tex"} receives 200/project.updated while nothing changes. Keep explicit compatibility or return a clear 400 for the retired field; add a regression test. The UI can remain per-open-file in either case.
The explicit compile path is normalized, checked against this project, included in the cache key and persisted on the job used by the worker/output lookup. Existing project write checks and snapshot admission remain in place; no dependency/workflow/security-policy or host-automation changes were found. Hosted checks passed, but these cases are not covered by the new happy-path tests. No contributor code, tests, installers or builds were executed on DGX.
|
Addressed both review findings in 7e2d834: the legacy default now selects only text .tex files and repairs itself on add/rename/delete (including the last-source/recreate case); retired project entryFile PATCH returns explicit HTTP 400 entry_file_retired instead of a silent 200. Added API regression coverage for .bib/.md/.tex fallback, recreation, rename, and PATCH rejection. Local lint, typecheck, 157 server tests, 127 web tests, and builds passed; hosted checks are rerunning on the new head. |
DebelToni
left a comment
There was a problem hiding this comment.
Re-reviewed all 16 changed files at 7e2d834 against current main 66f6c6a. Thirteen files are byte-identical to the previously reviewed revision; the three additional changes were inspected in full. Both previous findings are addressed.
Legacy defaults now remain on an existing text .tex source across create/rename/delete, become empty when none exists and recover when a new .tex is added. Tests cover mixed bibliography/Markdown/TeX files, last-source deletion, recreation and renaming away from .tex. Retired entryFile PATCH requests fail clearly before name/default mutation, with a regression test.
Reviewed per-open-file UI selection/flush, explicit path normalization/project membership/write gates, entry-aware cache/coalescing keys, frozen job entry passed through fake/real worker output and PDF handling, deletion behavior, API documentation and preservation of content/agent authorization. No dependency, workflow, review/security-policy or host-automation changes. Exact-head hosted test/analyze and CodeQL passed. No contributor code, tests, installers or builds executed on DGX. No remaining blocking findings.
Changes
Verification
Draft to allow CI without triggering automatic owner review/production deployment until ready.