Skip to content

Commit 7804e6e

Browse files
committed
docs(ci): documenter la regle fail-fast et le pilotage BCASL
1 parent e9e4adb commit 7804e6e

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

docs/ci_cd_ark_cli.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,15 @@ python3 /path/to/PyCompiler_ARK/pycompiler_ark.py
2424

2525
## Minimal Pipeline (copy/paste)
2626

27+
If you use the project wrapper script, prefer CLI flags over environment variables:
28+
29+
```bash
30+
./ci_cd_ark.sh --workspace /path/to/workspace --engine pyinstaller --no-bcasl
31+
./ci_cd_ark.sh --workspace /path/to/workspace --engine pyinstaller --with-bcasl --bcasl-timeout 120
32+
```
33+
34+
Direct ARK CLI flow:
35+
2736
```bash
2837
ARK_BIN="python3 /path/to/PyCompiler_ARK/pycompiler_ark.py"
2938
WORKSPACE_DIR="/path/to/workspace"
@@ -48,6 +57,9 @@ PY
4857
)"
4958
ENTRYPOINT_FILE="$WORKSPACE_DIR/$ENTRYPOINT_REL"
5059

60+
# Optional BCASL stage (enable explicitly when required)
61+
# $ARK_BIN bcasl run "$WORKSPACE_DIR" --timeout 120 > "$WORKSPACE_DIR/.ark_bcasl_run.log"
62+
5163
$ARK_BIN engine info "$ENGINE_ID" --workspace "$WORKSPACE_DIR" --json > "$WORKSPACE_DIR/.ark_engine_info.json"
5264
if ! $ARK_BIN engine compile "$ENGINE_ID" "$ENTRYPOINT_FILE" --workspace "$WORKSPACE_DIR" --json > "$WORKSPACE_DIR/.ark_build_result.json"; then
5365
WORKSPACE_DIR="$WORKSPACE_DIR" python3 - <<'PY'
@@ -83,6 +95,10 @@ $ARK_BIN workspace entrypoint-clear "$WORKSPACE_DIR" --json
8395
- CI/CD gate
8496
- exits non-zero when precheck fails
8597

98+
- `bcasl run` (optional)
99+
- include BCASL plugin execution in pipeline when needed
100+
- recommended through wrapper flags: `--with-bcasl` / `--no-bcasl`
101+
86102
- `engine compile`
87103
- compiles the resolved entrypoint with the selected engine
88104
- returns non-zero on build failure, even in `--json` mode (pipeline-friendly)
@@ -91,6 +107,14 @@ $ARK_BIN workspace entrypoint-clear "$WORKSPACE_DIR" --json
91107
- `venv status/use-system/use-venv/install-req`
92108
- lets CI enforce workspace Python mode and requirements installation policy
93109

110+
## Fail-fast Rule
111+
112+
CI/CD flow should be fail-fast:
113+
114+
- if one stage fails, stop the pipeline immediately
115+
- do not continue to later stages (for example, do not compile after a BCASL failure)
116+
- mark non-executed stages as skipped in the final summary
117+
94118
## System Tool Auto-install Policy (CI Security)
95119

96120
When `ARK_AUTO_INSTALL_SYSTEM_TOOLS=1` is set, ARK can attempt to install missing
@@ -243,6 +267,8 @@ from pathlib import Path
243267
ws = Path(os.environ["WORKSPACE_DIR"])
244268
reports = [
245269
("workspace-apply", ws / ".ark_workspace_apply.json", lambda d: bool(d.get("ok"))),
270+
# Optional BCASL report generated by your wrapper script when enabled
271+
("bcasl-run", ws / ".ark_bcasl_run.json", lambda d: bool(d.get("ok"))),
246272
("check", ws / ".ark_check.json", lambda d: bool(d.get("ok"))),
247273
("engine-info", ws / ".ark_engine_info.json", lambda d: bool(d.get("found", True))),
248274
("compile", ws / ".ark_build_result.json", lambda d: bool(d.get("success"))),

0 commit comments

Comments
 (0)