Commit Graph
100 Commits
Author SHA1 Message Date
“Naeel” d23cdb6307 test: 15 интеграционных тестов polygon + bump v1.2.25 2026-07-31 23:02:34 +04:00
“Naeel” cc57e4f14a feat: интеграция с polygon — STANDS-check в get_client/get_stand (v1.2.24) 2026-07-31 22:45:27 +04:00
“Naeel” 1a0940a2a0 Добавлены тесты для критических фиксов (lock_check, UniqueViolation, escName, idx_one_running) 2026-07-31 18:28:49 +04:00
“Naeel” 973a303d5e v1.2.23: lock_check three-state return (True/False/None), None→503 DB unavailable 2026-07-31 18:22:58 +04:00
“Naeel” b77f84403b v1.2.22: 3rd audit fixes — UniqueViolation→409, lock_check no-db→False, escName add & escape 2026-07-31 18:20:33 +04:00
“Naeel” 5b0bfeba3f v1.2.21: fix broken advisory lock (→ partial unique index), escName add " escape, lock_check fallback False 2026-07-31 18:17:09 +04:00
“Naeel” deec15f44a v1.2.20: remaining Codex fixes — _op_results lock, advisory lock for scenarios, _ensure_schema logging, stale async generation token, validate-cfs explicit JSONDecodeError 2026-07-31 18:07:24 +04:00
“Naeel” 713601aba0 v1.2.19: fixes from Codex audit — XSS in params, JS injection in onclick, scenario polling timeout, has_target validation, tracker atomic update 2026-07-31 17:58:57 +04:00
“Naeel” ba4f68ab9f v1.2.18: fix onOpChange — сохранять выбранную операцию в step.operation, авто-показ облачных инстансов для не-create 2026-07-31 17:40:33 +04:00
“Naeel” 62ed6b62d8 v1.2.17 2026-07-31 17:26:32 +04:00
“Naeel” cd0fd9c2d8 Подробные комментарии ко всем JS-файлам фронтенда 2026-07-31 17:25:44 +04:00
“Naeel” 2ba881e27a Рефакторинг API-слоя, операций и БД 2026-07-31 17:13:54 +04:00
“Naeel” ea64d897a8 v1.2.16: save full instance metadata (instance_meta JSONB)
init_db.py: ALTER TABLE runs ADD instance_meta JSONB
save_run.py: +instance_meta parameter → JSONB insert
api_test.py: _finish_op fetches GET /instances/{uid} after poll, saves all fields
scenario.py: run_scenario same — per-step instance metadata
Excludes: instanceUid, displayName, svc, serviceId, explainedStatus (already in other columns)
2026-07-31 14:19:29 +04:00
“Naeel” 266765bf9d v1.2.15: aligned table columns everywhere
- Overview cards: .overview-table with table-layout:fixed, status column 70px
- History table: table-layout:fixed, Time 130px, Op 90px, Status 50px, Duration 55px
- All tables now have consistent column widths across cards
2026-07-31 14:14:04 +04:00
“Naeel” fe1aaa0cb5 v1.2.14: expandable history rows with execution stages
Backend: /api/history now returns stages (JSONB)
Frontend: click on history row → expand to show execution stages:
  ✅ stage_name  start → finish (duration)
  ❌ stage_name  start → finish (duration)
  ⏳ stage_name  start → ... (—)
RUNNING rows: yellow background, FAIL rows: red background
2026-07-31 14:07:35 +04:00
“Naeel” 5d18c47711 v1.2.13: Organization card — same style as infra items + UUID
- Collapsible header like other infra cards
- Table row with displayName + instanceUid + status badge
- ClientID shown in header
2026-07-31 14:04:02 +04:00
“Naeel” fdfe305928 v1.2.12: scenario list — clean header row + action buttons in expanded view
- Header: name | step count | seed badge (no CRUD buttons)
- Expanded view: ▶ Запустить ✏ Редактировать 📋 Копировать 🗑 Удалить
  (same size, aligned, with labels)
- Delete hidden for seed scenarios
2026-07-31 14:02:50 +04:00
“Naeel” 5028de2b74 v1.2.11: scenario list — expandable steps + run confirmation
- Click on scenario name → expands to show step details:
  operation → service_id (output/ref/uid) (params)
