diff --git a/.env.example b/.env.example index 0987f6a..4d21fbf 100644 --- a/.env.example +++ b/.env.example @@ -11,10 +11,11 @@ HF_TOKEN= # ---- host paths ------------------------------------------------------------- -# Where your recordings live, laid out as /.mp4. Mounted read-only -# into the container; nothing is ever written back into it. -# must be absolute for the copy-path buttons (REQ-172) -VIDEO_ARCHIVE_HOST=/home/araaraenjoyer/dbs_project/reTraining/data/archive +# Where your recordings live, laid out as /.mp4. Mounted read-write +# into the container; written only by user-initiated upload / date-folder +# creation (REQ-178), nothing else. +# must be absolute for the copy-path buttons (REQ-179) +VIDEO_ARCHIVE_HOST=/absolute/path/to/reTraining/data/archive WSL_DISTRO_NAME=Ubuntu # ---- ports ------------------------------------------------------------------ diff --git a/backend/config.py b/backend/config.py index fb19211..79bab79 100644 --- a/backend/config.py +++ b/backend/config.py @@ -24,7 +24,7 @@ VIDEO_ROOT = os.path.abspath(os.environ.get("VIDEO_ARCHIVE", os.path.join(DATA_D def archive_host_paths() -> dict: - """Where the archive sits on the host — for the copy-path buttons (REQ-172). + """Where the archive sits on the host — for the copy-path buttons (REQ-179). ponytail: relative VIDEO_ARCHIVE_HOST (./data/archive) cannot be resolved inside the container; set it absolute in .env or the buttons stay hidden.""" diff --git a/backend/library.py b/backend/library.py index 30989ed..2dff068 100644 --- a/backend/library.py +++ b/backend/library.py @@ -1,7 +1,8 @@ """The video archive, read as `//.` (REQ-010…012). -Read-only by construction: this module only ever lists and stats files, never -writes into the user's recordings (REQ-074). +Reads the archive and appends user-initiated uploads and date folders +(REQ-178); nothing that exists is ever moved, renamed or deleted +(REQ-163/074 as revised). """ import os diff --git a/frontend/src/components/ArchiveControls.jsx b/frontend/src/components/ArchiveControls.jsx index a9ecce6..6fbab4f 100644 --- a/frontend/src/components/ArchiveControls.jsx +++ b/frontend/src/components/ArchiveControls.jsx @@ -134,8 +134,8 @@ export default function ArchiveControls({ project, projectId, onChanged }) { /> -
- {folderError &&

{folderError}

} +
+ {folderError &&

{folderError}

} {progress && (

@@ -154,7 +154,7 @@ export default function ArchiveControls({ project, projectId, onChanged }) {

)} {uploadErrors.map((err, i) => ( -

+

{err.name}: {err.message}

))} diff --git a/scripts/generate_panduan_md.py b/scripts/generate_panduan_md.py index 42dac61..fdce830 100644 --- a/scripts/generate_panduan_md.py +++ b/scripts/generate_panduan_md.py @@ -826,7 +826,7 @@ Pemisahan tegas diterapkan antara direktori kode sumber dan volume penyimpanan s reTraining/ ├── data/ # Volume utama persistensi data aplikasi │ ├── app.db # Database SQLite (mode WAL, 14 tabel relasional) -│ ├── archive/ # Arsip video CCTV read-only (/.mp4) +│ ├── archive/ # Arsip video CCTV (/.mp4); ditulis hanya oleh upload/pembuatan folder dari halaman Video Archive │ ├── live-count/ # Berkas jejak trajektori sesi hitung (.jsonl) │ └── projects// # Ruang kerja terisolasi per proyek │ ├── base/model.pt # Bobot checkpoint model dasar aktif