Skip to content

Commit 7b73e73

Browse files
committed
Docs/Fix: mise à jour des spécifications de locking (Git) et correction de la dépréciation datetime
1 parent 8dce0cf commit 7b73e73

3 files changed

Lines changed: 5 additions & 3 deletions

File tree

Core/Locking/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,8 @@ def get_git_commit_hash(workspace: Path) -> str | None:
134134

135135

136136
def next_build_id(lock_dir: Path) -> str:
137-
today = datetime.utcnow().strftime("%Y_%m_%d")
137+
from datetime import UTC
138+
today = datetime.now(UTC).strftime("%Y_%m_%d")
138139
prefix = f"ARK_{today}_"
139140
seq = 1
140141
if lock_dir.exists():

docs/dev_docs/ARK_Locking_v1.0.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ project:
4343
name: MyApp # Copied from project.name
4444
version: 1.0.0 # Copied from project.version
4545
entry: src/main.py # Copied from project.entry
46+
git_commit: sha256:abc123... # Snapshot of current git commit
4647

4748
workspace:
4849
exclude_patterns: # Copied from build.exclude (legacy support)

docs/how_to_create_an_engine.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ class MyEngine(CompilerEngine):
5151
2. `@engine_register` adds the class to the registry.
5252
3. The GUI calls `create_tab` if present to create a tab.
5353
4. When compile is triggered, the engine provides the command via `build_command`.
54-
5. The process runs the command and calls `on_success` on success.
54+
5. The process runs the command and calls `on_success` on success. **Note**: ARK automatically opens the output directory (from `BuildContext.output_dir`) before calling this hook.
5555

5656
### **Workspace Entrypoint**
5757

@@ -78,7 +78,7 @@ Core methods.
7878
- `program_and_args(self, context: BuildContext) -> (program, args) | None`: override if needed.
7979
- `preflight(self, gui, file) -> bool`: checks before compile, return False to abort.
8080
- `environment(self) -> dict[str, str] | None`: env vars to inject.
81-
- `on_success(self, gui, file) -> None`: post‑build hook.
81+
- `on_success(self, gui, file) -> None`: post‑build hook. Use this for specific cleanup or custom notifications. (The output directory is already opened by ARK).
8282

8383
UI and i18n.
8484

0 commit comments

Comments
 (0)