- ▶ Запустить button inside expanded view
- confirm('Запустить сценарий?') before running
- CRUD buttons (✏📋🗑) with event.stopPropagation()
- toggleScenarioSteps(defId): single-expand (closes others)
2026-07-31 13:55:11 +04:00
“Naeel” 0d5c3cbbbf v1.2.10: rename Верстак→Консоль, fix logs view
- Sidebar: Верстак → 🖥 Консоль
- View header: Верстак → Консоль
- Log view: show real log content (synced with log panel)
- Dark bottom log panel: hidden on all non-log views, left offset 192px (sidebar width)
- views.js: switchView handles log view sync
2026-07-31 13:33:05 +04:00
“Naeel” b81b8fa34e v1.2.9: Phase 1 — sidebar + views layout
index.html: full rewrite
- Sidebar (192px/72px, blue top border): Верстак/Обзор/История/Сценарии/Логи
- Views: workbench (service left rail + instances/params right), overview, history, scenarios, logs
- Token form moved to sidebar bottom
- All existing DOM ids preserved: inst-list, params-area, params-form, btn-test,
  test-status, create-btn-area, history-card, history-body, scenario-card, scenario-body
- Log panel adjusted: left 72px (sidebar width)
- Fonts increased: 12-14px

views.js (NEW): switchView(id) — show/hide views, auto-load content on open
2026-07-31 13:16:50 +04:00
“Naeel” f94a747c39 v1.2.8: Phase 0 review fixes — snackbar.js include + sidebar 72px + collapsed view
- index.html: add snackbar.js (was missing, showSnackbar not available)
- style.css: sidebar.collapsed 56→72px (match Nubes DS 4.5rem)
- style.css: .sidebar.collapsed ~ .view margin-left: 72px
2026-07-31 13:14:49 +04:00
“Naeel” 042a0de34e v1.2.7: Phase 0 — CSS foundation + icons + snackbar
style.css: +93 lines — sidebar, view, tabs, toolbar, field (label on top),
  skeleton, snackbar, combobox classes. Font scale 13/14/16.
icons.js (NEW): 10 inline-SVG Lucide icons (play, edit, trash, check, x,
  chevronDown, search, plus, rotateCw, cloud). stroke=currentColor.
snackbar.js (NEW): showSnackbar(msg, type). bottom-right, 4s/8s auto-hide,
  stacking max 4, accessibility role=status aria-live=polite.
index.html: include icons.js before utils.js
2026-07-31 12:52:02 +04:00
“Naeel” 07ae53b30d v1.2.6: instance dropdown: outputs only + cloud button + RUNNING highlight
scenario-form.js:
- renderStepRow: non-create dropdown shows only 🆕 outputs by default
- «📥 Из облака» button toggles cloud autotest-* instances in same select
- toggleCloudInstances(idx): snapshot, flip _showCloud flag, re-render
- Button label: 📥 Из облака ↔ ➖ Скрыть облако

scenario-list.js:
- RUNNING status: yellow background #fef3c7 on both loadScenarios() and runScenario() polling
2026-07-31 12:29:43 +04:00
“Naeel” 03b991510d v1.2.5: parameter editor with auto-load from API + params-render.js
Phase 1: paramDefsCache, step.params as {name:value}
Phase 2: resolveStepSvcOpId() → loadStepParams() via /api/params
Phase 3: <details> in step card, renderParamRow with pre-fill (clone def + saved values)
Phase 4: snapshotStepParams() before re-render, reset on operation change
Phase 5: collectFormSteps via collectParams() + numeric→name reverse mapping

Only scenario-form.js changed. params-render.js, api_test.py, _resolve_params unchanged.
Compatible with existing scenarios (symbolic names in DB).
2026-07-31 12:00:50 +04:00
“Naeel” ce53d911c2 v1.2.4: collapsible help section in scenario editor modal
scenario-form.js: <details> block between name and steps:
- How steps work (operation → target)
- Create: service + output name
- Non-create: instance from scenario or cloud
- Parameters: key=value format with example
- Buttons: ↑↓ reorder, ✕ delete
2026-07-31 11:49:04 +04:00
“Naeel” 1885621b12 v1.2.3: instance_ref shows cloud instances + bigger CRUD buttons
scenario-form.js:
- showScenarioEditor loads /api/instances/list alongside services
- renderStepRow: non-create instance_ref dropdown shows:
  🆕 outputs from previous create steps
  ☁ existing cloud instances filtered by service_id
- Removed separate instance_uid text field (now in dropdown)

scenario-list.js:
- CRUD buttons: ✏📋🗑 bigger (13px, padding), vertical layout
- Run button: full-width, left-aligned
2026-07-31 11:40:29 +04:00
“Naeel” 095271ef98 v1.2.2: modal scenario editor with dropdowns + output/ref
scenario-form.js — full rewrite:
- Full-screen modal (backdrop + content, 800px max-width)
- Services dropdown (GET /api/services, cached)
- Operations dropdown (GET /api/operations/{svcId}, cached)
- output field for create steps
- instance_ref dropdown (previous outputs) + explicit instance_uid
- [↑][↓] reorder buttons
- Auto-load operations on service change

index.html — modal CSS (#scenario-modal, .modal-backdrop, .modal-content)
2026-07-31 10:19:26 +04:00
“Naeel” 85d2153154 v1.2.1: fix tracker_add in executor + labelCls + descr context + script order
Opus review fixes:
- executor.py: tracker_add inside executor after instance_uid, before params/run (A3, orphan protection)
- executor.py: descr parameter (version/context instead of hardcoded)
- api_test.py: pass client_id/stand/descr, remove duplicate tracker_add
- scenario.py: pass client_id/stand/descr with scenario context
- params-render.js: fix labelCls ReferenceError in renderMapFixedRow (pre-existing bug)
- index.html: params-render.js already before operations.js (verified)
2026-07-31 09:45:05 +04:00
“Naeel” e368dc19b6 v1.2.0: unified executor + flexible instance refs + params-render.js
Phase 1 — New modules:
- api/utils.py: find_uid(), uid_from_location() (replaces 2 duplicates)
- operations/poll.py: poll_until_done() (shared sync/async polling)
- operations/executor.py: execute_operation() (single CREATE/non-CREATE flow)

Phase 2 — Format + validation:
- routes/api_scenario_defs.py: _validate_steps with output/instance_ref/instance_uid
- operations/scenario.py: resolve instance_uid > instance_ref > service_id,
  use executor + poll_until_done, persist instance_bindings

Phase 3 — Migration:
- routes/api_test.py: create/non-create through executor, _finish_op through poll_until_done
- db/init_db.py: startup cleanup of stuck scenario_runs (>1h)

Phase 4 — UI shared module:
- static/js/params-render.js: renderParamRow, renderMapFixedRow, collectParams
- static/js/operations.js: use params-render.js (remove duplicates)
- templates/index.html: include params-render.js
- app.py: bump 1.1.57 → 1.2.0
2026-07-31 08:55:06 +04:00
“Naeel” 74c51c8d35 v1.1.57: fix scenario editor body bug + relativeTime columns + infra UUIDs
- scenario-form.js: fix ReferenceError body is not defined in renderEditor()
- utils.js: relativeTime(iso) → 3ч 12м / 2д 5ч / только что
- instances.js: columns created / modified with relativeTime()
- index.html: instanceUid under displayName in infra column
2026-07-30 22:22:19 +04:00
“Naeel” b6229dec02 v1.1.56: fix JS load order — selectService() moved to app.js (was calling stopPoll before operations.js loaded) 2026-07-30 22:09:26 +04:00
“Naeel” ec689d0739 v1.1.55: split large files + CRUD scenario editor
Backend (5→7 files):
- api_test.py: 622→479, terraform functions → operations/terraform.py (142)
- api_scenario.py: 241→split into run (153) + defs (108) with _validate_steps()
- db/scenario_defs.py: +client_id, stand, is_seed in list_definitions

Frontend (1→10 files):
- app.js: 554→16 (loader), split into:
  utils.js (45), instances.js (89), operations.js (249),
  history.js (35), scenario-list.js (90)
- New CRUD: scenario-form.js (128), create (25), edit (12), delete (13)

Max file size: JS 249, PY 479
2026-07-30 22:02:22 +04:00
“Naeel” b7571f800e v1.1.54: remove delete from dummy_test scenario (cannot delete without suspend) 2026-07-30 16:12:42 +04:00
“Naeel” dbc3236821 v1.1.53: filter scenario history by app_version (fix stale results after redeploy) 2026-07-30 16:10:53 +04:00
“Naeel” 155c42ad95 v1.1.52: fix scenario create (drop svcOperationId) + http_client _status debug 2026-07-30 15:51:22 +04:00
“Naeel” 427d67386e v1.1.51: fix seed — list/get also match global defaults (client_id='' stand='') 2026-07-30 15:25:16 +04:00
“Naeel” cea746a294 v1.1.50: scenario_definitions DB+CRUD, seed, runner from DB, 409 lock, UI definitions, drop config.yaml scenarios 2026-07-30 15:06:05 +04:00
“Naeel” 773f886d32 v1.1.49: UUID extraction directly in http_client.post() — Location header → instanceUid/instanceOperationUid 2026-07-30 14:37:35 +04:00
“Naeel” febc7e5c59 v1.1.48: fix 4 scenario bugs — save_run: scenario_run_id+step_number, run_id before thread (202), TIMEOUT op_data init, RUNNING before API call, GET /run/<id> 2026-07-30 14:08:29 +04:00
“Naeel” 9857231297 v1.1.47: fix scenario UUID extraction — _find_uid + _uid_from_location fallback 2026-07-30 13:57:34 +04:00
“Naeel” 3311d2765e v1.1.46: phase2 — scenario runner MVP (YAML config, DB schema, API endpoints, UI section) 2026-07-30 13:48:34 +04:00
“Naeel” 3cd3cfadda v1.1.45: phase1 — escape fixes, refSvc top-level, redact secrets, validate inputs, no traceback, TIMEOUT save, remove legacy api_bp 2026-07-30 13:43:48 +04:00
“Naeel” ea858e95fa cleanup: move all docs to root DOCS 2026-07-30 13:38:33 +04:00
“Naeel” 4792c508ca docs: ARCHITECTURE-FULL.md + README link 2026-07-30 13:36:35 +04:00
“Naeel” aed95491e7 remove questions-to-sol.md — moved to root DOCS 2026-07-30 13:24:46 +04:00
“Naeel” 56894d0f28 docs: 14 questions to Sol — discuss before implementing 2026-07-30 13:20:19 +04:00
“Naeel” fbeaf40318 docs: GPT-5.6 Sol — 10-step MVP plan 2026-07-30 13:16:48 +04:00
“Naeel” 315c0a23ff docs: GPT-5.6 Sol prompt — architecture ideas + bug hunt 2026-07-30 13:02:26 +04:00
“Naeel” 11d1be0200 v1.1.44: 5 fixes — null-guard + try/catch in toggleInstance/selectService/refreshInstances/CMDB 2026-07-30 09:49:08 +04:00
“Naeel” 27fef9ea0a docs: Sonnet final audit — all bugs + user actions review 2026-07-30 09:36:56 +04:00
“Naeel” 5fc0d96cd0 v1.1.43: fix missing opsEl declaration in toggleInstance 2026-07-30 09:33:27 +04:00
“Naeel” c95c331843 v1.1.42: busy check BEFORE stopPoll in toggleInstance 2026-07-30 09:29:40 +04:00
“Naeel” dae3f28921 v1.1.41: block selectService when busy 2026-07-30 09:10:10 +04:00
“Naeel” e1586159b9 v1.1.40: busy blocks instance expand completely 2026-07-30 09:08:22 +04:00
“Naeel” 8fca948b36 v1.1.39: populate empty valueList from state.out + normalize value_list 2026-07-30 08:47:13 +04:00
“Naeel” 5b565f41dd docs: Sonnet response — state.out valueList + normalize fix 2026-07-30 08:43:32 +04:00
“Naeel” b1aa8d25fe docs: Sonnet question — populate valueList from state.out 2026-07-30 08:37:55 +04:00
“Naeel” c87485b7be v1.1.38: operations per instance svcId + operation name header 2026-07-30 08:33:03 +04:00
“Naeel” 3604f485b1 v1.1.37: params for all ops + polling try/catch + refresh always + tracker CMDB + firstServiceId 2026-07-30 07:47:43 +04:00
“Naeel” 4d91e0e0d4 docs: Sonnet response — 6 bugs found, params for all operations 2026-07-30 07:41:01 +04:00
“Naeel” 803dcedb19 docs: Sonnet question — parameterized operations + full audit 2026-07-30 07:32:13 +04:00
“Naeel” 5fe0e8c70a v1.1.36: CMDB raw_delete uses clean requests (no auth headers) 2026-07-30 07:14:25 +04:00
“Naeel” d920e62764 v1.1.35: close stale ops panels when busy resets 2026-07-29 15:07:25 +04:00
“Naeel” 723496d6a8 v1.1.34: busy=false in catch + CMDB OK no polling 2026-07-29 14:54:59 +04:00
“Naeel” cf8abd0e80 v1.1.33: CMDB delete logging — log HTTP status code 2026-07-29 14:09:56 +04:00
“Naeel” 30751d80df v1.1.32: not-created instances — only show delete operation 2026-07-29 13:57:51 +04:00
“Naeel” f32406066f v1.1.31: CMDB hard delete + fix _resolve_ref_svc params update 2026-07-29 13:48:49 +04:00
“Naeel” b98afa7ee3 v1.1.30: fix json.loads('') in _resolve_ref_svc 2026-07-29 13:43:30 +04:00
“Naeel” ff419be747 v1.1.29: busy=false on early FAIL return — prevent permanent lock 2026-07-29 13:41:57 +04:00
“Naeel” 73480c81fc v1.1.28: HttpClient.get() resilient to empty body — return {} instead of JSONDecodeError 2026-07-29 13:32:17 +04:00
“Naeel” 4bc35d73ec v1.1.27: busy lock — block operations while another is running 2026-07-29 13:30:53 +04:00
“Naeel” fbbfef2916 v1.1.26: handle empty validate-cfs response (JSONDecodeError) 2026-07-29 13:24:00 +04:00
“Naeel” 9658d0459a v1.1.25: full Terraform parity — normalize, resolveRefSvc, send ALL params, 30min timeout, svc in fields 2026-07-29 13:17:45 +04:00
“Naeel” f9c6c5cf2c v1.1.24: step 6 from REAL operation (not template) — fixes serviceInstanceUid 2026-07-29 12:59:13 +04:00
“Naeel” 8190a93382 docs: Sonnet found root cause — template vs real operation for step 6 2026-07-29 12:57:41 +04:00
“Naeel” d558ae14b6 docs: add Terraform provider source paths to Sonnet request 2026-07-29 12:51:48 +04:00
“Naeel” 6398fa475e docs: Sonnet — full Terraform diff analysis request 2026-07-29 12:49:10 +04:00
“Naeel” dd9c70091e v1.1.23: fix None defaultValue for map-fixed — build JSON from sub-param defaults 2026-07-29 12:48:23 +04:00
“Naeel” 2ef23d0243 v1.1.22: fix currentSvcShort scope — move to module level 2026-07-29 12:37:50 +04:00
“Naeel” 835cdff66d v1.1.21: 6 fixes — _finish_op args, connection leak, pool init, XSS, secure cookie, let 2026-07-29 12:01:00 +04:00
“Naeel” ae91e06e05 docs: Sonnet vs Opus comparison + fix plan 2026-07-29 11:59:01 +04:00
“Naeel” 1423b284be docs: Sonnet full review response — 3 critical + 4 important bugs 2026-07-29 11:52:24 +04:00
“Naeel” 818a8b0600 docs: Sonnet FULL code review — all 17 files 2026-07-29 11:40:38 +04:00
“Naeel” a6b765d7ae v1.1.20: fix _client() → get_client() — NameError in status polling 2026-07-29 11:39:56 +04:00
“Naeel” 133569d163 v1.1.19: send required+default params (Terraform step 6) + validate-cfs 2026-07-29 11:15:41 +04:00
“Naeel” bad557e070 docs: Sonnet new chat — full context for missing required params 2026-07-29 11:12:25 +04:00
“Naeel” 62a7ef7818 docs: Sonnet round 3 — missing required params in CREATE 2026-07-29 11:10:01 +04:00
“Naeel” 6476e89dea v1.1.18: fix stages position for CREATE — after create-btn, not in inst-list 2026-07-29 11:03:31 +04:00
“Naeel” 98dbb4fcd1 v1.1.17: fix sort TypeError — string negation crashed API 2026-07-29 10:21:34 +04:00
“Naeel” 29bc0cd06a v1.1.16: remove serviceId filter, sort by svc+date, scrollable inst-list 2026-07-29 10:10:41 +04:00
“Naeel” 9f30aba161 v1.1.15: dynamic stages-box — inline after instance, not below all 2026-07-29 09:43:29 +04:00
“Naeel” dbb4f03607 v1.1.14: serviceId filter, svcShort displayName, descr, remove duplicate endpoint 2026-07-29 09:34:46 +04:00
“Naeel” 70034e556c docs: absolute paths in Sonnet round 2 2026-07-29 09:26:33 +04:00
“Naeel” 615436fc05 docs: Sonnet round 2 — remaining bugs and fix plan 2026-07-29 09:22:36 +04:00
“Naeel” d671ddea06 v1.1.13: service highlight, dynamic btn text, defaultValue in dataDescriptor 2026-07-29 09:05:23 +04:00
“Naeel” d734945f1f v1.1.12: fix NameError — missing import + JS error handling in showParams 2026-07-29 08:53:53 +04:00
“Naeel” a5739bd7fa docs: Sonnet 4.6 code review questions for v1.1.11 2026-07-29 08:45:52 +04:00
“Naeel” acc8ecfda0 v1.1.11: normalize valueList CSV→array for nested dataDescriptor params 2026-07-28 13:56:58 +04:00
“Naeel” 3fffa2b2fe v1.1.10: real svc per instance, create header, required marks for nested 2026-07-28 13:50:34 +04:00
“Naeel” 4cc84e68e8 v1.1.9: expand dataDescriptor — nested map params as individual fields 2026-07-28 13:38:57 +04:00