Compare commits
16
Commits
a19fab34e3
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d65d1fdf5c | ||
|
|
3cb1201b32 | ||
|
|
d37297b889 | ||
|
|
d9a616cdfb | ||
|
|
8e06815bc9 | ||
|
|
27b82c169e | ||
|
|
85f81d8e0a | ||
|
|
6064cce05e | ||
|
|
fbda9516fe | ||
|
|
72bf10dcec | ||
|
|
29e580c461 | ||
|
|
1e23001e73 | ||
|
|
6c5342219a | ||
|
|
231d11528a | ||
|
|
6bddbfba5a | ||
|
|
34f26e6948 |
@@ -5,3 +5,12 @@ gitea/droplet-runner/*.sh text eol=lf
|
|||||||
|
|
||||||
# Preserve spaces emitted by tools in captured evidence.
|
# Preserve spaces emitted by tools in captured evidence.
|
||||||
delivery/evidence/*.txt -whitespace
|
delivery/evidence/*.txt -whitespace
|
||||||
|
|
||||||
|
# Keep captured observer CSV bytes and public runtime hashes reproducible.
|
||||||
|
delivery/evidence/recovery-*.csv -text
|
||||||
|
delivery/evidence/recovery-*.json text eol=lf
|
||||||
|
|
||||||
|
# Keep the frozen upstream blobs and their provenance byte-identical on checkout.
|
||||||
|
demo/tikzrefinery/** -text -whitespace
|
||||||
|
demo/snapshot.json -text
|
||||||
|
demo/ci/*.sh text eol=lf
|
||||||
|
|||||||
@@ -14,6 +14,8 @@
|
|||||||
|
|
||||||
# Intermediate documents and automatic conversions
|
# Intermediate documents and automatic conversions
|
||||||
*.dvi
|
*.dvi
|
||||||
|
# This exact upstream asset is part of the frozen, hash-verified demo input.
|
||||||
|
!/demo/tikzrefinery/documents/assets/loop-example/loop-boxes.dvi
|
||||||
*.xdv
|
*.xdv
|
||||||
*-converted-to.*
|
*-converted-to.*
|
||||||
|
|
||||||
|
|||||||
+23
-9
@@ -1,13 +1,25 @@
|
|||||||
# Assignment 8 evidence
|
# Assignment 8 evidence
|
||||||
|
|
||||||
## Reviewed Jenkins execution, 15 November 2026
|
## Completed Jenkins execution, 15 November Eastern / 16 November UTC
|
||||||
|
|
||||||
PR 24 is merged. The actual [test/secret gate demonstrations](evidence/gates-20261115.md)
|
PRs 24–26 are merged. The actual [test/secret gate demonstrations](evidence/gates-20261115.md)
|
||||||
blocked as intended. [Release attempt 3](evidence/release-attempt-3-20261115.md)
|
blocked as intended. [Release attempt 3](evidence/release-attempt-3-20261115.md)
|
||||||
passed scans and published v1, then stopped before any app change at the
|
published v1 and stopped at the Ansible PTY request. After that correction
|
||||||
Ansible PTY request. The noninteractive SSH correction was verified in
|
merged, [release attempt 4](evidence/release-attempt-4-20261115.md) passed initial
|
||||||
agent-preflight build 3 but awaits source review/merge. No successful promotion,
|
staging checks but its unchanged rerun stopped at Docker's health timeout.
|
||||||
production approval or recovery has occurred.
|
Eight isolated diagnostic probes passed with ten seconds instead of three.
|
||||||
|
After review, [builds 5 and 6](evidence/releases-20261115.md) completed v1/v2
|
||||||
|
promotions, zero-change reruns and actual human approvals. Production monitoring
|
||||||
|
is live; one HTTP 502 sample during v2 replacement is preserved. The exact
|
||||||
|
successful records and staging-only fault/revert history were reviewed in PR 27.
|
||||||
|
[Completed recovery evidence](evidence/recovery-20261115.md) records build 7's
|
||||||
|
pre-deployment runner error, human-approved rollback 8, blocked staging fault 9,
|
||||||
|
and original-configuration recovery 10 with changed=0. Final production is
|
||||||
|
healthy v1/total 30 and staging v2/total 36. Original CSVs, hashes, runtime
|
||||||
|
checks and monitoring correlation preserve observed interruptions and limits.
|
||||||
|
[Issue 28](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/issues/28) was
|
||||||
|
created during finalization with Vincent's authorization; final group review
|
||||||
|
and submission remain.
|
||||||
|
|
||||||
## Preparation evidence — historical baseline
|
## Preparation evidence — historical baseline
|
||||||
|
|
||||||
@@ -55,12 +67,14 @@ from the initial laptop checks above. UTC dates cross into November 15 while
|
|||||||
the client's Eastern date is still November 14. At that point the PDF runner
|
the client's Eastern date is still November 14. At that point the PDF runner
|
||||||
was unchanged. It subsequently moved too; see the
|
was unchanged. It subsequently moved too; see the
|
||||||
[manual runner migration record](../gitea/droplet-runner/EVIDENCE.md).
|
[manual runner migration record](../gitea/droplet-runner/EVIDENCE.md).
|
||||||
Assessed releases and recovery are still pending.
|
At that migration snapshot, assessed releases and recovery were still pending;
|
||||||
|
the completed results are linked above.
|
||||||
|
|
||||||
## DNS and TLS readiness
|
## DNS and TLS readiness
|
||||||
|
|
||||||
On 15 November Billy's two DNS records were verified and Caddy's prepared
|
On 15 November Billy's two DNS records were verified and Caddy's prepared
|
||||||
routes applied. Both names have trusted TLS and HTTP 308 redirects; HTTPS
|
routes applied. Both names have trusted TLS and HTTP 308 redirects; HTTPS
|
||||||
returns 502 while pricing backends are absent. See the
|
returned 502 while pricing backends were absent. See the
|
||||||
[dated HTTPS evidence](evidence/https-20261115.md). Application deployment,
|
[dated HTTPS evidence](evidence/https-20261115.md). Application deployment,
|
||||||
production monitoring and assessed recovery evidence remain pending.
|
production monitoring and recovery were pending at that readiness snapshot;
|
||||||
|
their subsequent completed results are linked above.
|
||||||
|
|||||||
+23
-8
@@ -6,14 +6,29 @@ existing Gitea/Jenkins/Caddy/monitoring foundation.
|
|||||||
- [x] Prepare exact dependencies, base digest, trusted agent and Ansible.
|
- [x] Prepare exact dependencies, base digest, trusted agent and Ansible.
|
||||||
- [x] Verify deploy SSH, host-key pinning, sudo and target prerequisites.
|
- [x] Verify deploy SSH, host-key pinning, sudo and target prerequisites.
|
||||||
- [x] Prepare gates, pipeline, approval and recovery automation.
|
- [x] Prepare gates, pipeline, approval and recovery automation.
|
||||||
- [ ] Review/merge v1 source; configure staging/app DNS and TLS routes.
|
- [x] Review/merge v1 source; configure staging/app DNS and TLS routes.
|
||||||
- [ ] Show blocked unit-test and synthetic-secret Jenkins runs, then repair.
|
- [x] Show blocked unit-test and synthetic-secret Jenkins runs, then repair.
|
||||||
- [ ] Publish v1; deploy staging; prove changed=0; approve production.
|
- [x] Publish v1; deploy staging; prove changed=0; approve production.
|
||||||
- [ ] Preserve v1 records; review/merge v2; promote the same v2 digest.
|
- [x] Preserve v1 records; review/merge v2; promote the same v2 digest.
|
||||||
- [ ] Roll production back to matching v1 image/config; measure interruption.
|
- [x] Roll production back to matching v1 image/config; measure interruption.
|
||||||
- [ ] Review staging-only bad command; show failed wait and recovery.
|
- [x] Review staging-only bad command; show failed wait and recovery.
|
||||||
- [ ] Add production monitoring and correlate actual samples/timestamps.
|
- [x] Add production monitoring and correlate actual samples/timestamps.
|
||||||
- [ ] Finalize traceability, runbooks, history, AI log and one PDF.
|
- [ ] Review/merge final traceability, runbooks, history, AI log and PDF; submit.
|
||||||
|
|
||||||
|
Actual execution, 15 November Eastern / 16 November UTC:
|
||||||
|
|
||||||
|
- Reviewed implementation and corrections: PRs [24](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/24), [25](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/25), [26](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/26), and [27](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/27).
|
||||||
|
- [Build 5](https://ci.yebilly.me/job/secure-delivery/job/pricing/5/) and [build 6](https://ci.yebilly.me/job/secure-delivery/job/pricing/6/): v1/v2 promotions, exact digests, passing gates, changed=0, and real Vincent approvals.
|
||||||
|
- [Build 8](https://ci.yebilly.me/job/secure-delivery/job/pricing/8/): healthy production rollback passed with original v1 image/configuration, source 34f26e6 and total 30. Vincent approved at 04:23:36 UTC. Nine failed HTTPS samples were observed; zero downtime is not claimed.
|
||||||
|
- [Build 9](https://ci.yebilly.me/job/secure-delivery/job/pricing/9/): the reviewed staging-only port mismatch failed Compose wait and blocked production.
|
||||||
|
- [Build 10](https://ci.yebilly.me/job/secure-delivery/job/pricing/10/): restored the original v2 staging configuration/digest, source 6bddbfb, total 36, then changed=0 on rerun.
|
||||||
|
- Final verified state at 04:32 UTC: production v1, staging v2; both healthy. Six monitoring targets were up. Prometheus's 30-second samples missed the brief rollback interruption that the one-second observer captured. Staging had 169 failed samples during the deliberate fault/recovery.
|
||||||
|
|
||||||
|
This tracking issue was created during finalization, after the implementation
|
||||||
|
PRs and operational exercises; it is not a claimed pre-implementation issue.
|
||||||
|
The final evidence PR should close it after peer review. A first rollback
|
||||||
|
attempt (build 7) stopped before deployment with a runner process-limit error;
|
||||||
|
the idle runner was restarted without changing its limits before build 8.
|
||||||
|
|
||||||
Local preparation is not assessed release evidence. Preserve branch protection
|
Local preparation is not assessed release evidence. Preserve branch protection
|
||||||
and earlier services/data; keep credentials out of Git and reports.
|
and earlier services/data; keep credentials out of Git and reports.
|
||||||
|
|||||||
+23
-12
@@ -1,15 +1,26 @@
|
|||||||
# Fix noninteractive Ansible deployment over the restricted SSH key
|
# Record completed rollback and staging recovery (closes #28)
|
||||||
|
|
||||||
The first reviewed v1 release passed its tests and security gates and published
|
Record build 8's human-approved production rollback to the original v1
|
||||||
an image, but stopped during Ansible Gathering Facts: Ansible forced a PTY
|
image/configuration, build 9's staging bind-mismatch block, and build 10's
|
||||||
that the dedicated deploy key forbids. Set `ansible_ssh_use_tty=false` in the
|
restored v2 staging deployment with changed=0 on rerun. Final production is
|
||||||
delivery inventory and extend the administrator preflight to exercise Ansible's
|
healthy v1/total 30 and staging v2/total 36. No app, pipeline, deployment-template,
|
||||||
actual SSH/sudo path. Keep the key restriction and pinned host verification.
|
credential or resource/security-limit change is included.
|
||||||
|
|
||||||
Record the actual Jenkins test/secret blocks, passing image scans and publication,
|
Preserve actual decisions, approval, timings, report hashes, runtime checks and
|
||||||
zero-change staging connection failure, and successful connection preflight.
|
original HTTPS CSVs. Nine production requests failed during rollback although
|
||||||
No app deployment or production approval is claimed. Retry v1 after merge;
|
the 30-second probe missed it; staging recorded 169 failures during the
|
||||||
v2 promotion, both recoveries and monitoring evidence still remain.
|
deliberate fault/recovery. Retain build 7's pre-deployment process-limit error
|
||||||
|
and unchanged-limit runner restart. Document sampling and single-Droplet limits.
|
||||||
|
|
||||||
Validation: credential-bound Jenkins agent-preflight build 3 passed and returned
|
Update the manual, diagram, inventory, source/access links, runbooks, history
|
||||||
root UID 0 through Ansible without a PTY; twelve release-control tests passed.
|
and AI log. Issue 28 was created during finalization with Vincent's approval;
|
||||||
|
it is not represented as a pre-implementation issue. Preserve CSV bytes and
|
||||||
|
JSON line endings for reproducible evidence hashes.
|
||||||
|
|
||||||
|
Validation: actual Jenkins 8 SUCCESS, 9 expected FAILURE before production,
|
||||||
|
10 SUCCESS; 12 control/3 app tests and source/dependency gates in each;
|
||||||
|
matching historical selectors; final HTTPS health/source/price/400 checks and
|
||||||
|
six monitoring targets up. Full manual build and affected-page visual review.
|
||||||
|
Existing coursework, earlier services and grading evidence retained.
|
||||||
|
|
||||||
|
Closes #28.
|
||||||
|
|||||||
+37
-24
@@ -1,7 +1,7 @@
|
|||||||
# Secure Delivery and Rollback — Assignment 8
|
# Secure Delivery and Rollback — Assignment 8
|
||||||
|
|
||||||
The active application starts with the instructor's Startup Pricing Service
|
The application is adapted from the instructor's Startup Pricing Service
|
||||||
v1 from `Examples.zip`, `Examples/dosSecureDelivery/v1/`. The deployment
|
v1 in `Examples.zip`, `Examples/dosSecureDelivery/v1/`. The deployment
|
||||||
starters come from that bundle's `ansible/` directory. The task follows
|
starters come from that bundle's `ansible/` directory. The task follows
|
||||||
Chapter 6 of instructor manual version 1.43.
|
Chapter 6 of instructor manual version 1.43.
|
||||||
|
|
||||||
@@ -11,18 +11,23 @@ The inventory selects The-Ocean's dedicated deploy account. The example
|
|||||||
release record remains explicitly an example; real registry digests are
|
release record remains explicitly an example; real registry digests are
|
||||||
generated by Jenkins from reviewed source.
|
generated by Jenkins from reviewed source.
|
||||||
|
|
||||||
Current execution status, 15 November: PR 24 is merged and the delivery job
|
Current execution status, 15 November Eastern / 16 November UTC: PRs 24–27
|
||||||
is enabled. Real Jenkins test/secret demonstrations blocked as intended. The
|
are merged, preserving the separate v1/v2 commits. Real Jenkins test/secret
|
||||||
first v1 image was scanned and published, but staging stopped before any app
|
demonstrations blocked as intended. Builds 5 and 6 then completed both releases,
|
||||||
change because Ansible requested a PTY forbidden by the deploy key. The
|
with zero-change staging reruns, passing gates and actual human production
|
||||||
noninteractive inventory correction and expanded, passing Ansible preflight
|
approvals. PR 27 reviewed the successful records and fault/revert history.
|
||||||
await review/merge. See [gate evidence](evidence/gates-20261115.md) and
|
Build 8 passed production rollback to v1; build 9 blocked the staging fault;
|
||||||
[release attempt 3](evidence/release-attempt-3-20261115.md).
|
build 10 restored staging v2 with changed=0. Production is v1/total 30 and
|
||||||
|
staging v2/total 36, both healthy; production monitoring is live.
|
||||||
|
See [releases](evidence/releases-20261115.md) and
|
||||||
|
[completed recoveries](evidence/recovery-20261115.md), including interruption,
|
||||||
|
sampling limits and build 7's pre-deployment runner error. Final review/merge
|
||||||
|
and submission remain.
|
||||||
|
|
||||||
Run the tests from `app/` after installing its requirements into the selected
|
Run the tests from `app/` after installing its requirements into the selected
|
||||||
Linux test environment. The expected v1 result for three units is USD 30.
|
Linux test environment. The expected v1 result for three units is USD 30.
|
||||||
The later v2 source/test change will be a separate reviewed commit and will
|
The reviewed v2 source/test change returns USD 36. PR 26 preserved the separate
|
||||||
return USD 36. The source commit must be baked into each built image.
|
v1 and v2 SHAs, selected explicitly by builds 5 and 6 and baked into each image.
|
||||||
|
|
||||||
Deployment work uses a dedicated trusted Jenkins agent, immutable images
|
Deployment work uses a dedicated trusted Jenkins agent, immutable images
|
||||||
in the existing Gitea registry, and separate Ansible-managed staging and
|
in the existing Gitea registry, and separate Ansible-managed staging and
|
||||||
@@ -33,6 +38,11 @@ and both recovery exercises require dated execution evidence.
|
|||||||
|
|
||||||
## Attribution and preparation record
|
## Attribution and preparation record
|
||||||
|
|
||||||
|
The 23 November [Java security update](../security/java/README.md) replaces the
|
||||||
|
trusted agent's Java runtime with pinned Temurin 21.0.13.1+2. Its current image
|
||||||
|
is `ssw590-delivery-agent:20261114-java21.0.13.1-2`; historical execution evidence
|
||||||
|
below retains the original versions actually used.
|
||||||
|
|
||||||
On 14 November 2026 Vincent asked Codex to review the assignment and begin
|
On 14 November 2026 Vincent asked Codex to review the assignment and begin
|
||||||
preparation while he started Docker Desktop. Codex checked the repository's
|
preparation while he started Docker Desktop. Codex checked the repository's
|
||||||
AI requirements and usage guide, read Chapter 6 and the example sources,
|
AI requirements and usage guide, read Chapter 6 and the example sources,
|
||||||
@@ -101,25 +111,28 @@ now depends on Docker Desktop. Run manual builds and delivery releases sequentia
|
|||||||
See `RUNBOOKS.md`.
|
See `RUNBOOKS.md`.
|
||||||
|
|
||||||
Ansible syntax, agent Compose configuration, and the installed Jenkins
|
Ansible syntax, agent Compose configuration, and the installed Jenkins
|
||||||
controller's declarative parser checks passed. These are preparation checks;
|
controller's declarative parser checks passed. Those were preparation checks;
|
||||||
**successful v1/v2 deployment, promotion and recovery are not yet demonstrated**.
|
the subsequent assessed releases and both recovery cases are linked above.
|
||||||
|
|
||||||
## Remaining checkpoints
|
## Remaining checkpoints
|
||||||
|
|
||||||
Vincent merged PR #24, including runner migration and HTTPS, after Billy's
|
PRs 24–27 preserve the implementation, corrections, separate v1/v2 source
|
||||||
latest review. Review/merge the noninteractive Ansible correction before
|
commits and recovery configuration history. The technical demonstrations are
|
||||||
retrying v1. Create the assignment issue if still absent. Keep main protection.
|
complete. [Issue 28](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/issues/28)
|
||||||
Billy added the A
|
was created with Vincent's authorization during finalization, after execution;
|
||||||
records; Google and Cloudflare now resolve both names to `147.182.178.136`.
|
the final evidence PR should close it following Billy's review. Vincent handles
|
||||||
On 15 November Caddy's prepared routes were validated and gracefully reloaded;
|
commits, pushes and PDF submission. No further intentional failure is needed.
|
||||||
both names have trusted HTTPS and HTTP redirects. They currently return 502
|
Main and live staging have the good template. Keep branch protection and
|
||||||
because the app containers are not deployed. See `evidence/https-20261115.md`.
|
earlier services. Both names retain trusted HTTPS and redirects; the initial
|
||||||
The release job is enabled; follow `RUNBOOKS.md` after the corrected source reaches main.
|
TLS snapshot remains `evidence/https-20261115.md`.
|
||||||
|
Use `RUNBOOKS.md` for later authorized operations.
|
||||||
Keep Jenkins and the remote delivery node available. Production approval requires an authorized
|
Keep Jenkins and the remote delivery node available. Production approval requires an authorized
|
||||||
human; an agent must not approve unattended.
|
human; an agent must not approve unattended.
|
||||||
|
|
||||||
`SECURITY.md` defines the gate policy. `bootstrap/` makes administrator setup
|
`SECURITY.md` defines the gate policy. `bootstrap/` makes administrator setup
|
||||||
reviewable; its one-time script refuses to overwrite existing deployment state.
|
reviewable; its one-time script refuses to overwrite existing deployment state.
|
||||||
Raw local reports remain under ignored `build/evidence/assignment8-local/`.
|
Raw local reports remain under ignored `build/evidence/assignment8-local/`.
|
||||||
The manual records material AI assistance and distinguishes pending work from
|
The manual records actual outcomes, access instructions, limitations and AI
|
||||||
actual evidence. This preparation is not ready for assignment submission.
|
assistance. Raw assessed reports are in ignored
|
||||||
|
`build/evidence/assignment8-execution/` and Jenkins artifacts; non-secret
|
||||||
|
summaries, hashes and original observer CSVs are versioned under `evidence/`.
|
||||||
|
|||||||
+27
-13
@@ -1,17 +1,19 @@
|
|||||||
# Release, recovery and cleanup
|
# Release, recovery and cleanup
|
||||||
|
|
||||||
These are execution instructions, not completed release evidence.
|
These are repeatable instructions. Completed results are recorded in
|
||||||
|
`evidence/releases-20261115.md` and `evidence/recovery-20261115.md`.
|
||||||
|
|
||||||
Current status, 15 November 2026: Billy's DNS records resolve correctly and the
|
Current status, 15 November 2026 Eastern / 16 November UTC: Billy's DNS records resolve correctly and the
|
||||||
two Caddy routes are active with trusted certificates and HTTP-to-HTTPS redirects.
|
two Caddy routes are active with trusted certificates and HTTP-to-HTTPS redirects.
|
||||||
502 is expected while the app backends are absent. The one-time HTTPS helper
|
The one-time HTTPS helper has already run; use the normal validate/reload
|
||||||
has already run; use the normal validate/reload procedure for later changes.
|
procedure for later changes. PRs 24–27 are merged. Actual builds 5/6 passed
|
||||||
The reviewed preparation is merged, the release job is enabled, and real
|
v1/v2 promotions, zero-change reruns and real vsun1 approvals. Both environments
|
||||||
Jenkins test/secret blocks are recorded. Release build 3 published v1 but
|
passed both promotions. Build 8 restored production v1 with human approval;
|
||||||
stopped at Ansible's PTY request before any app change. Review/merge the
|
build 9 blocked the reviewed staging fault; build 10 restored staging v2 and
|
||||||
noninteractive inventory correction and retry from the corrected main SHA.
|
passed changed=0. Production is v1/total 30, staging v2/total 36. The production
|
||||||
The expanded Ansible/sudo preflight passed; full deployment remains unverified.
|
probe/panel is live. Actual interruption and sampling limits are preserved.
|
||||||
Monitoring additions and successful releases remain pending.
|
The successful records and fault/revert are reviewed main ancestors; no repeat
|
||||||
|
exercise is required for the completed evidence.
|
||||||
|
|
||||||
## Authority and preparation
|
## Authority and preparation
|
||||||
|
|
||||||
@@ -36,9 +38,13 @@ docker exec gitea-caddy-1 caddy reload --config /etc/caddy/Caddyfile --adapter c
|
|||||||
docker exec monitoring-prometheus-1 promtool check config /etc/prometheus/prometheus.yml
|
docker exec monitoring-prometheus-1 promtool check config /etc/prometheus/prometheus.yml
|
||||||
```
|
```
|
||||||
|
|
||||||
Preserve bind-mounted file inodes when copying new contents. Apply monitoring
|
Preserve bind-mounted file inodes when copying new contents. Monitoring was
|
||||||
only after healthy production, then reload using its existing documented
|
applied only after healthy v1 production, using the guarded one-time
|
||||||
procedure. The temporary candidate checks already passed without a reload.
|
`bootstrap/enable-production-monitoring.py`. It compares prior probes/panels,
|
||||||
|
validates with promtool, backs up and reloads Prometheus via SIGHUP. Do not
|
||||||
|
rerun its one-time application over the already changed state. The protected
|
||||||
|
backup is `/root/ssw590-delivery-bootstrap/monitoring-20261116/`. Actual targets,
|
||||||
|
reload metric and the provisioned Grafana panel were verified separately.
|
||||||
|
|
||||||
## v1 and v2
|
## v1 and v2
|
||||||
|
|
||||||
@@ -61,6 +67,14 @@ procedure. The temporary candidate checks already passed without a reload.
|
|||||||
VERSION=v2, UNIT_PRICE=12, expected total=36. Repeat the complete release and
|
VERSION=v2, UNIT_PRICE=12, expected total=36. Repeat the complete release and
|
||||||
real approval. Preserve v1 images/configuration/records; save v2 records.
|
real approval. Preserve v1 images/configuration/records; save v2 records.
|
||||||
|
|
||||||
|
The v1 health correction and v2 source/test change may be reviewed together
|
||||||
|
in one PR while remaining separate commits. Do not squash them: the delivery
|
||||||
|
job requires both selected source commits to remain ancestors of protected
|
||||||
|
main. Start with the full v1 health-fix SHA, then use the full v2 SHA only after
|
||||||
|
v1 production verification. The actual successful records were reviewed in PR 27;
|
||||||
|
review any replacement records before later rollback. Never substitute a failed
|
||||||
|
attempt's generated record for that evidence.
|
||||||
|
|
||||||
## Healthy production rollback
|
## Healthy production rollback
|
||||||
|
|
||||||
Record the detection/decision UTC and reason. Before approval, start the HTTPS
|
Record the detection/decision UTC and reason. Before approval, start the HTTPS
|
||||||
|
|||||||
@@ -1,8 +1,12 @@
|
|||||||
|
FROM eclipse-temurin:21.0.13.1_2-jdk-jammy@sha256:4b3d0998ee65462bd86ff060c87119b3575294cb3d0927372afa6f3708b0c8db AS patched_java
|
||||||
FROM docker:29-cli@sha256:5a7af0dcb0e46c803efe9b45371dd21cb500e5b4453250394ac6f06d49b6e6f1 AS dockercli
|
FROM docker:29-cli@sha256:5a7af0dcb0e46c803efe9b45371dd21cb500e5b4453250394ac6f06d49b6e6f1 AS dockercli
|
||||||
FROM aquasec/trivy:0.76.2@sha256:8f6bb947dbc528902e11f2f5be52f7b519f6a39d5d148f41166f2040499768fb AS scanner
|
FROM aquasec/trivy:0.76.2@sha256:8f6bb947dbc528902e11f2f5be52f7b519f6a39d5d148f41166f2040499768fb AS scanner
|
||||||
FROM jenkins/inbound-agent:jdk21@sha256:25a3704f7de4d3d0becc441f5683a227556658df1473865ee94c5232355678ab
|
FROM jenkins/inbound-agent:jdk21@sha256:25a3704f7de4d3d0becc441f5683a227556658df1473865ee94c5232355678ab
|
||||||
|
|
||||||
USER root
|
USER root
|
||||||
|
RUN rm -rf /opt/java/openjdk
|
||||||
|
COPY --from=patched_java /opt/java/openjdk /opt/java/openjdk
|
||||||
|
ENV JAVA_VERSION=jdk-21.0.13.1+2
|
||||||
RUN apt-get update \
|
RUN apt-get update \
|
||||||
&& apt-get install -y --no-install-recommends python3 python3-venv git openssh-client ca-certificates curl \
|
&& apt-get install -y --no-install-recommends python3 python3-venv git openssh-client ca-certificates curl \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
name: ssw590-delivery
|
name: ssw590-delivery
|
||||||
services:
|
services:
|
||||||
agent:
|
agent:
|
||||||
image: ssw590-delivery-agent:20261114
|
image: ssw590-delivery-agent:20261114-java21.0.13.1-2
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
entrypoint: ["java", "-jar", "/usr/share/jenkins/agent.jar"]
|
entrypoint: ["java", "-jar", "/usr/share/jenkins/agent.jar"]
|
||||||
command:
|
command:
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
name: ssw590-delivery
|
name: ssw590-delivery
|
||||||
services:
|
services:
|
||||||
agent:
|
agent:
|
||||||
image: ssw590-delivery-agent:20261114
|
image: ssw590-delivery-agent:20261114-java21.0.13.1-2
|
||||||
restart: "no"
|
restart: "no"
|
||||||
entrypoint: ["java", "-jar", "/usr/share/jenkins/agent.jar"]
|
entrypoint: ["java", "-jar", "/usr/share/jenkins/agent.jar"]
|
||||||
command:
|
command:
|
||||||
|
|||||||
@@ -9,5 +9,6 @@ RUN pip install --no-cache-dir -r requirements.txt \
|
|||||||
COPY app.py .
|
COPY app.py .
|
||||||
USER 10001:10001
|
USER 10001:10001
|
||||||
EXPOSE 8000
|
EXPOSE 8000
|
||||||
HEALTHCHECK --interval=10s --timeout=3s --start-period=10s --retries=3 CMD python -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8000/health', timeout=2)"
|
# Allow Python startup under the 0.25 CPU cap; the HTTP timeout remains 2s.
|
||||||
|
HEALTHCHECK --interval=10s --timeout=10s --start-period=10s --retries=3 CMD python -c "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8000/health', timeout=2)"
|
||||||
CMD ["gunicorn", "--bind", "0.0.0.0:8000", "--workers", "1", "--worker-tmp-dir", "/tmp", "app:app"]
|
CMD ["gunicorn", "--bind", "0.0.0.0:8000", "--workers", "1", "--worker-tmp-dir", "/tmp", "app:app"]
|
||||||
|
|||||||
+2
-2
@@ -2,8 +2,8 @@ import os
|
|||||||
from flask import Flask, jsonify, request
|
from flask import Flask, jsonify, request
|
||||||
|
|
||||||
app = Flask(__name__)
|
app = Flask(__name__)
|
||||||
VERSION = "v1"
|
VERSION = "v2"
|
||||||
UNIT_PRICE = 10
|
UNIT_PRICE = 12
|
||||||
COMMIT = os.environ.get("APP_COMMIT", "development")
|
COMMIT = os.environ.get("APP_COMMIT", "development")
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -7,17 +7,17 @@ class PricingTests(unittest.TestCase):
|
|||||||
self.client = app.test_client()
|
self.client = app.test_client()
|
||||||
|
|
||||||
def test_price(self):
|
def test_price(self):
|
||||||
self.assertEqual(total_price(3), 30)
|
self.assertEqual(total_price(3), 36)
|
||||||
response = self.client.get("/price?quantity=3")
|
response = self.client.get("/price?quantity=3")
|
||||||
self.assertEqual(response.status_code, 200)
|
self.assertEqual(response.status_code, 200)
|
||||||
self.assertEqual(response.json["total"], 30)
|
self.assertEqual(response.json["total"], 36)
|
||||||
|
|
||||||
def test_invalid_quantity(self):
|
def test_invalid_quantity(self):
|
||||||
for value in ["0", "-1", "1001", "abc", "1.5"]:
|
for value in ["0", "-1", "1001", "abc", "1.5"]:
|
||||||
self.assertEqual(self.client.get("/price?quantity=" + value).status_code, 400)
|
self.assertEqual(self.client.get("/price?quantity=" + value).status_code, 400)
|
||||||
|
|
||||||
def test_release_identity(self):
|
def test_release_identity(self):
|
||||||
self.assertEqual(self.client.get("/").json["version"], "v1")
|
self.assertEqual(self.client.get("/").json["version"], "v2")
|
||||||
self.assertEqual(self.client.get("/health").json["status"], "ok")
|
self.assertEqual(self.client.get("/health").json["status"], "ok")
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,79 @@
|
|||||||
|
"""Apply the reviewed production probe/panel only after production is healthy."""
|
||||||
|
import argparse
|
||||||
|
from datetime import datetime, timezone
|
||||||
|
import hashlib
|
||||||
|
import json
|
||||||
|
import os
|
||||||
|
from pathlib import Path
|
||||||
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
import urllib.request
|
||||||
|
|
||||||
|
parser = argparse.ArgumentParser()
|
||||||
|
parser.add_argument('--prometheus', required=True, type=Path)
|
||||||
|
parser.add_argument('--dashboard', required=True, type=Path)
|
||||||
|
parser.add_argument('--backup', required=True, type=Path)
|
||||||
|
parser.add_argument('--apply', action='store_true')
|
||||||
|
args = parser.parse_args()
|
||||||
|
live_prom = Path('/root/monitoring/prometheus/prometheus.yml')
|
||||||
|
live_dashboard = Path('/root/monitoring/grafana/dashboards/sre.json')
|
||||||
|
before = {live_prom:live_prom.read_bytes(), live_dashboard:live_dashboard.read_bytes()}
|
||||||
|
candidate_prom = args.prometheus.read_text().replace('\r\n','\n')
|
||||||
|
candidate_dashboard = args.dashboard.read_bytes()
|
||||||
|
addition = ' # Apply this addition only after Assignment 8 production is healthy.\n - https://app.yebilly.me/health\n'
|
||||||
|
assert candidate_prom.count(addition) == 1, 'Unexpected production probe'
|
||||||
|
assert candidate_prom.replace(addition,'').strip() == before[live_prom].decode().replace('\r\n','\n').strip(), 'Existing probes differ; inspect before changing'
|
||||||
|
old = json.loads(before[live_dashboard])
|
||||||
|
new = json.loads(candidate_dashboard)
|
||||||
|
assert old['uid'] == new['uid'] == 'group1-sre'
|
||||||
|
assert old['version'] == 1 and new['version'] == 2
|
||||||
|
panel = new['panels'][-1]
|
||||||
|
assert panel['id'] == 8 and panel['type'] == 'timeseries'
|
||||||
|
assert panel['targets'][0]['expr'] == 'probe_success{job="https",instance="https://app.yebilly.me/health"}'
|
||||||
|
comparison = dict(new, version=old['version'], panels=new['panels'][:-1])
|
||||||
|
assert comparison == old, 'Existing dashboard differs; inspect before changing'
|
||||||
|
with urllib.request.urlopen('https://app.yebilly.me/health',timeout=10) as response:
|
||||||
|
health = json.load(response)
|
||||||
|
assert response.status == 200 and health['status'] == 'ok' and health['version'] in {'v1','v2'}, 'Production must be healthy first'
|
||||||
|
|
||||||
|
stamp = datetime.now(timezone.utc).strftime('%Y%m%dT%H%M%S%fZ')
|
||||||
|
temporary = '/tmp/ssw590-production-probe-' + stamp + '.yml'
|
||||||
|
subprocess.run(['docker','cp',str(args.prometheus),'monitoring-prometheus-1:'+temporary],check=True,capture_output=True)
|
||||||
|
try:
|
||||||
|
validation = subprocess.check_output(['docker','exec','monitoring-prometheus-1','promtool','check','config',temporary],text=True)
|
||||||
|
if not args.apply:
|
||||||
|
print(validation + 'Validated only; no active file changed.')
|
||||||
|
raise SystemExit(0)
|
||||||
|
args.backup.mkdir(parents=True,mode=0o700,exist_ok=False)
|
||||||
|
for path in before:
|
||||||
|
shutil.copy2(path,args.backup / (path.name + '.before'))
|
||||||
|
inodes = {p:p.stat().st_ino for p in before}
|
||||||
|
|
||||||
|
def write(path,content):
|
||||||
|
with path.open('wb') as stream:
|
||||||
|
stream.write(content)
|
||||||
|
stream.flush()
|
||||||
|
os.fsync(stream.fileno())
|
||||||
|
assert path.stat().st_ino == inodes[path], 'Bind inode changed'
|
||||||
|
|
||||||
|
try:
|
||||||
|
write(live_prom,candidate_prom.encode())
|
||||||
|
write(live_dashboard,candidate_dashboard)
|
||||||
|
subprocess.run(['docker','kill','--signal','HUP','monitoring-prometheus-1'],check=True,capture_output=True)
|
||||||
|
except Exception:
|
||||||
|
for path,content in before.items():
|
||||||
|
write(path,content)
|
||||||
|
subprocess.run(['docker','kill','--signal','HUP','monitoring-prometheus-1'],check=True,capture_output=True)
|
||||||
|
raise
|
||||||
|
report = {'applied_at':datetime.now(timezone.utc).isoformat(),'production_health':health,
|
||||||
|
'validation':validation,'prior_probes_and_panels_preserved':True,
|
||||||
|
'files':[{'path':str(p),'before_sha256':hashlib.sha256(before[p]).hexdigest(),
|
||||||
|
'after_sha256':hashlib.sha256(p.read_bytes()).hexdigest(),
|
||||||
|
'inode_preserved':p.stat().st_ino == inodes[p]} for p in before],
|
||||||
|
'backup':str(args.backup),'reload':'Prometheus SIGHUP; Grafana file provisioning',
|
||||||
|
'result':'applied; runtime probe and panel verification still required'}
|
||||||
|
(args.backup / 'applied.json').write_text(json.dumps(report,indent=2))
|
||||||
|
print(json.dumps(report,indent=2))
|
||||||
|
finally:
|
||||||
|
# docker cp creates a root-owned file; the Prometheus service runs as nobody.
|
||||||
|
subprocess.run(['docker','exec','--user','0','monitoring-prometheus-1','rm','-f',temporary],check=True,capture_output=True)
|
||||||
@@ -18,7 +18,7 @@ $sshArguments = @('-i', $IdentityFile, '-o', 'IdentitiesOnly=yes', '-o', 'BatchM
|
|||||||
& ssh @sshArguments 'docker exec -u jenkins gitea-jenkins-1 cat /var/jenkins_home/delivery-bootstrap/agent-secret' |
|
& ssh @sshArguments 'docker exec -u jenkins gitea-jenkins-1 cat /var/jenkins_home/delivery-bootstrap/agent-secret' |
|
||||||
& docker run --rm -i --network none --user 0:0 --entrypoint sh `
|
& docker run --rm -i --network none --user 0:0 --entrypoint sh `
|
||||||
--mount 'type=volume,source=ssw590-delivery-identity,target=/identity' `
|
--mount 'type=volume,source=ssw590-delivery-identity,target=/identity' `
|
||||||
ssw590-delivery-agent:20261114 -c 'set -eu; umask 077; cat > /identity/agent-secret; test -s /identity/agent-secret; chown 1000:1000 /identity /identity/agent-secret; chmod 700 /identity; chmod 400 /identity/agent-secret'
|
ssw590-delivery-agent:20261114-java21.0.13.1-2 -c 'set -eu; umask 077; cat > /identity/agent-secret; test -s /identity/agent-secret; chown 1000:1000 /identity /identity/agent-secret; chmod 700 /identity; chmod 400 /identity/agent-secret'
|
||||||
Push-Location $repoPath
|
Push-Location $repoPath
|
||||||
try {
|
try {
|
||||||
& docker compose -f delivery/agent/compose.yaml up -d
|
& docker compose -f delivery/agent/compose.yaml up -d
|
||||||
|
|||||||
@@ -10,14 +10,14 @@ DOCKER_GID=$(stat -c '%g' /var/run/docker.sock)
|
|||||||
# Numeric group only, not a credential. Keep it available for later Compose use.
|
# Numeric group only, not a credential. Keep it available for later Compose use.
|
||||||
printf 'DOCKER_GID=%s\n' "$DOCKER_GID" > .env
|
printf 'DOCKER_GID=%s\n' "$DOCKER_GID" > .env
|
||||||
chmod 644 .env
|
chmod 644 .env
|
||||||
docker image inspect ssw590-delivery-agent:20261114 >/dev/null
|
docker image inspect ssw590-delivery-agent:20261114-java21.0.13.1-2 >/dev/null
|
||||||
docker compose -f compose.droplet.yaml config --quiet
|
docker compose -f compose.droplet.yaml config --quiet
|
||||||
docker exec -u jenkins gitea-jenkins-1 test -s /var/jenkins_home/delivery-bootstrap/agent-secret
|
docker exec -u jenkins gitea-jenkins-1 test -s /var/jenkins_home/delivery-bootstrap/agent-secret
|
||||||
docker volume create ssw590-delivery-identity >/dev/null
|
docker volume create ssw590-delivery-identity >/dev/null
|
||||||
docker exec -u jenkins gitea-jenkins-1 cat /var/jenkins_home/delivery-bootstrap/agent-secret |
|
docker exec -u jenkins gitea-jenkins-1 cat /var/jenkins_home/delivery-bootstrap/agent-secret |
|
||||||
docker run --rm -i --network none --user 0:0 --entrypoint sh \
|
docker run --rm -i --network none --user 0:0 --entrypoint sh \
|
||||||
--mount type=volume,source=ssw590-delivery-identity,target=/identity \
|
--mount type=volume,source=ssw590-delivery-identity,target=/identity \
|
||||||
ssw590-delivery-agent:20261114 -c \
|
ssw590-delivery-agent:20261114-java21.0.13.1-2 -c \
|
||||||
'set -eu; umask 077; cat > /identity/agent-secret; test -s /identity/agent-secret; chown 1000:1000 /identity /identity/agent-secret; chmod 700 /identity; chmod 400 /identity/agent-secret'
|
'set -eu; umask 077; cat > /identity/agent-secret; test -s /identity/agent-secret; chown 1000:1000 /identity /identity/agent-secret; chmod 700 /identity; chmod 400 /identity/agent-secret'
|
||||||
docker compose -f compose.droplet.yaml up -d --pull never
|
docker compose -f compose.droplet.yaml up -d --pull never
|
||||||
agent=ssw590-delivery-agent-1
|
agent=ssw590-delivery-agent-1
|
||||||
|
|||||||
@@ -0,0 +1,133 @@
|
|||||||
|
{
|
||||||
|
"started": "2026-11-16T02:06:37.133690+00:00",
|
||||||
|
"image": "git.yebilly.me/ssw590-group1/pricing@sha256:63e2e3d49a5119b1064868b0b15b39a1719a60a632ff0ecdc3f676fcdc55de3b",
|
||||||
|
"existing_staging_health": {
|
||||||
|
"Status": "healthy",
|
||||||
|
"FailingStreak": 0,
|
||||||
|
"Log": [
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:05:39.379167981Z",
|
||||||
|
"End": "2026-11-16T02:05:42.481797619Z",
|
||||||
|
"ExitCode": -1,
|
||||||
|
"Output": "Health check exceeded timeout (3s)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:05:52.483085766Z",
|
||||||
|
"End": "2026-11-16T02:05:55.560331159Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:06:05.56119162Z",
|
||||||
|
"End": "2026-11-16T02:06:08.689713122Z",
|
||||||
|
"ExitCode": -1,
|
||||||
|
"Output": "Health check exceeded timeout (3s)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:06:18.690913613Z",
|
||||||
|
"End": "2026-11-16T02:06:21.782465826Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:06:31.784224739Z",
|
||||||
|
"End": "2026-11-16T02:06:34.780482181Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"existing_staging_memory_events": "low 0\nhigh 0\nmax 29\noom 0\noom_kill 0\noom_group_kill 0",
|
||||||
|
"candidate_timeout_seconds": 10,
|
||||||
|
"samples": [
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:06:42.778495877Z",
|
||||||
|
"End": "2026-11-16T02:06:48.438554619Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:06:58.439880386Z",
|
||||||
|
"End": "2026-11-16T02:07:01.623272338Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:11.624979767Z",
|
||||||
|
"End": "2026-11-16T02:07:14.734453351Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:24.735921433Z",
|
||||||
|
"End": "2026-11-16T02:07:27.640717567Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:37.641388311Z",
|
||||||
|
"End": "2026-11-16T02:07:40.639898244Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:50.64115933Z",
|
||||||
|
"End": "2026-11-16T02:07:53.824315905Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:08:03.825342377Z",
|
||||||
|
"End": "2026-11-16T02:08:07.523556252Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:08:17.525594582Z",
|
||||||
|
"End": "2026-11-16T02:08:20.342264608Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"final_health": {
|
||||||
|
"Status": "healthy",
|
||||||
|
"FailingStreak": 0,
|
||||||
|
"Log": [
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:24.735921433Z",
|
||||||
|
"End": "2026-11-16T02:07:27.640717567Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:37.641388311Z",
|
||||||
|
"End": "2026-11-16T02:07:40.639898244Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:07:50.64115933Z",
|
||||||
|
"End": "2026-11-16T02:07:53.824315905Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:08:03.825342377Z",
|
||||||
|
"End": "2026-11-16T02:08:07.523556252Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"Start": "2026-11-16T02:08:17.525594582Z",
|
||||||
|
"End": "2026-11-16T02:08:20.342264608Z",
|
||||||
|
"ExitCode": 0,
|
||||||
|
"Output": ""
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"memory_events": "low 0\nhigh 0\nmax 0\noom 0\noom_kill 0\noom_group_kill 0",
|
||||||
|
"cpu_stat": "usage_usec 8426586\nuser_usec 6475439\nsystem_usec 1951147\ncore_sched.force_idle_usec 0\nnr_periods 372\nnr_throttled 327\nthrottled_usec 23409965\nnr_bursts 0\nburst_usec 0",
|
||||||
|
"passed": true,
|
||||||
|
"completed": "2026-11-16T02:08:24.345181+00:00",
|
||||||
|
"temporary_container_removed": true
|
||||||
|
}
|
||||||
@@ -0,0 +1,51 @@
|
|||||||
|
"""Administrator-only diagnostic; never deploys a pricing environment."""
|
||||||
|
import json
|
||||||
|
import subprocess
|
||||||
|
import time
|
||||||
|
from datetime import datetime, timezone
|
||||||
|
|
||||||
|
IMAGE = 'git.yebilly.me/ssw590-group1/pricing@sha256:63e2e3d49a5119b1064868b0b15b39a1719a60a632ff0ecdc3f676fcdc55de3b'
|
||||||
|
NAME = 'ssw590-pricing-health-trial'
|
||||||
|
|
||||||
|
def command(*args):
|
||||||
|
return subprocess.check_output(args, text=True).strip()
|
||||||
|
|
||||||
|
def health(container):
|
||||||
|
return json.loads(command('docker', 'inspect', '--format', '{{json .State.Health}}', container))
|
||||||
|
|
||||||
|
def now():
|
||||||
|
return datetime.now(timezone.utc).isoformat()
|
||||||
|
|
||||||
|
existing = subprocess.run(['docker','container','inspect',NAME],capture_output=True)
|
||||||
|
assert existing.returncode != 0, 'Existing diagnostic container must be reviewed'
|
||||||
|
report = {'started':now(), 'image':IMAGE, 'existing_staging_health':health('pricing-staging-app-1'),
|
||||||
|
'existing_staging_memory_events':command('docker','exec','pricing-staging-app-1','cat','/sys/fs/cgroup/memory.events'),
|
||||||
|
'candidate_timeout_seconds':10, 'samples':[]}
|
||||||
|
container = command('docker','run','-d','--pull','never','--name',NAME,
|
||||||
|
'--network','none','--read-only','--tmpfs','/tmp:size=16m,mode=1777',
|
||||||
|
'--cap-drop','ALL','--security-opt','no-new-privileges:true','--user','10001:10001',
|
||||||
|
'--memory','64m','--memory-swap','96m','--cpus','0.25','--pids-limit','64',
|
||||||
|
'--health-timeout','10s',IMAGE)
|
||||||
|
assert len(container) == 64 and all(c in '0123456789abcdef' for c in container)
|
||||||
|
seen = set()
|
||||||
|
try:
|
||||||
|
deadline = time.monotonic() + 170
|
||||||
|
while time.monotonic() < deadline:
|
||||||
|
state = health(container)
|
||||||
|
for sample in state.get('Log',[]):
|
||||||
|
if sample['Start'] not in seen:
|
||||||
|
seen.add(sample['Start'])
|
||||||
|
report['samples'].append(sample)
|
||||||
|
if len(report['samples']) >= 8:
|
||||||
|
break
|
||||||
|
time.sleep(5)
|
||||||
|
report['final_health'] = health(container)
|
||||||
|
report['memory_events'] = command('docker','exec',container,'cat','/sys/fs/cgroup/memory.events')
|
||||||
|
report['cpu_stat'] = command('docker','exec',container,'cat','/sys/fs/cgroup/cpu.stat')
|
||||||
|
report['passed'] = len(report['samples']) >= 8 and all(s['ExitCode'] == 0 for s in report['samples']) and report['final_health']['Status'] == 'healthy'
|
||||||
|
finally:
|
||||||
|
subprocess.run(['docker','rm','-f',container],check=True,capture_output=True)
|
||||||
|
report['completed'] = now()
|
||||||
|
report['temporary_container_removed'] = True
|
||||||
|
print(json.dumps(report,indent=2))
|
||||||
|
assert report['passed'], 'Health trial did not pass'
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
{
|
||||||
|
"applied_at": "2026-11-16T03:08:11.087796+00:00",
|
||||||
|
"production_health": {
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v1"
|
||||||
|
},
|
||||||
|
"validation": "Checking /tmp/ssw590-production-probe-20261116T030810544427Z.yml\n SUCCESS: /tmp/ssw590-production-probe-20261116T030810544427Z.yml is valid prometheus config file syntax\n\n",
|
||||||
|
"prior_probes_and_panels_preserved": true,
|
||||||
|
"files": [
|
||||||
|
{
|
||||||
|
"path": "/root/monitoring/prometheus/prometheus.yml",
|
||||||
|
"before_sha256": "fe1d0f479d947e20ea7ebfec164689fe69ea9539ba0289adc2b7d26b8ffe62d6",
|
||||||
|
"after_sha256": "e35bc7fb3d09f7b3442324a2af147d8f1319ae1f0631ba81ed7577bb63826edd",
|
||||||
|
"inode_preserved": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/root/monitoring/grafana/dashboards/sre.json",
|
||||||
|
"before_sha256": "c21fadca47ee624001133a82b788e728d08168664302666ed103113f3bec5f13",
|
||||||
|
"after_sha256": "08f99b845e5d56b81f54bf1b386aa50a54a88296ce5caf9496c5bfbf62929ed1",
|
||||||
|
"inode_preserved": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"backup": "/root/ssw590-delivery-bootstrap/monitoring-20261116",
|
||||||
|
"reload": "Prometheus SIGHUP; Grafana file provisioning",
|
||||||
|
"result": "applied; runtime probe and panel verification still required"
|
||||||
|
}
|
||||||
@@ -0,0 +1,218 @@
|
|||||||
|
{
|
||||||
|
"observed_at": "2026-11-16T03:14:11.206493+00:00",
|
||||||
|
"queries": {
|
||||||
|
"probe_success{job=\"https\"}": [
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "probe_success",
|
||||||
|
"instance": "https://ci.yebilly.me/login",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.242,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "probe_success",
|
||||||
|
"instance": "https://git.yebilly.me/user/login",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.242,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "probe_success",
|
||||||
|
"instance": "https://app.yebilly.me/health",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.242,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"prometheus_config_last_reload_successful": [
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "prometheus_config_last_reload_successful",
|
||||||
|
"instance": "prometheus:9090",
|
||||||
|
"job": "prometheus"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.244,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"up": [
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "up",
|
||||||
|
"instance": "blackbox-exporter:9115",
|
||||||
|
"job": "blackbox"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.245,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "up",
|
||||||
|
"instance": "prometheus:9090",
|
||||||
|
"job": "prometheus"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.245,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "up",
|
||||||
|
"instance": "https://ci.yebilly.me/login",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.245,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "up",
|
||||||
|
"instance": "https://git.yebilly.me/user/login",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.245,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "up",
|
||||||
|
"instance": "node-exporter:9100",
|
||||||
|
"job": "node"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.245,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "up",
|
||||||
|
"instance": "https://app.yebilly.me/health",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"value": [
|
||||||
|
1794798851.245,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"targets": [
|
||||||
|
{
|
||||||
|
"labels": {
|
||||||
|
"instance": "blackbox-exporter:9115",
|
||||||
|
"job": "blackbox"
|
||||||
|
},
|
||||||
|
"health": "up",
|
||||||
|
"lastError": "",
|
||||||
|
"lastScrape": "2026-11-16T03:13:46.738098436Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"labels": {
|
||||||
|
"instance": "https://git.yebilly.me/user/login",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"health": "up",
|
||||||
|
"lastError": "",
|
||||||
|
"lastScrape": "2026-11-16T03:14:02.878212313Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"labels": {
|
||||||
|
"instance": "https://ci.yebilly.me/login",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"health": "up",
|
||||||
|
"lastError": "",
|
||||||
|
"lastScrape": "2026-11-16T03:13:50.769303819Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"labels": {
|
||||||
|
"instance": "https://app.yebilly.me/health",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"health": "up",
|
||||||
|
"lastError": "",
|
||||||
|
"lastScrape": "2026-11-16T03:13:54.602557327Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"labels": {
|
||||||
|
"instance": "node-exporter:9100",
|
||||||
|
"job": "node"
|
||||||
|
},
|
||||||
|
"health": "up",
|
||||||
|
"lastError": "",
|
||||||
|
"lastScrape": "2026-11-16T03:14:06.522911829Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"labels": {
|
||||||
|
"instance": "prometheus:9090",
|
||||||
|
"job": "prometheus"
|
||||||
|
},
|
||||||
|
"health": "up",
|
||||||
|
"lastError": "",
|
||||||
|
"lastScrape": "2026-11-16T03:13:47.742950331Z"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"dashboard_provisioning_source": {
|
||||||
|
"uid": "group1-sre",
|
||||||
|
"title": "Group 1 SRE",
|
||||||
|
"panels": [
|
||||||
|
{
|
||||||
|
"id": 1,
|
||||||
|
"title": "Droplet CPU utilization (%)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 2,
|
||||||
|
"title": "Available memory (bytes)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 3,
|
||||||
|
"title": "Root filesystem available (%)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 4,
|
||||||
|
"title": "Gitea HTTPS availability (probe_success)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 5,
|
||||||
|
"title": "Jenkins HTTPS availability (probe_success)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 6,
|
||||||
|
"title": "HTTPS probe duration (s)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 7,
|
||||||
|
"title": "Scrape health (up)"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 8,
|
||||||
|
"title": "Pricing production HTTPS availability (probe_success)"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"production_probe_up": true,
|
||||||
|
"pricing_panel_configured": true,
|
||||||
|
"runtime_panel_verification": "Separate Grafana UI verification required"
|
||||||
|
}
|
||||||
@@ -0,0 +1,615 @@
|
|||||||
|
{
|
||||||
|
"review": {
|
||||||
|
"pr": 27,
|
||||||
|
"url": "https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/27",
|
||||||
|
"reviewer": "bill",
|
||||||
|
"approved_utc": "2026-11-16T04:12:09Z",
|
||||||
|
"merged_by": "vsun1",
|
||||||
|
"merged_utc": "2026-11-16T04:14:30Z",
|
||||||
|
"main_commit": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"manual_workflow": 16,
|
||||||
|
"manual_result": "SUCCESS",
|
||||||
|
"manual_elapsed_seconds": 137
|
||||||
|
},
|
||||||
|
"staging_fault_commit": "1e23001e7303d14630cfa97c8de36f31f30b81a0",
|
||||||
|
"staging_revert_commit": "29e580c4613f00a02f44bce0dbcee2fd8fdc83ae",
|
||||||
|
"tracking_issue": {
|
||||||
|
"number": 28,
|
||||||
|
"url": "https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/issues/28",
|
||||||
|
"created_utc": "2026-11-16T04:33:40Z",
|
||||||
|
"timing": "Created with Vincent authorization during finalization, after implementation and exercises"
|
||||||
|
},
|
||||||
|
"decisions": {
|
||||||
|
"production": {
|
||||||
|
"decision_utc": "2026-11-16T04:17:46.307026+00:00",
|
||||||
|
"environment": "production",
|
||||||
|
"reason": "Planned healthy v2-to-v1 production rollback exercise; no incident claimed",
|
||||||
|
"reviewed_main": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"before": {
|
||||||
|
"/health": {
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"/": {
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"service": "Startup Pricing",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"/price?quantity=3": {
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"currency": "USD",
|
||||||
|
"quantity": 3,
|
||||||
|
"total": 36
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"observer_seconds": 1800,
|
||||||
|
"observer_interval_seconds": 1,
|
||||||
|
"observer_pid": 99107
|
||||||
|
},
|
||||||
|
"staging": {
|
||||||
|
"decision_utc": "2026-11-16T04:25:23.939561+00:00",
|
||||||
|
"environment": "staging",
|
||||||
|
"reason": "Planned isolated staging bind mismatch and recovery exercise",
|
||||||
|
"reviewed_main": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"before": {
|
||||||
|
"/health": {
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"/": {
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"service": "Startup Pricing",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"/price?quantity=3": {
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"currency": "USD",
|
||||||
|
"quantity": 3,
|
||||||
|
"total": 36
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"observer_seconds": 1800,
|
||||||
|
"observer_interval_seconds": 1,
|
||||||
|
"observer_pid": 105221
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"builds": [
|
||||||
|
{
|
||||||
|
"result": "FAILURE",
|
||||||
|
"duration": "17784",
|
||||||
|
"startTime": "1794802675044",
|
||||||
|
"timestamp": "1794802675036",
|
||||||
|
"number": 7,
|
||||||
|
"parameters": {
|
||||||
|
"MODE": "rollback-production",
|
||||||
|
"SOURCE_COMMIT": "",
|
||||||
|
"RELEASE_RECORD": "delivery/releases/v1-production.json",
|
||||||
|
"STAGING_FAILURE_CONFIG": ""
|
||||||
|
},
|
||||||
|
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/7/",
|
||||||
|
"started_utc": "2026-11-16T04:17:55.044000+00:00",
|
||||||
|
"completed_utc": "2026-11-16T04:18:12.828000+00:00",
|
||||||
|
"elapsed_seconds": 17.784,
|
||||||
|
"control_commit": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"report_sha256": {
|
||||||
|
"reports\\source-commit.txt": "d32fa240635dc770690e10403280212691e8fff9e8e9479ed2d5382c7fa47b63"
|
||||||
|
},
|
||||||
|
"console_sha256": "ffb0fdf1e6a4da50eed4f10535208b6646985da94a565d543f29615b2980281b",
|
||||||
|
"deployments": {},
|
||||||
|
"runner_incident": {
|
||||||
|
"failure": "Cannot fork during test-app.sh before deployment",
|
||||||
|
"observations": "Before restart, cgroup pids.current=115/128 and pids.events max=2; Docker stats PIDS=114, memory=132.6 MiB/512 MiB; no OOM kill. Process listing showed Java only; no accumulation mechanism was established.",
|
||||||
|
"action": "Restarted only the idle existing delivery-agent container, preserving image, identity/workspace and resource/security limits. Immediate Docker stats PIDS=13. Retried as build 8.",
|
||||||
|
"limits_changed": false,
|
||||||
|
"root_cause": "Process-limit pressure observed; underlying accumulation mechanism not proven"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"result": "SUCCESS",
|
||||||
|
"duration": "163654",
|
||||||
|
"startTime": "1794802924875",
|
||||||
|
"timestamp": "1794802924865",
|
||||||
|
"number": 8,
|
||||||
|
"parameters": {
|
||||||
|
"MODE": "rollback-production",
|
||||||
|
"SOURCE_COMMIT": "",
|
||||||
|
"RELEASE_RECORD": "delivery/releases/v1-production.json",
|
||||||
|
"STAGING_FAILURE_CONFIG": ""
|
||||||
|
},
|
||||||
|
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/8/",
|
||||||
|
"started_utc": "2026-11-16T04:22:04.875000+00:00",
|
||||||
|
"completed_utc": "2026-11-16T04:24:48.529000+00:00",
|
||||||
|
"elapsed_seconds": 163.654,
|
||||||
|
"control_commit": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"report_sha256": {
|
||||||
|
"reports\\ansible-production-deploy.json": "201c1a045f5fdcbcb2254a501c74a0a560dbcf091e3aadf825be59db804aea11",
|
||||||
|
"reports\\ansible-production-deploy.txt": "ba845712187efc5fd4b6d3b757d1ea643aa399b377b3c2382e83d632171e7550",
|
||||||
|
"reports\\dependencies.json": "efe1d4f130ea70d6fcf733a3051d05c03cd0b1e0ab25e471ac6dc62924136ff5",
|
||||||
|
"reports\\dependencies.log": "79d30422388543b2563e1dde76bb7e7857d7ef0c6fdf05c8c71598633ca07e1e",
|
||||||
|
"reports\\pip-audit-version.log": "70d9a63a0ea389b4992009be156f8738d7c22f2f5c049084054528ed7f9eee0c",
|
||||||
|
"reports\\production-approval.txt": "6566df927fb18e6e297634d4dd522cf4c759c4fc008c6176d942672d5792cf95",
|
||||||
|
"reports\\source-commit.txt": "d32fa240635dc770690e10403280212691e8fff9e8e9479ed2d5382c7fa47b63",
|
||||||
|
"reports\\source-execution.json": "ba5b68047d9dac04089b31fb29fb40a3cb51b992c02f974444d300d504d0f5e1",
|
||||||
|
"reports\\source-secrets.json": "72bd267761ba93c546536807f9b7e790797c38742cb36370d9679d6dcb1441b5",
|
||||||
|
"reports\\source-secrets.log": "5a9fe951960c7abd0708e7155c0ab4729ef8f2d3edf84da7d35c8086f8dbee01",
|
||||||
|
"reports\\trivy-version.log": "fdfa3e3b4b56139b5fe7bbecf4fe9a542298ee21bfd83d1f5e79b78f67b44c68",
|
||||||
|
"reports\\unit-tests.json": "4e85118262b6728c253125415a37ddf3a3457abeda987bf1bcdb321cf3c57e8e",
|
||||||
|
"reports\\unit-tests.txt": "1d86b5cda3b26f9b3b40dad45794b90949d1b1bbd12ee7520977e3654913566f"
|
||||||
|
},
|
||||||
|
"console_sha256": "98dde3f24af6fd114f092be6f23d288f9f61ce33bf73c51ba07935d8addba243",
|
||||||
|
"deployments": {
|
||||||
|
"ansible-production-deploy": {
|
||||||
|
"started": "2026-11-16T04:23:42.801152+00:00",
|
||||||
|
"completed": "2026-11-16T04:24:46.705083+00:00",
|
||||||
|
"elapsed_seconds": 63.904,
|
||||||
|
"operation": "deploy",
|
||||||
|
"release": {
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||||
|
"expected_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"expected_version": "v1",
|
||||||
|
"expected_total": 30,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||||
|
"created_at": "2026-11-16T03:01:23.246375+00:00",
|
||||||
|
"target_env": "production",
|
||||||
|
"public_url": "https://app.yebilly.me"
|
||||||
|
},
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 3,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"gates": {
|
||||||
|
"control_tests": 12,
|
||||||
|
"app_tests": 3,
|
||||||
|
"source_secrets": 0,
|
||||||
|
"audited_dependencies": 9,
|
||||||
|
"dependency_advisories": 0,
|
||||||
|
"source_gate": "passed",
|
||||||
|
"image_build_publish": "skipped: exact previously scanned release digest reused"
|
||||||
|
},
|
||||||
|
"approval": {
|
||||||
|
"Approver": "vsun1",
|
||||||
|
"Decision": "approved",
|
||||||
|
"UTC": "2026-11-16T04:23:36Z"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"result": "FAILURE",
|
||||||
|
"duration": "128235",
|
||||||
|
"startTime": "1794803149011",
|
||||||
|
"timestamp": "1794803149001",
|
||||||
|
"number": 9,
|
||||||
|
"parameters": {
|
||||||
|
"MODE": "staging-failure",
|
||||||
|
"SOURCE_COMMIT": "",
|
||||||
|
"RELEASE_RECORD": "delivery/releases/v2-staging.json",
|
||||||
|
"STAGING_FAILURE_CONFIG": "1e23001e7303d14630cfa97c8de36f31f30b81a0"
|
||||||
|
},
|
||||||
|
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/9/",
|
||||||
|
"started_utc": "2026-11-16T04:25:49.011000+00:00",
|
||||||
|
"completed_utc": "2026-11-16T04:27:57.246000+00:00",
|
||||||
|
"elapsed_seconds": 128.235,
|
||||||
|
"control_commit": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"report_sha256": {
|
||||||
|
"reports\\ansible-staging-deploy.json": "a3e6f2ec37c87c8989ff86d76a0d7adde4269b1ca4711252a87493b7f130eca6",
|
||||||
|
"reports\\ansible-staging-deploy.txt": "81224e3fe7b3e2fd873fb4efccd4fcf539cefd7b5c22e2f62a380fadaf07acf5",
|
||||||
|
"reports\\dependencies.json": "efe1d4f130ea70d6fcf733a3051d05c03cd0b1e0ab25e471ac6dc62924136ff5",
|
||||||
|
"reports\\dependencies.log": "79d30422388543b2563e1dde76bb7e7857d7ef0c6fdf05c8c71598633ca07e1e",
|
||||||
|
"reports\\pip-audit-version.log": "70d9a63a0ea389b4992009be156f8738d7c22f2f5c049084054528ed7f9eee0c",
|
||||||
|
"reports\\source-commit.txt": "d32fa240635dc770690e10403280212691e8fff9e8e9479ed2d5382c7fa47b63",
|
||||||
|
"reports\\source-execution.json": "9412c68aff2731f64d7ec8f0a5b385f06ff0cdd00695e95637bea641c27954b3",
|
||||||
|
"reports\\source-secrets.json": "1c19587e36004d75715c36a1de0a1de995206810b4cdcc4191913cf1dddc8870",
|
||||||
|
"reports\\source-secrets.log": "304aacf31aa559e3ebc960cdbfaacdc5acd332b02ef549767c807ad881e83d00",
|
||||||
|
"reports\\trivy-version.log": "fdfa3e3b4b56139b5fe7bbecf4fe9a542298ee21bfd83d1f5e79b78f67b44c68",
|
||||||
|
"reports\\unit-tests.json": "348cec2062b44e325a1ce6c8ba9f58b5138f0cdba1b99a20ffbff4b0597c12fe",
|
||||||
|
"reports\\unit-tests.txt": "00f03324a514a809d96c5ff8c178bf619ba0c860c2b2eacf81be492ace71cf2b"
|
||||||
|
},
|
||||||
|
"console_sha256": "d5a3b8260c102a179b7749f1e247299e42a629b09e313ba0796b42e8c8ab8e0c",
|
||||||
|
"deployments": {
|
||||||
|
"ansible-staging-deploy": {
|
||||||
|
"started": "2026-11-16T04:26:25.353545+00:00",
|
||||||
|
"completed": "2026-11-16T04:27:52.043305+00:00",
|
||||||
|
"elapsed_seconds": 86.69,
|
||||||
|
"operation": "deploy",
|
||||||
|
"release": {
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"configuration_commit": "1e23001e7303d14630cfa97c8de36f31f30b81a0",
|
||||||
|
"expected_version": "v2",
|
||||||
|
"expected_total": 36,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||||
|
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||||
|
"target_env": "staging",
|
||||||
|
"public_url": "https://staging.yebilly.me"
|
||||||
|
},
|
||||||
|
"ansible_exit_code": 2,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 4,
|
||||||
|
"changed": 1,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 1
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "blocked"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"gates": {
|
||||||
|
"control_tests": 12,
|
||||||
|
"app_tests": 3,
|
||||||
|
"source_secrets": 0,
|
||||||
|
"audited_dependencies": 9,
|
||||||
|
"dependency_advisories": 0,
|
||||||
|
"source_gate": "passed",
|
||||||
|
"image_build_publish": "skipped: exact previously scanned release digest reused"
|
||||||
|
},
|
||||||
|
"blocked_before_production": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"result": "SUCCESS",
|
||||||
|
"duration": "141672",
|
||||||
|
"startTime": "1794803318093",
|
||||||
|
"timestamp": "1794803318085",
|
||||||
|
"number": 10,
|
||||||
|
"parameters": {
|
||||||
|
"MODE": "recover-staging",
|
||||||
|
"SOURCE_COMMIT": "",
|
||||||
|
"RELEASE_RECORD": "delivery/releases/v2-staging.json",
|
||||||
|
"STAGING_FAILURE_CONFIG": ""
|
||||||
|
},
|
||||||
|
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/10/",
|
||||||
|
"started_utc": "2026-11-16T04:28:38.093000+00:00",
|
||||||
|
"completed_utc": "2026-11-16T04:30:59.765000+00:00",
|
||||||
|
"elapsed_seconds": 141.672,
|
||||||
|
"control_commit": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"report_sha256": {
|
||||||
|
"reports\\ansible-staging-deploy.json": "ed55e946f9e8bb13225ce0a8811024d540f9fe4294323d2ee455f3acf2845657",
|
||||||
|
"reports\\ansible-staging-deploy.txt": "07f0481909dfde24de95ac0a1db610a094d9fffa936c3cff689fcd6c821d63fb",
|
||||||
|
"reports\\ansible-staging-rerun.json": "26305363b025835bd3153520e70079f61a91dd23baa4e36f7222afe8f74c412d",
|
||||||
|
"reports\\ansible-staging-rerun.txt": "911564f4c8bf57d9520a443034e0bc9de4abf7726ca0b8c2b3afa97943b4a91d",
|
||||||
|
"reports\\dependencies.json": "efe1d4f130ea70d6fcf733a3051d05c03cd0b1e0ab25e471ac6dc62924136ff5",
|
||||||
|
"reports\\dependencies.log": "79d30422388543b2563e1dde76bb7e7857d7ef0c6fdf05c8c71598633ca07e1e",
|
||||||
|
"reports\\pip-audit-version.log": "70d9a63a0ea389b4992009be156f8738d7c22f2f5c049084054528ed7f9eee0c",
|
||||||
|
"reports\\source-commit.txt": "d32fa240635dc770690e10403280212691e8fff9e8e9479ed2d5382c7fa47b63",
|
||||||
|
"reports\\source-execution.json": "d78b9b30bba14b4f3323fb092a153056b813a06a6a8d1ebab4adfdecaeded57d",
|
||||||
|
"reports\\source-secrets.json": "520f12af3fd8864aeb7b559e0f9c0259af1e4a82b5d2d80bcd863d80fc59c110",
|
||||||
|
"reports\\source-secrets.log": "4a69a54407e808d23fc6ae73f37542f1e959f9556673109c59bcc7c2b968f1a9",
|
||||||
|
"reports\\trivy-version.log": "fdfa3e3b4b56139b5fe7bbecf4fe9a542298ee21bfd83d1f5e79b78f67b44c68",
|
||||||
|
"reports\\unit-tests.json": "98a1ea888dffc5ca4bf86099df73b5f5381f5f152e749c69ab0354e8c08d5835",
|
||||||
|
"reports\\unit-tests.txt": "5b85444f8bb9c230b2cdaad8cc115d29731678013be9758c1a8b3aa48796bf05"
|
||||||
|
},
|
||||||
|
"console_sha256": "ae14281ab7598b35d44ee27fa223a6d2db95109506befefa400d5266e582f7ec",
|
||||||
|
"deployments": {
|
||||||
|
"ansible-staging-deploy": {
|
||||||
|
"started": "2026-11-16T04:29:10.105956+00:00",
|
||||||
|
"completed": "2026-11-16T04:30:06.602542+00:00",
|
||||||
|
"elapsed_seconds": 56.497,
|
||||||
|
"operation": "deploy",
|
||||||
|
"release": {
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"expected_version": "v2",
|
||||||
|
"expected_total": 36,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||||
|
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||||
|
"target_env": "staging",
|
||||||
|
"public_url": "https://staging.yebilly.me"
|
||||||
|
},
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 2,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"ansible-staging-rerun": {
|
||||||
|
"started": "2026-11-16T04:30:10.351831+00:00",
|
||||||
|
"completed": "2026-11-16T04:30:58.450829+00:00",
|
||||||
|
"elapsed_seconds": 48.099,
|
||||||
|
"operation": "rerun",
|
||||||
|
"release": {
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"expected_version": "v2",
|
||||||
|
"expected_total": 36,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||||
|
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||||
|
"target_env": "staging",
|
||||||
|
"public_url": "https://staging.yebilly.me"
|
||||||
|
},
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 0,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"gates": {
|
||||||
|
"control_tests": 12,
|
||||||
|
"app_tests": 3,
|
||||||
|
"source_secrets": 0,
|
||||||
|
"audited_dependencies": 9,
|
||||||
|
"dependency_advisories": 0,
|
||||||
|
"source_gate": "passed",
|
||||||
|
"image_build_publish": "skipped: exact previously scanned release digest reused"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"observer_analysis": {
|
||||||
|
"production": {
|
||||||
|
"samples": 863,
|
||||||
|
"failed_samples": 9,
|
||||||
|
"first": {
|
||||||
|
"started_utc": "2026-11-16T04:17:46.446751+00:00",
|
||||||
|
"elapsed_seconds": "0.053",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:17:46.499751+00:00"
|
||||||
|
},
|
||||||
|
"last": {
|
||||||
|
"started_utc": "2026-11-16T04:32:10.607054+00:00",
|
||||||
|
"elapsed_seconds": "0.018",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v1",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:32:10.625054+00:00"
|
||||||
|
},
|
||||||
|
"first_seen_versions": {
|
||||||
|
"v2": {
|
||||||
|
"started_utc": "2026-11-16T04:17:46.446751+00:00",
|
||||||
|
"elapsed_seconds": "0.053",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:17:46.499751+00:00"
|
||||||
|
},
|
||||||
|
"v1": {
|
||||||
|
"started_utc": "2026-11-16T04:24:23.645071+00:00",
|
||||||
|
"elapsed_seconds": "1.668",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v1",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:24:25.313071+00:00"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"failure_clusters": [
|
||||||
|
{
|
||||||
|
"count": 9,
|
||||||
|
"first_failed": {
|
||||||
|
"started_utc": "2026-11-16T04:24:13.628753+00:00",
|
||||||
|
"elapsed_seconds": "0.034",
|
||||||
|
"http_status": "502",
|
||||||
|
"status": "",
|
||||||
|
"version": "",
|
||||||
|
"error": "HTTPError",
|
||||||
|
"completed_utc": "2026-11-16T04:24:13.662753+00:00"
|
||||||
|
},
|
||||||
|
"last_failed": {
|
||||||
|
"started_utc": "2026-11-16T04:24:21.630135+00:00",
|
||||||
|
"elapsed_seconds": "2.015",
|
||||||
|
"http_status": "",
|
||||||
|
"status": "",
|
||||||
|
"version": "",
|
||||||
|
"error": "TimeoutError",
|
||||||
|
"completed_utc": "2026-11-16T04:24:23.645135+00:00"
|
||||||
|
},
|
||||||
|
"preceding_success": {
|
||||||
|
"started_utc": "2026-11-16T04:24:12.628587+00:00",
|
||||||
|
"elapsed_seconds": "0.043",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:24:12.671587+00:00"
|
||||||
|
},
|
||||||
|
"following_success": {
|
||||||
|
"started_utc": "2026-11-16T04:24:23.645071+00:00",
|
||||||
|
"elapsed_seconds": "1.668",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v1",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:24:25.313071+00:00"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"maximum_start_gap_seconds": 2.014936,
|
||||||
|
"csv_file": "recovery-production-20261115.csv",
|
||||||
|
"csv_sha256": "6dbc670bd7bf32d7ee8e8c784f3af5135dc444503ae0418a4efad9075caa93b2",
|
||||||
|
"failed_http_statuses": {
|
||||||
|
"": 1,
|
||||||
|
"502": 8
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"staging": {
|
||||||
|
"samples": 406,
|
||||||
|
"failed_samples": 169,
|
||||||
|
"first": {
|
||||||
|
"started_utc": "2026-11-16T04:25:24.077935+00:00",
|
||||||
|
"elapsed_seconds": "0.07",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:25:24.147935+00:00"
|
||||||
|
},
|
||||||
|
"last": {
|
||||||
|
"started_utc": "2026-11-16T04:32:11.031289+00:00",
|
||||||
|
"elapsed_seconds": "0.017",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:32:11.048289+00:00"
|
||||||
|
},
|
||||||
|
"first_seen_versions": {
|
||||||
|
"v2": {
|
||||||
|
"started_utc": "2026-11-16T04:25:24.077935+00:00",
|
||||||
|
"elapsed_seconds": "0.07",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:25:24.147935+00:00"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"failure_clusters": [
|
||||||
|
{
|
||||||
|
"count": 169,
|
||||||
|
"first_failed": {
|
||||||
|
"started_utc": "2026-11-16T04:26:53.130293+00:00",
|
||||||
|
"elapsed_seconds": "0.03",
|
||||||
|
"http_status": "502",
|
||||||
|
"status": "",
|
||||||
|
"version": "",
|
||||||
|
"error": "HTTPError",
|
||||||
|
"completed_utc": "2026-11-16T04:26:53.160293+00:00"
|
||||||
|
},
|
||||||
|
"last_failed": {
|
||||||
|
"started_utc": "2026-11-16T04:29:41.187224+00:00",
|
||||||
|
"elapsed_seconds": "2.018",
|
||||||
|
"http_status": "",
|
||||||
|
"status": "",
|
||||||
|
"version": "",
|
||||||
|
"error": "TimeoutError",
|
||||||
|
"completed_utc": "2026-11-16T04:29:43.205224+00:00"
|
||||||
|
},
|
||||||
|
"preceding_success": {
|
||||||
|
"started_utc": "2026-11-16T04:26:52.130143+00:00",
|
||||||
|
"elapsed_seconds": "0.143",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:26:52.273143+00:00"
|
||||||
|
},
|
||||||
|
"following_success": {
|
||||||
|
"started_utc": "2026-11-16T04:29:43.205246+00:00",
|
||||||
|
"elapsed_seconds": "1.718",
|
||||||
|
"http_status": "200",
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2",
|
||||||
|
"error": "",
|
||||||
|
"completed_utc": "2026-11-16T04:29:44.923246+00:00"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"maximum_start_gap_seconds": 2.018022,
|
||||||
|
"csv_file": "recovery-staging-20261115.csv",
|
||||||
|
"csv_sha256": "9519837bd6a3e8b40985dba5a933119d76fcae03c9fc78bec26f1cf84c00c209",
|
||||||
|
"failed_http_statuses": {
|
||||||
|
"": 1,
|
||||||
|
"502": 168
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"observation_end": {
|
||||||
|
"finished_at": "2026-11-16T04:32:10.987203+00:00",
|
||||||
|
"reason": "Both recovery exercises and unchanged rerun completed; end bounded observation after post-recovery samples",
|
||||||
|
"observers": {
|
||||||
|
"production": {
|
||||||
|
"pid": 99107,
|
||||||
|
"sent_sigterm_to_verified_process": true,
|
||||||
|
"planned_max_seconds": 1800,
|
||||||
|
"actual_first_sample": "2026-11-16T04:17:46.446751+00:00",
|
||||||
|
"actual_last_sample": "2026-11-16T04:32:10.607054+00:00",
|
||||||
|
"samples": 863,
|
||||||
|
"normalized_text_sha256_at_stop": "c7d70f56283eac8f031e61fc41ef2e8a7d34e123d1fd12936dab0e00c9addb39",
|
||||||
|
"hash_note": "Stop helper hashed read_text-normalized LF text; original captured CSV bytes are independently verified below."
|
||||||
|
},
|
||||||
|
"staging": {
|
||||||
|
"pid": 105221,
|
||||||
|
"sent_sigterm_to_verified_process": true,
|
||||||
|
"planned_max_seconds": 1800,
|
||||||
|
"actual_first_sample": "2026-11-16T04:25:24.077935+00:00",
|
||||||
|
"actual_last_sample": "2026-11-16T04:32:11.031289+00:00",
|
||||||
|
"samples": 406,
|
||||||
|
"normalized_text_sha256_at_stop": "02942e3f179efb5f303abe4f071de7296fbca042591379e424aa7d8d1298b8c1",
|
||||||
|
"hash_note": "Stop helper hashed read_text-normalized LF text; original captured CSV bytes are independently verified below."
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"original_csv_hashes": {
|
||||||
|
"production": {
|
||||||
|
"sha256": "6dbc670bd7bf32d7ee8e8c784f3af5135dc444503ae0418a4efad9075caa93b2"
|
||||||
|
},
|
||||||
|
"staging": {
|
||||||
|
"sha256": "9519837bd6a3e8b40985dba5a933119d76fcae03c9fc78bec26f1cf84c00c209"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"monitoring_correlation": {
|
||||||
|
"production_probe_samples_since_decision": 34,
|
||||||
|
"failed_samples_since_decision": 0,
|
||||||
|
"cadence_seconds": 30,
|
||||||
|
"observer_failed_production_samples": 9,
|
||||||
|
"explanation": "Prometheus missed the short rollback interruption captured by the finer observer. The staging exercise is not a production-probe outage.",
|
||||||
|
"alert_samples_returned_in_90m_query": 0,
|
||||||
|
"notification_claim": "No notification claim; notification history was not collected"
|
||||||
|
},
|
||||||
|
"final_verified_at": "2026-11-16T04:34:28.764638+00:00",
|
||||||
|
"final_state": {
|
||||||
|
"production": {
|
||||||
|
"version": "v1",
|
||||||
|
"source": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"digest": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||||
|
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"total": 30
|
||||||
|
},
|
||||||
|
"staging": {
|
||||||
|
"version": "v2",
|
||||||
|
"source": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"digest": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"total": 36
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"runtime_sha256": "aba434191cd79cdb1a3a1cfdc1b46264a8b3fb1dfdbac059b8f66819fa23b1b9"
|
||||||
|
}
|
||||||
@@ -0,0 +1,137 @@
|
|||||||
|
# Completed production rollback and staging recovery
|
||||||
|
|
||||||
|
Executed 15 November 2026 Eastern / 16 November UTC. All times below are UTC.
|
||||||
|
Primary data: [results and report hashes](recovery-20261115.json),
|
||||||
|
[actual runtime and Prometheus responses](recovery-runtime-20261115.json),
|
||||||
|
[original production CSV](recovery-production-20261115.csv), and
|
||||||
|
[original staging CSV](recovery-staging-20261115.csv). CSV bytes and SHA-256
|
||||||
|
values were verified against the remote originals.
|
||||||
|
|
||||||
|
## Review and baseline
|
||||||
|
|
||||||
|
[PR 27](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/27) was approved
|
||||||
|
by `bill` at 04:12:09 and merged by `vsun1` at 04:14:30 as
|
||||||
|
`72bf10dcecc8db65dce4750c05bf841bea9b0834`. It preserves the actual successful
|
||||||
|
release records, bad configuration `1e23001e7303d14630cfa97c8de36f31f30b81a0`
|
||||||
|
and immediate revert `29e580c4613f00a02f44bce0dbcee2fd8fdc83ae`. Main is good.
|
||||||
|
[Actions workflow 16](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/actions/runs/16)
|
||||||
|
passed in 2m17s before recovery. Jobs 7–10 used reviewed main `72bf10d` for
|
||||||
|
control code; their release records select historical app/configuration commits.
|
||||||
|
|
||||||
|
## Healthy production rollback
|
||||||
|
|
||||||
|
This was a planned exercise on healthy v2, not an incident. Decision:
|
||||||
|
04:17:46.307. The reviewed HTTPS observer started before approval. The original
|
||||||
|
v1 production record selects source/configuration
|
||||||
|
`34f26e6948b7001ede8ca19f23b67a02082e6a9a` and image:
|
||||||
|
|
||||||
|
```text
|
||||||
|
git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8
|
||||||
|
```
|
||||||
|
|
||||||
|
[Build 7](https://ci.yebilly.me/job/secure-delivery/job/pricing/7/) stopped after
|
||||||
|
17.784 s with `Cannot fork` during test setup, before approval/deployment.
|
||||||
|
The agent cgroup showed 115/128 tasks and two limit events; Docker stats showed
|
||||||
|
132.6/512 MiB, PIDS=114 and no OOM kill. Its process listing showed Java only;
|
||||||
|
the accounting/accumulation mechanism was not established. Only the idle
|
||||||
|
delivery-agent container was restarted, preserving identity, workspace, image,
|
||||||
|
all limits and application services. Immediate Docker stats showed PIDS=13.
|
||||||
|
No resource/security limit was raised. Build 8 is the successful retry.
|
||||||
|
|
||||||
|
| Build 8 event | Actual result |
|
||||||
|
|---|---|
|
||||||
|
| [Jenkins run](https://ci.yebilly.me/job/secure-delivery/job/pricing/8/) | SUCCESS; 04:22:04.875–04:24:48.529; 163.654 s including approval wait |
|
||||||
|
| Actual approval | `vsun1`, 04:23:36, archived |
|
||||||
|
| Ansible rollback | 04:23:42.801–04:24:46.705; 63.904 s; ok=10 changed=3 unreachable=0 failed=0 |
|
||||||
|
| First v1 health response completed | 04:24:25.313; request started 04:24:23.645 |
|
||||||
|
| Restored behavior | HTTPS health/identity/price passed; v1, source 34f26e6, total 30 |
|
||||||
|
|
||||||
|
[Actual production v1 SUCCESS screenshot](../../manual/latex/images/assignment8-rollback-8-20261115.jpg):
|
||||||
|
build 8 completed November 16 at 04:24:48 UTC; deployment recap passed.
|
||||||
|
|
||||||
|
Twelve control and three app tests, source-secret and nine-dependency gates
|
||||||
|
passed. Build/publish was skipped: the original scanned digest and matching
|
||||||
|
Ansible configuration were restored without rebuilding. Deployment-start to
|
||||||
|
first observed v1 response completion was 42.512 s. Decision-to-recovery also
|
||||||
|
includes the runner error, troubleshooting and actual human wait; it is not
|
||||||
|
traffic interruption time.
|
||||||
|
|
||||||
|
Production: **863 requests, 9 failures** (8 HTTP 502, one timeout), sampled
|
||||||
|
04:17:46.447–04:32:10.607. Adjacent successful response completions:
|
||||||
|
04:24:12.672 (v2), 04:24:25.313 (v1), **12.641 s apart**. First failed request:
|
||||||
|
04:24:13.629. This is sampled evidence, not an exact continuous outage duration
|
||||||
|
or proof of zero interruption between requests. Maximum request-start gap:
|
||||||
|
2.015 s; two-second timeouts delayed the nominal one-second cadence.
|
||||||
|
|
||||||
|
## Separate staging failure and recovery
|
||||||
|
|
||||||
|
[Build 9](https://ci.yebilly.me/job/secure-delivery/job/pricing/9/) selected the
|
||||||
|
good v2 staging record and changed only its runtime configuration selection
|
||||||
|
to the reviewed bad SHA. Its existing image remained:
|
||||||
|
|
||||||
|
```text
|
||||||
|
git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b
|
||||||
|
```
|
||||||
|
|
||||||
|
Gunicorn bound to 8001; image health/Caddy used 8000. Compose reported
|
||||||
|
`container pricing-staging-app-1 is unhealthy`. The command retained
|
||||||
|
`--wait --wait-timeout 90`; Ansible blocked after 86.690 s including earlier
|
||||||
|
tasks: ok=4 changed=1 unreachable=0 failed=1, exit 2. No unchanged rerun,
|
||||||
|
production approval or production deployment ran.
|
||||||
|
|
||||||
|
The 04:28:54.827 snapshot confirmed staging unhealthy/HTTP 502 at the same v2
|
||||||
|
digest while production remained healthy v1/total 30. The failed run did not
|
||||||
|
reach the final metadata-copy task: host `release.json` still described the
|
||||||
|
last good release while Compose was bad. That file alone cannot prove health.
|
||||||
|
|
||||||
|
[Build 10](https://ci.yebilly.me/job/secure-delivery/job/pricing/10/) used the
|
||||||
|
original good v2 staging record and restored playbook/template from
|
||||||
|
`6bddbfba5a36e0e397537678ffb197e101fb0670` using `git archive`. No rebuild/push.
|
||||||
|
|
||||||
|
| Staging event | UTC / actual result |
|
||||||
|
|---|---|
|
||||||
|
| Decision / observer start | 04:25:23.940 / 04:25:24.078 |
|
||||||
|
| Failed deployment | 04:26:25.354–04:27:52.043; 86.690 s; build 9 FAILURE |
|
||||||
|
| First failed request | 04:26:53.130 |
|
||||||
|
| Recovery job began | 04:28:38.093 |
|
||||||
|
| Recovery Ansible | 04:29:10.106–04:30:06.603; 56.497 s; ok=10 changed=2 failed=0 |
|
||||||
|
| First recovered v2 response completed | 04:29:44.923; request started 04:29:43.205 |
|
||||||
|
| Unchanged rerun | 04:30:10.352–04:30:58.451; 48.099 s; ok=10 changed=0 failed=0 |
|
||||||
|
| Recovery job ended | 04:30:59.765 SUCCESS; 141.672 s total |
|
||||||
|
|
||||||
|
Staging: **406 requests, 169 failures** (168 HTTP 502, one timeout), ending
|
||||||
|
04:32:11.031. Adjacent successful response completions: 04:26:52.273 and
|
||||||
|
04:29:44.923, **172.650 s apart**. This includes fault, collection/selection,
|
||||||
|
new-job gates and restoration; it is not Ansible duration or an exact continuous
|
||||||
|
outage. Maximum request-start gap: 2.018 s. Production had no additional failed
|
||||||
|
observer requests during the staging exercise; its Compose hash was unchanged.
|
||||||
|
|
||||||
|
## Monitoring, final state and limits
|
||||||
|
|
||||||
|
At 04:34:28.765: production v1/source 34f26e6/total 30; staging v2/source
|
||||||
|
6bddbfb/total 36. Both healthy, exact original digests/configuration restored,
|
||||||
|
invalid quantity 0 returned HTTP 400, no published application host port.
|
||||||
|
All six scrape targets were up and all three HTTPS probes were 1. The 34
|
||||||
|
production samples since the decision were all 1: the 30-second probe missed
|
||||||
|
the short rollback interruption captured by the finer observer. Grafana was
|
||||||
|
flat over this exercise, unlike the earlier v2-release dip. The captured
|
||||||
|
90-minute query returned no `ALERTS` samples; no notification history or
|
||||||
|
Discord-notification claim is made. Staging used its own observer, not the
|
||||||
|
production-only chart.
|
||||||
|
|
||||||
|
Capacity sample: 1,967 MiB RAM, 660 MiB available; swap 476/2,047 MiB;
|
||||||
|
root space 8.9 GiB available, 62% used. Pricing used 32.53/33.68 MiB;
|
||||||
|
agent 131.9/512 MiB and 71/128 tasks, zero new process-limit events since
|
||||||
|
restart. Grafana used 188.4/192 MiB. These are point samples, not load/soak
|
||||||
|
tests. Serialize jobs on the shared CPU. The same-host observer shares the
|
||||||
|
Droplet failure domain; no off-site monitoring or high availability is claimed.
|
||||||
|
Status-only probes cannot verify price.
|
||||||
|
|
||||||
|
Both bounded observers were stopped after post-recovery verification rather
|
||||||
|
than waiting out their 1,800-second maximum. Only their verified PIDs were
|
||||||
|
signaled. Earlier services, volumes, credentials, gates and backups remain.
|
||||||
|
|
||||||
|
[Issue 28](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/issues/28) was
|
||||||
|
created with Vincent's explicit authorization at 04:33:40 during finalization,
|
||||||
|
after implementation and exercises. It records a late workflow correction,
|
||||||
|
not a pre-implementation issue. Final group review/merge and submission remain.
|
||||||
@@ -0,0 +1,864 @@
|
|||||||
|
started_utc,elapsed_seconds,http_status,status,version,error
|
||||||
|
2026-11-16T04:17:46.446751+00:00,0.053,200,ok,v2,
|
||||||
|
2026-11-16T04:17:47.447643+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:17:48.447821+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:17:49.448064+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:17:50.448234+00:00,0.041,200,ok,v2,
|
||||||
|
2026-11-16T04:17:51.448433+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:17:52.448697+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:17:53.448907+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:17:54.449062+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:17:55.449494+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:17:56.449650+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:17:57.449871+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:17:58.450040+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:17:59.450175+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:18:00.451897+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:18:01.452072+00:00,0.053,200,ok,v2,
|
||||||
|
2026-11-16T04:18:02.453528+00:00,0.046,200,ok,v2,
|
||||||
|
2026-11-16T04:18:03.454671+00:00,0.049,200,ok,v2,
|
||||||
|
2026-11-16T04:18:04.456958+00:00,0.05,200,ok,v2,
|
||||||
|
2026-11-16T04:18:05.457115+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:18:06.457304+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:18:07.457542+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:18:08.457704+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:18:09.457900+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:18:10.458901+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:18:11.459038+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:18:12.459471+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:18:13.459761+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:18:14.459931+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:18:15.460081+00:00,0.024,200,ok,v2,
|
||||||
|
2026-11-16T04:18:16.460265+00:00,0.054,200,ok,v2,
|
||||||
|
2026-11-16T04:18:17.460471+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:18:18.460663+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:18:19.460871+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:18:20.461012+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:18:21.461147+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:18:22.462927+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:18:23.463092+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:18:24.463273+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:18:25.463503+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:18:26.463691+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:18:27.463899+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:18:28.464103+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:18:29.464316+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:18:30.464494+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:18:31.464694+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:18:32.464915+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:18:33.465086+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:18:34.465426+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:18:35.465650+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:18:36.465831+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:18:37.466093+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:18:38.466335+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:18:39.466527+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:18:40.466734+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:18:41.466975+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:18:42.468028+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:18:43.468912+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:18:44.469066+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:18:45.469346+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:18:46.469555+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:18:47.469716+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:18:48.469898+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:18:49.470147+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:18:50.470367+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:18:51.470535+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:18:52.475231+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:18:53.475455+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:18:54.475676+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:18:55.476911+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:18:56.477920+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:18:57.478076+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:18:58.478940+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:18:59.479170+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:00.479347+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:01.479589+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:19:02.479816+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:19:03.480065+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:19:04.480333+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:19:05.480498+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:06.480716+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:07.481908+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:19:08.482917+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:19:09.484435+00:00,0.061,200,ok,v2,
|
||||||
|
2026-11-16T04:19:10.484906+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:19:11.485935+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:19:12.486141+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:19:13.486380+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:19:14.486608+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:19:15.486810+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:19:16.486988+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:19:17.487189+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:18.487422+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:19.487600+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:20.487836+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:21.488915+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:19:22.489923+00:00,0.046,200,ok,v2,
|
||||||
|
2026-11-16T04:19:23.490063+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:19:24.490919+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:25.491066+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:19:26.491251+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:27.491429+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:28.491655+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:29.491908+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:30.492227+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:19:31.492459+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:32.493925+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:33.494150+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:34.494460+00:00,0.09,200,ok,v2,
|
||||||
|
2026-11-16T04:19:35.494609+00:00,0.094,200,ok,v2,
|
||||||
|
2026-11-16T04:19:36.495921+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:19:37.496910+00:00,0.062,200,ok,v2,
|
||||||
|
2026-11-16T04:19:38.497100+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:39.497508+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:40.497691+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:41.497867+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:42.498063+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:19:43.498247+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:44.498430+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:45.498636+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:46.498829+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:19:47.499029+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:19:48.499912+00:00,0.085,200,ok,v2,
|
||||||
|
2026-11-16T04:19:49.500066+00:00,0.085,200,ok,v2,
|
||||||
|
2026-11-16T04:19:50.500907+00:00,0.05,200,ok,v2,
|
||||||
|
2026-11-16T04:19:51.501048+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:19:52.501265+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:19:53.501774+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:19:54.501997+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:55.502267+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:19:56.502511+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:19:57.502710+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:19:58.502955+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:19:59.503165+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:20:00.503403+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:01.518818+00:00,0.069,200,ok,v2,
|
||||||
|
2026-11-16T04:20:02.519927+00:00,0.077,200,ok,v2,
|
||||||
|
2026-11-16T04:20:03.520123+00:00,0.067,200,ok,v2,
|
||||||
|
2026-11-16T04:20:04.520333+00:00,0.069,200,ok,v2,
|
||||||
|
2026-11-16T04:20:05.526734+00:00,0.092,200,ok,v2,
|
||||||
|
2026-11-16T04:20:06.526912+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:20:07.527159+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:20:08.527364+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:20:09.527593+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:20:10.527782+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:20:11.530230+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:20:12.530435+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:20:13.530675+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:20:14.530893+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:20:15.531068+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:20:16.531267+00:00,0.052,200,ok,v2,
|
||||||
|
2026-11-16T04:20:17.531501+00:00,0.062,200,ok,v2,
|
||||||
|
2026-11-16T04:20:18.531666+00:00,0.059,200,ok,v2,
|
||||||
|
2026-11-16T04:20:19.531822+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:20:20.532046+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:20:21.532291+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:20:22.532513+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:20:23.532713+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:24.533533+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:20:25.533882+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:20:26.534116+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:27.534312+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:28.534505+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:20:29.534683+00:00,0.049,200,ok,v2,
|
||||||
|
2026-11-16T04:20:30.534927+00:00,0.054,200,ok,v2,
|
||||||
|
2026-11-16T04:20:31.535152+00:00,0.051,200,ok,v2,
|
||||||
|
2026-11-16T04:20:32.535293+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:20:33.535514+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:20:34.535686+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:35.535901+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:20:36.536158+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:20:37.536377+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:20:38.536623+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:20:39.537158+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:20:40.537421+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:20:41.537644+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:20:42.537902+00:00,0.047,200,ok,v2,
|
||||||
|
2026-11-16T04:20:43.538914+00:00,0.051,200,ok,v2,
|
||||||
|
2026-11-16T04:20:44.539129+00:00,0.051,200,ok,v2,
|
||||||
|
2026-11-16T04:20:45.539316+00:00,0.047,200,ok,v2,
|
||||||
|
2026-11-16T04:20:46.539571+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:20:47.539792+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:20:48.540007+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:20:49.540221+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:50.540426+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:20:51.540653+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:52.540928+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:20:53.541120+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:54.541390+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:20:55.541565+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:20:56.541768+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:20:57.541982+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:20:58.542144+00:00,0.048,200,ok,v2,
|
||||||
|
2026-11-16T04:20:59.542314+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:00.542502+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:21:01.542702+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:21:02.542907+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:03.543101+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:21:04.543328+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:21:05.543535+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:06.543733+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:21:07.543931+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:21:08.544123+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:21:09.544316+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:21:10.544522+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:21:11.544737+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:21:12.544929+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:21:13.545105+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:21:14.545423+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:21:15.545617+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:16.545810+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:21:17.546021+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:18.546227+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:19.546462+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:21:20.546684+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:21.546903+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:22.547075+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:21:23.547218+00:00,0.048,200,ok,v2,
|
||||||
|
2026-11-16T04:21:24.547452+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:21:25.547660+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:26.547904+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:21:27.548119+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:28.548356+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:29.548575+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:21:30.548796+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:31.549004+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:32.549251+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:21:33.549497+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:34.549720+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:21:35.549935+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:21:36.550143+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:21:37.550376+00:00,0.046,200,ok,v2,
|
||||||
|
2026-11-16T04:21:38.550613+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:21:39.550876+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:21:40.551099+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:21:41.551339+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:42.551528+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:21:43.551729+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:21:44.551915+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:21:45.552887+00:00,0.024,200,ok,v2,
|
||||||
|
2026-11-16T04:21:46.553048+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:21:47.553245+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:21:48.553518+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:21:49.553694+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:21:50.554466+00:00,0.052,200,ok,v2,
|
||||||
|
2026-11-16T04:21:51.555341+00:00,0.05,200,ok,v2,
|
||||||
|
2026-11-16T04:21:52.556348+00:00,0.064,200,ok,v2,
|
||||||
|
2026-11-16T04:21:53.556504+00:00,0.048,200,ok,v2,
|
||||||
|
2026-11-16T04:21:54.556753+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:21:55.556908+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:56.557913+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:57.558061+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:21:58.558537+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:21:59.558687+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:22:00.558913+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:22:01.559076+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:22:02.559243+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:22:03.559431+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:22:04.559682+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:22:05.560331+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:22:06.560900+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:22:07.561900+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:22:08.562042+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:22:09.563534+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:22:10.564719+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:11.564933+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:22:12.566913+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:13.567111+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:14.567277+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:15.568130+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:22:16.568287+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:22:17.568904+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:22:18.569810+00:00,0.049,200,ok,v2,
|
||||||
|
2026-11-16T04:22:19.570070+00:00,0.064,200,ok,v2,
|
||||||
|
2026-11-16T04:22:20.571916+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:22:21.572406+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:22:22.572574+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:22:23.572794+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:22:24.573036+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:22:25.573271+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:22:26.573544+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:22:27.573708+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:22:28.573942+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:29.574123+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:22:30.574331+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:22:31.574562+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:22:32.574915+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:22:33.575953+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:22:34.576921+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:22:35.577130+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:36.577382+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:22:37.577627+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:22:38.577841+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:39.578090+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:22:40.578296+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:22:41.578483+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:22:42.578733+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:22:43.578899+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:22:44.579043+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:22:45.579783+00:00,0.047,200,ok,v2,
|
||||||
|
2026-11-16T04:22:46.579920+00:00,0.05,200,ok,v2,
|
||||||
|
2026-11-16T04:22:47.580071+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:22:48.580272+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:22:49.580490+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:22:50.580674+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:22:51.580929+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:22:52.581141+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:22:53.581323+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:22:54.581585+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:22:55.581804+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:22:56.582047+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:22:57.582966+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:22:58.583151+00:00,0.05,200,ok,v2,
|
||||||
|
2026-11-16T04:22:59.583910+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:23:00.585129+00:00,0.043,200,ok,v2,
|
||||||
|
2026-11-16T04:23:01.585929+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:23:02.586474+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:23:03.586643+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:23:04.586882+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:23:05.587103+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:23:06.587425+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:23:07.587634+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:23:08.587906+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:23:09.588129+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:23:10.588336+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:23:11.589915+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:23:12.590928+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:23:13.591083+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:23:14.591242+00:00,0.049,200,ok,v2,
|
||||||
|
2026-11-16T04:23:15.591407+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:23:16.591647+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:23:17.591866+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:23:18.592081+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:23:19.592316+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:23:20.592537+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:23:21.592757+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:23:22.592969+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:23:23.593240+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:23:24.593540+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:23:25.593691+00:00,0.044,200,ok,v2,
|
||||||
|
2026-11-16T04:23:26.593909+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:23:27.594059+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:23:28.594202+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:23:29.594411+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:23:30.594610+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:23:31.594824+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:23:32.595031+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:23:33.595267+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:23:34.595511+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:23:35.595829+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:23:36.596060+00:00,0.051,200,ok,v2,
|
||||||
|
2026-11-16T04:23:37.596439+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:23:38.597918+00:00,0.092,200,ok,v2,
|
||||||
|
2026-11-16T04:23:39.598949+00:00,0.057,200,ok,v2,
|
||||||
|
2026-11-16T04:23:40.599926+00:00,0.055,200,ok,v2,
|
||||||
|
2026-11-16T04:23:41.600902+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:23:42.601926+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:23:43.602521+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:23:44.603916+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:23:45.604797+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:23:46.606149+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:23:47.606908+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:23:48.607893+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:23:49.609902+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:23:50.610732+00:00,0.047,200,ok,v2,
|
||||||
|
2026-11-16T04:23:51.613150+00:00,0.075,200,ok,v2,
|
||||||
|
2026-11-16T04:23:52.614080+00:00,0.051,200,ok,v2,
|
||||||
|
2026-11-16T04:23:53.615905+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:23:54.616702+00:00,0.061,200,ok,v2,
|
||||||
|
2026-11-16T04:23:55.616938+00:00,0.061,200,ok,v2,
|
||||||
|
2026-11-16T04:23:56.617820+00:00,0.041,200,ok,v2,
|
||||||
|
2026-11-16T04:23:57.618003+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:23:58.618159+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:23:59.618902+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:24:00.619913+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:24:01.620903+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:24:02.621359+00:00,0.046,200,ok,v2,
|
||||||
|
2026-11-16T04:24:03.621533+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:24:04.622918+00:00,0.049,200,ok,v2,
|
||||||
|
2026-11-16T04:24:05.623231+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:24:06.623915+00:00,0.041,200,ok,v2,
|
||||||
|
2026-11-16T04:24:07.624910+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:24:08.625911+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:24:09.626932+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:24:10.627893+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:24:11.628292+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:24:12.628587+00:00,0.043,200,ok,v2,
|
||||||
|
2026-11-16T04:24:13.628753+00:00,0.034,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:14.628906+00:00,0.026,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:15.629037+00:00,0.019,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:16.629305+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:17.629474+00:00,0.029,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:18.629654+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:19.629808+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:20.629968+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:24:21.630135+00:00,2.015,,,,TimeoutError
|
||||||
|
2026-11-16T04:24:23.645071+00:00,1.668,200,ok,v1,
|
||||||
|
2026-11-16T04:24:25.313178+00:00,0.079,200,ok,v1,
|
||||||
|
2026-11-16T04:24:26.313332+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:24:27.314180+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:24:28.315449+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:24:29.315617+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:24:30.319150+00:00,0.044,200,ok,v1,
|
||||||
|
2026-11-16T04:24:31.319724+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:24:32.319894+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:24:33.320026+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:24:34.321573+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:24:35.323903+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:24:36.324973+00:00,0.041,200,ok,v1,
|
||||||
|
2026-11-16T04:24:37.326900+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:24:38.328808+00:00,0.064,200,ok,v1,
|
||||||
|
2026-11-16T04:24:39.330946+00:00,0.067,200,ok,v1,
|
||||||
|
2026-11-16T04:24:40.331604+00:00,0.028,200,ok,v1,
|
||||||
|
2026-11-16T04:24:41.332797+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:24:42.332944+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:24:43.334795+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:24:44.335899+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:24:45.337244+00:00,0.039,200,ok,v1,
|
||||||
|
2026-11-16T04:24:46.337433+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:24:47.337630+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:24:48.338400+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:24:49.338555+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:24:50.338912+00:00,0.057,200,ok,v1,
|
||||||
|
2026-11-16T04:24:51.339135+00:00,0.05,200,ok,v1,
|
||||||
|
2026-11-16T04:24:52.339334+00:00,0.049,200,ok,v1,
|
||||||
|
2026-11-16T04:24:53.339524+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:24:54.339698+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:24:55.339906+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:24:56.340113+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:24:57.340301+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:24:58.340497+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:24:59.340708+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:25:00.341092+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:25:01.341299+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:25:02.341729+00:00,0.05,200,ok,v1,
|
||||||
|
2026-11-16T04:25:03.341978+00:00,0.051,200,ok,v1,
|
||||||
|
2026-11-16T04:25:04.342222+00:00,0.055,200,ok,v1,
|
||||||
|
2026-11-16T04:25:05.342471+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:25:06.342696+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:25:07.342929+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:25:08.343127+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:25:09.343328+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:25:10.343532+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:25:11.343771+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:25:12.343977+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:25:13.344215+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:25:14.344455+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:25:15.344723+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:25:16.344962+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:25:17.345932+00:00,0.054,200,ok,v1,
|
||||||
|
2026-11-16T04:25:18.346138+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:25:19.346303+00:00,0.042,200,ok,v1,
|
||||||
|
2026-11-16T04:25:20.346522+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:25:21.346726+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:25:22.350249+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:25:23.350576+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:25:24.350893+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:25:25.351190+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:25:26.351352+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:25:27.351505+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:25:28.351733+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:25:29.351903+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:25:30.352069+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:25:31.352234+00:00,0.041,200,ok,v1,
|
||||||
|
2026-11-16T04:25:32.352380+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:25:33.352512+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:25:34.352708+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:25:35.352910+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:25:36.353053+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:25:37.353207+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:25:38.353364+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:25:39.353596+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:25:40.353732+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:25:41.353962+00:00,0.028,200,ok,v1,
|
||||||
|
2026-11-16T04:25:42.354184+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:25:43.354375+00:00,0.044,200,ok,v1,
|
||||||
|
2026-11-16T04:25:44.354560+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:25:45.354725+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:25:46.354924+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:25:47.355083+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:25:48.355268+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:25:49.356020+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:25:50.357474+00:00,0.039,200,ok,v1,
|
||||||
|
2026-11-16T04:25:51.357685+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:25:52.358904+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:25:53.359441+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:25:54.360501+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:25:55.360639+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:25:56.361318+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:25:57.361994+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:25:58.362157+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:25:59.362357+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:26:00.362517+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:26:01.362797+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:26:02.362964+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:26:03.364772+00:00,0.059,200,ok,v1,
|
||||||
|
2026-11-16T04:26:04.364913+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:26:05.365102+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:26:06.365300+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:26:07.365916+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:26:08.366083+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:26:09.366246+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:26:10.366998+00:00,0.057,200,ok,v1,
|
||||||
|
2026-11-16T04:26:11.367154+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:26:12.367796+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:26:13.367960+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:26:14.368126+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:26:15.368311+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:26:16.368451+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:26:17.368611+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:26:18.368777+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:26:19.368956+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:26:20.369905+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:26:21.370903+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:26:22.371921+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:26:23.372141+00:00,0.04,200,ok,v1,
|
||||||
|
2026-11-16T04:26:24.372916+00:00,0.047,200,ok,v1,
|
||||||
|
2026-11-16T04:26:25.373094+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:26:26.373315+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:26:27.374368+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:26:28.374893+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:26:29.375047+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:26:30.375241+00:00,0.078,200,ok,v1,
|
||||||
|
2026-11-16T04:26:31.375372+00:00,0.032,200,ok,v1,
|
||||||
|
2026-11-16T04:26:32.375554+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:26:33.375707+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:26:34.376724+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:26:35.376909+00:00,0.073,200,ok,v1,
|
||||||
|
2026-11-16T04:26:36.377017+00:00,0.039,200,ok,v1,
|
||||||
|
2026-11-16T04:26:37.377178+00:00,0.062,200,ok,v1,
|
||||||
|
2026-11-16T04:26:38.377909+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:26:39.378049+00:00,0.053,200,ok,v1,
|
||||||
|
2026-11-16T04:26:40.378245+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:26:41.378559+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:26:42.379222+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:26:43.380768+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:26:44.380920+00:00,0.05,200,ok,v1,
|
||||||
|
2026-11-16T04:26:45.381114+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:26:46.381903+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:26:47.382647+00:00,0.042,200,ok,v1,
|
||||||
|
2026-11-16T04:26:48.382798+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:26:49.384904+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:26:50.385315+00:00,0.075,200,ok,v1,
|
||||||
|
2026-11-16T04:26:51.386919+00:00,0.065,200,ok,v1,
|
||||||
|
2026-11-16T04:26:52.389914+00:00,0.076,200,ok,v1,
|
||||||
|
2026-11-16T04:26:53.391229+00:00,0.08,200,ok,v1,
|
||||||
|
2026-11-16T04:26:54.392101+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:26:55.392912+00:00,0.043,200,ok,v1,
|
||||||
|
2026-11-16T04:26:56.393073+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:26:57.393244+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:26:58.393485+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:26:59.393636+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:27:00.394124+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:27:01.394317+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:27:02.394491+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:27:03.394664+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:27:04.394819+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:27:05.394994+00:00,0.04,200,ok,v1,
|
||||||
|
2026-11-16T04:27:06.395130+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:27:07.395278+00:00,0.044,200,ok,v1,
|
||||||
|
2026-11-16T04:27:08.395494+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:27:09.395655+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:27:10.395838+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:27:11.396270+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:27:12.396443+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:27:13.396614+00:00,0.028,200,ok,v1,
|
||||||
|
2026-11-16T04:27:14.396775+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:27:15.396977+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:27:16.397164+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:27:17.397317+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:27:18.397435+00:00,0.047,200,ok,v1,
|
||||||
|
2026-11-16T04:27:19.397546+00:00,0.089,200,ok,v1,
|
||||||
|
2026-11-16T04:27:20.397686+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:27:21.397834+00:00,0.049,200,ok,v1,
|
||||||
|
2026-11-16T04:27:22.398137+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:27:23.398306+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:27:24.398462+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:27:25.398625+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:27:26.398791+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:27:27.398907+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:27:28.399087+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:27:29.399255+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:27:30.399408+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:27:31.399587+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:27:32.400498+00:00,0.112,200,ok,v1,
|
||||||
|
2026-11-16T04:27:33.400683+00:00,0.061,200,ok,v1,
|
||||||
|
2026-11-16T04:27:34.400840+00:00,0.087,200,ok,v1,
|
||||||
|
2026-11-16T04:27:35.401043+00:00,0.088,200,ok,v1,
|
||||||
|
2026-11-16T04:27:36.401225+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:27:37.401513+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:27:38.401774+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:27:39.401921+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:27:40.402080+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:27:41.402256+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:27:42.402434+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:27:43.402617+00:00,0.041,200,ok,v1,
|
||||||
|
2026-11-16T04:27:44.402816+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:27:45.403015+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:27:46.403123+00:00,0.087,200,ok,v1,
|
||||||
|
2026-11-16T04:27:47.403273+00:00,0.084,200,ok,v1,
|
||||||
|
2026-11-16T04:27:48.403434+00:00,0.086,200,ok,v1,
|
||||||
|
2026-11-16T04:27:49.403592+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:27:50.403755+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:27:51.404900+00:00,0.058,200,ok,v1,
|
||||||
|
2026-11-16T04:27:52.405165+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:27:53.405403+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:27:54.405637+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:27:55.433056+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:27:56.433921+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:27:57.434110+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:27:58.434318+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:27:59.434615+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:28:00.434883+00:00,0.065,200,ok,v1,
|
||||||
|
2026-11-16T04:28:01.435917+00:00,0.052,200,ok,v1,
|
||||||
|
2026-11-16T04:28:02.436084+00:00,0.054,200,ok,v1,
|
||||||
|
2026-11-16T04:28:03.436241+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:04.436511+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:28:05.436786+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:28:06.437076+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:28:07.437298+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:08.437648+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:28:09.437800+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:10.437992+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:28:11.438228+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:28:12.438490+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:13.444784+00:00,0.044,200,ok,v1,
|
||||||
|
2026-11-16T04:28:14.444991+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:28:15.445200+00:00,0.042,200,ok,v1,
|
||||||
|
2026-11-16T04:28:16.445328+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:28:17.445547+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:18.445771+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:19.446579+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:28:20.446804+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:21.446903+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:22.447125+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:23.447345+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:24.447486+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:28:25.447702+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:28:26.447937+00:00,0.04,200,ok,v1,
|
||||||
|
2026-11-16T04:28:27.448087+00:00,0.043,200,ok,v1,
|
||||||
|
2026-11-16T04:28:28.448250+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:28:29.448418+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:30.448604+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:31.448750+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:32.448994+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:33.449135+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:28:34.449276+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:28:35.449530+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:28:36.449683+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:37.449871+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:28:38.450008+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:28:39.450154+00:00,0.043,200,ok,v1,
|
||||||
|
2026-11-16T04:28:40.450903+00:00,0.047,200,ok,v1,
|
||||||
|
2026-11-16T04:28:41.451043+00:00,0.042,200,ok,v1,
|
||||||
|
2026-11-16T04:28:42.451182+00:00,0.039,200,ok,v1,
|
||||||
|
2026-11-16T04:28:43.451924+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:28:44.453246+00:00,0.043,200,ok,v1,
|
||||||
|
2026-11-16T04:28:45.453407+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:28:46.454192+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:28:47.454357+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:28:48.454511+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:28:49.455921+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:28:50.456919+00:00,0.044,200,ok,v1,
|
||||||
|
2026-11-16T04:28:51.457915+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:28:52.458091+00:00,0.057,200,ok,v1,
|
||||||
|
2026-11-16T04:28:53.458285+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:28:54.459911+00:00,0.081,200,ok,v1,
|
||||||
|
2026-11-16T04:28:55.460702+00:00,0.039,200,ok,v1,
|
||||||
|
2026-11-16T04:28:56.461744+00:00,0.041,200,ok,v1,
|
||||||
|
2026-11-16T04:28:57.461926+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:28:58.462931+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:28:59.464914+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:29:00.465068+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:29:01.465259+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:29:02.465493+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:29:03.465667+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:29:04.466917+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:29:05.467111+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:29:06.467327+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:29:07.467967+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:29:08.468157+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:29:09.469270+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:29:10.469901+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:29:11.470415+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:29:12.472835+00:00,0.056,200,ok,v1,
|
||||||
|
2026-11-16T04:29:13.473411+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:29:14.473907+00:00,0.047,200,ok,v1,
|
||||||
|
2026-11-16T04:29:15.474705+00:00,0.078,200,ok,v1,
|
||||||
|
2026-11-16T04:29:16.474885+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:29:17.475022+00:00,0.013,200,ok,v1,
|
||||||
|
2026-11-16T04:29:18.475528+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:29:19.476912+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:29:20.477058+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:29:21.477221+00:00,0.051,200,ok,v1,
|
||||||
|
2026-11-16T04:29:22.477519+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:29:23.477667+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:29:24.477821+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:29:25.478902+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:29:26.479125+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:29:27.479333+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:29:28.479493+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:29:29.480630+00:00,0.028,200,ok,v1,
|
||||||
|
2026-11-16T04:29:30.480788+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:29:31.481144+00:00,0.041,200,ok,v1,
|
||||||
|
2026-11-16T04:29:32.481403+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:29:33.482016+00:00,0.112,200,ok,v1,
|
||||||
|
2026-11-16T04:29:34.482279+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:29:35.482422+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:29:36.482577+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:29:37.482738+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:29:38.482924+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:29:39.483901+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:29:40.484088+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:29:41.484243+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:29:42.484396+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:29:43.484545+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:29:44.484702+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:29:45.484887+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:29:46.485904+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:29:47.487917+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:29:48.488174+00:00,0.102,200,ok,v1,
|
||||||
|
2026-11-16T04:29:49.488383+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:29:50.488772+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:29:51.489015+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:29:52.489224+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:29:53.489428+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:29:54.489596+00:00,0.032,200,ok,v1,
|
||||||
|
2026-11-16T04:29:55.489821+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:29:56.490533+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:29:57.491894+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:29:58.492089+00:00,0.043,200,ok,v1,
|
||||||
|
2026-11-16T04:29:59.492940+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:30:00.495070+00:00,0.093,200,ok,v1,
|
||||||
|
2026-11-16T04:30:01.496802+00:00,0.061,200,ok,v1,
|
||||||
|
2026-11-16T04:30:02.497919+00:00,0.107,200,ok,v1,
|
||||||
|
2026-11-16T04:30:03.498102+00:00,0.042,200,ok,v1,
|
||||||
|
2026-11-16T04:30:04.498310+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:30:05.500708+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:30:06.502032+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:30:07.502911+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:30:08.503915+00:00,0.044,200,ok,v1,
|
||||||
|
2026-11-16T04:30:09.504905+00:00,0.039,200,ok,v1,
|
||||||
|
2026-11-16T04:30:10.505926+00:00,0.037,200,ok,v1,
|
||||||
|
2026-11-16T04:30:11.506085+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:30:12.506908+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:30:13.507652+00:00,0.055,200,ok,v1,
|
||||||
|
2026-11-16T04:30:14.507915+00:00,0.055,200,ok,v1,
|
||||||
|
2026-11-16T04:30:15.508922+00:00,0.076,200,ok,v1,
|
||||||
|
2026-11-16T04:30:16.510315+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:30:17.510506+00:00,0.035,200,ok,v1,
|
||||||
|
2026-11-16T04:30:18.510923+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:30:19.511903+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:30:20.512892+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:30:21.513037+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:30:22.513929+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:30:23.514074+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:30:24.514621+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:30:25.514933+00:00,0.03,200,ok,v1,
|
||||||
|
2026-11-16T04:30:26.515575+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:30:27.516921+00:00,0.054,200,ok,v1,
|
||||||
|
2026-11-16T04:30:28.519570+00:00,0.081,200,ok,v1,
|
||||||
|
2026-11-16T04:30:29.520921+00:00,0.074,200,ok,v1,
|
||||||
|
2026-11-16T04:30:30.522897+00:00,0.07,200,ok,v1,
|
||||||
|
2026-11-16T04:30:31.523044+00:00,0.047,200,ok,v1,
|
||||||
|
2026-11-16T04:30:32.523381+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:30:33.524897+00:00,0.026,200,ok,v1,
|
||||||
|
2026-11-16T04:30:34.525054+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:30:35.526005+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:30:36.526160+00:00,0.052,200,ok,v1,
|
||||||
|
2026-11-16T04:30:37.526898+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:30:38.528913+00:00,0.058,200,ok,v1,
|
||||||
|
2026-11-16T04:30:39.529925+00:00,0.046,200,ok,v1,
|
||||||
|
2026-11-16T04:30:40.531942+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:30:41.533812+00:00,0.089,200,ok,v1,
|
||||||
|
2026-11-16T04:30:42.536216+00:00,0.077,200,ok,v1,
|
||||||
|
2026-11-16T04:30:43.537937+00:00,0.057,200,ok,v1,
|
||||||
|
2026-11-16T04:30:44.539932+00:00,0.078,200,ok,v1,
|
||||||
|
2026-11-16T04:30:45.540103+00:00,0.033,200,ok,v1,
|
||||||
|
2026-11-16T04:30:46.542909+00:00,0.087,200,ok,v1,
|
||||||
|
2026-11-16T04:30:47.543786+00:00,0.053,200,ok,v1,
|
||||||
|
2026-11-16T04:30:48.545022+00:00,0.04,200,ok,v1,
|
||||||
|
2026-11-16T04:30:49.545194+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:30:50.546952+00:00,0.032,200,ok,v1,
|
||||||
|
2026-11-16T04:30:51.547570+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:30:52.550196+00:00,0.06,200,ok,v1,
|
||||||
|
2026-11-16T04:30:53.551016+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:30:54.552907+00:00,0.043,200,ok,v1,
|
||||||
|
2026-11-16T04:30:55.553823+00:00,0.064,200,ok,v1,
|
||||||
|
2026-11-16T04:30:56.554279+00:00,0.038,200,ok,v1,
|
||||||
|
2026-11-16T04:30:57.554425+00:00,0.065,200,ok,v1,
|
||||||
|
2026-11-16T04:30:58.554625+00:00,0.036,200,ok,v1,
|
||||||
|
2026-11-16T04:30:59.554789+00:00,0.025,200,ok,v1,
|
||||||
|
2026-11-16T04:31:00.555029+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:01.555258+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:31:02.555539+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:03.555782+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:04.555926+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:05.563200+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:31:06.568068+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:31:07.568263+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:08.568486+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:31:09.568705+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:10.568912+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:31:11.569103+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:31:12.569305+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:13.573443+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:31:14.573618+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:15.573881+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:31:16.574116+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:17.574279+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:31:18.574509+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:31:19.574747+00:00,0.021,200,ok,v1,
|
||||||
|
2026-11-16T04:31:20.574968+00:00,0.014,200,ok,v1,
|
||||||
|
2026-11-16T04:31:21.575156+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:31:22.575390+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:31:23.575553+00:00,0.041,200,ok,v1,
|
||||||
|
2026-11-16T04:31:24.576379+00:00,0.047,200,ok,v1,
|
||||||
|
2026-11-16T04:31:25.576623+00:00,0.029,200,ok,v1,
|
||||||
|
2026-11-16T04:31:26.576877+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:27.577125+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:31:28.577411+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:29.577654+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:31:30.577878+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:31:31.578109+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:31:32.587819+00:00,0.018,200,ok,v1,
|
||||||
|
2026-11-16T04:31:33.588058+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:31:34.588310+00:00,0.028,200,ok,v1,
|
||||||
|
2026-11-16T04:31:35.588740+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:31:36.589923+00:00,0.045,200,ok,v1,
|
||||||
|
2026-11-16T04:31:37.590961+00:00,0.097,200,ok,v1,
|
||||||
|
2026-11-16T04:31:38.593532+00:00,0.094,200,ok,v1,
|
||||||
|
2026-11-16T04:31:39.593696+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:31:40.593937+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:41.594150+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:31:42.594428+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:31:43.594595+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:44.594822+00:00,0.016,200,ok,v1,
|
||||||
|
2026-11-16T04:31:45.595087+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:31:46.595278+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:31:47.595433+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:31:48.595649+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:31:49.597912+00:00,0.034,200,ok,v1,
|
||||||
|
2026-11-16T04:31:50.598058+00:00,0.089,200,ok,v1,
|
||||||
|
2026-11-16T04:31:51.598911+00:00,0.092,200,ok,v1,
|
||||||
|
2026-11-16T04:31:52.600125+00:00,0.09,200,ok,v1,
|
||||||
|
2026-11-16T04:31:53.600222+00:00,0.024,200,ok,v1,
|
||||||
|
2026-11-16T04:31:54.600383+00:00,0.051,200,ok,v1,
|
||||||
|
2026-11-16T04:31:55.600540+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:31:56.600734+00:00,0.02,200,ok,v1,
|
||||||
|
2026-11-16T04:31:57.600942+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:31:58.601145+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:31:59.601378+00:00,0.017,200,ok,v1,
|
||||||
|
2026-11-16T04:32:00.601589+00:00,0.023,200,ok,v1,
|
||||||
|
2026-11-16T04:32:01.601816+00:00,0.028,200,ok,v1,
|
||||||
|
2026-11-16T04:32:02.602053+00:00,0.031,200,ok,v1,
|
||||||
|
2026-11-16T04:32:03.603926+00:00,0.072,200,ok,v1,
|
||||||
|
2026-11-16T04:32:04.604911+00:00,0.085,200,ok,v1,
|
||||||
|
2026-11-16T04:32:05.605919+00:00,0.083,200,ok,v1,
|
||||||
|
2026-11-16T04:32:06.606150+00:00,0.022,200,ok,v1,
|
||||||
|
2026-11-16T04:32:07.606366+00:00,0.015,200,ok,v1,
|
||||||
|
2026-11-16T04:32:08.606630+00:00,0.019,200,ok,v1,
|
||||||
|
2026-11-16T04:32:09.606881+00:00,0.027,200,ok,v1,
|
||||||
|
2026-11-16T04:32:10.607054+00:00,0.018,200,ok,v1,
|
||||||
|
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,407 @@
|
|||||||
|
started_utc,elapsed_seconds,http_status,status,version,error
|
||||||
|
2026-11-16T04:25:24.077935+00:00,0.07,200,ok,v2,
|
||||||
|
2026-11-16T04:25:25.078146+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:25:26.078374+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:25:27.078588+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:25:28.078777+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:25:29.078945+00:00,0.091,200,ok,v2,
|
||||||
|
2026-11-16T04:25:30.079944+00:00,0.088,200,ok,v2,
|
||||||
|
2026-11-16T04:25:31.080929+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:25:32.081162+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:25:33.081359+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:25:34.081663+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:25:35.081813+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:25:36.082041+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:25:37.082235+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:25:38.082467+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:25:39.082684+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:25:40.082924+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:25:41.083080+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:25:42.084078+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:25:43.084608+00:00,0.09,200,ok,v2,
|
||||||
|
2026-11-16T04:25:44.084920+00:00,0.083,200,ok,v2,
|
||||||
|
2026-11-16T04:25:45.085915+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:25:46.086907+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:25:47.087083+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:25:48.087246+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:25:49.087954+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:25:50.088097+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:25:51.088905+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:25:52.089100+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:25:53.090189+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:25:54.090399+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:25:55.090901+00:00,0.08,200,ok,v2,
|
||||||
|
2026-11-16T04:25:56.091061+00:00,0.079,200,ok,v2,
|
||||||
|
2026-11-16T04:25:57.091906+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:25:58.092087+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:25:59.092945+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:26:00.093207+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:26:01.093545+00:00,0.056,200,ok,v2,
|
||||||
|
2026-11-16T04:26:02.093789+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:26:03.094051+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:26:04.094283+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:26:05.094528+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:26:06.094766+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:26:07.095733+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:26:08.095917+00:00,0.075,200,ok,v2,
|
||||||
|
2026-11-16T04:26:09.097934+00:00,0.073,200,ok,v2,
|
||||||
|
2026-11-16T04:26:10.098929+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:26:11.099066+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:26:12.100928+00:00,0.052,200,ok,v2,
|
||||||
|
2026-11-16T04:26:13.101717+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:26:14.102909+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:26:15.103251+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:26:16.103683+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:26:17.104902+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:26:18.105912+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:26:19.106071+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:26:20.106914+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:26:21.107903+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:26:22.108904+00:00,0.063,200,ok,v2,
|
||||||
|
2026-11-16T04:26:23.110924+00:00,0.063,200,ok,v2,
|
||||||
|
2026-11-16T04:26:24.111911+00:00,0.058,200,ok,v2,
|
||||||
|
2026-11-16T04:26:25.112057+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:26:26.112807+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:26:27.113910+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:26:28.114070+00:00,0.058,200,ok,v2,
|
||||||
|
2026-11-16T04:26:29.114309+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:26:30.114638+00:00,0.044,200,ok,v2,
|
||||||
|
2026-11-16T04:26:31.114833+00:00,0.052,200,ok,v2,
|
||||||
|
2026-11-16T04:26:32.115700+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:26:33.115910+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:26:34.116303+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:26:35.116905+00:00,0.058,200,ok,v2,
|
||||||
|
2026-11-16T04:26:36.118115+00:00,0.059,200,ok,v2,
|
||||||
|
2026-11-16T04:26:37.119038+00:00,0.069,200,ok,v2,
|
||||||
|
2026-11-16T04:26:38.119180+00:00,0.06,200,ok,v2,
|
||||||
|
2026-11-16T04:26:39.120922+00:00,0.062,200,ok,v2,
|
||||||
|
2026-11-16T04:26:40.121060+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:26:41.121767+00:00,0.06,200,ok,v2,
|
||||||
|
2026-11-16T04:26:42.121938+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:26:43.122387+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:26:44.122876+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:26:45.123020+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:26:46.123362+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:26:47.124782+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:26:48.125797+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:26:49.128077+00:00,0.053,200,ok,v2,
|
||||||
|
2026-11-16T04:26:50.128314+00:00,0.096,200,ok,v2,
|
||||||
|
2026-11-16T04:26:51.129911+00:00,0.097,200,ok,v2,
|
||||||
|
2026-11-16T04:26:52.130143+00:00,0.143,200,ok,v2,
|
||||||
|
2026-11-16T04:26:53.130293+00:00,0.03,502,,,HTTPError
|
||||||
|
2026-11-16T04:26:54.130916+00:00,0.03,502,,,HTTPError
|
||||||
|
2026-11-16T04:26:55.131055+00:00,0.026,502,,,HTTPError
|
||||||
|
2026-11-16T04:26:56.131725+00:00,0.02,502,,,HTTPError
|
||||||
|
2026-11-16T04:26:57.131900+00:00,0.031,502,,,HTTPError
|
||||||
|
2026-11-16T04:26:58.132050+00:00,0.02,502,,,HTTPError
|
||||||
|
2026-11-16T04:26:59.132208+00:00,0.026,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:00.132599+00:00,0.025,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:01.132761+00:00,0.033,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:02.132956+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:03.133105+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:04.133265+00:00,0.025,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:05.133917+00:00,0.02,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:06.134386+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:07.134733+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:08.134942+00:00,0.021,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:09.135103+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:10.135447+00:00,0.044,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:11.136362+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:12.136531+00:00,0.021,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:13.136709+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:14.136912+00:00,0.016,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:15.137083+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:16.137766+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:17.137927+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:18.138084+00:00,0.019,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:19.138904+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:20.139040+00:00,0.026,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:21.139230+00:00,0.029,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:22.139429+00:00,0.034,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:23.139587+00:00,0.027,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:24.139767+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:25.139948+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:26.140101+00:00,0.016,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:27.140245+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:28.140440+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:29.140639+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:30.140791+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:31.140900+00:00,0.019,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:32.141041+00:00,0.061,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:33.142682+00:00,0.05,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:34.142833+00:00,0.02,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:35.143010+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:36.143157+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:37.143306+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:38.143486+00:00,0.021,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:39.143641+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:40.143874+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:41.144021+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:42.144204+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:43.144375+00:00,0.016,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:44.144553+00:00,0.019,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:45.144709+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:46.145242+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:47.145402+00:00,0.019,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:48.145616+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:49.145796+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:50.145913+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:51.146685+00:00,0.036,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:52.146810+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:53.147072+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:54.147286+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:55.147485+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:56.147685+00:00,0.031,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:57.148323+00:00,0.038,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:58.148530+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:27:59.148735+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:00.148937+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:01.149163+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:02.149317+00:00,0.033,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:03.149558+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:04.149722+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:05.149941+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:06.150093+00:00,0.016,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:07.150315+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:08.150536+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:09.150760+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:10.150901+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:11.151119+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:12.151328+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:13.151538+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:14.151770+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:15.151980+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:16.152168+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:17.152759+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:18.152957+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:19.153184+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:20.153417+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:21.153665+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:22.153905+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:23.154099+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:24.154248+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:25.154405+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:26.154589+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:27.154747+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:28.154927+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:29.155137+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:30.155288+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:31.155468+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:32.155669+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:33.155867+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:34.156086+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:35.156247+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:36.156410+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:37.156609+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:38.156929+00:00,0.03,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:39.157913+00:00,0.025,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:40.158912+00:00,0.024,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:41.159054+00:00,0.033,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:42.160045+00:00,0.03,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:43.160368+00:00,0.038,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:44.160556+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:45.160776+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:46.161003+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:47.162156+00:00,0.025,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:48.162385+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:49.162579+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:50.163124+00:00,0.025,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:51.163318+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:52.164488+00:00,0.035,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:53.165348+00:00,0.026,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:54.165863+00:00,0.028,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:55.165991+00:00,0.048,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:56.166900+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:57.167057+00:00,0.025,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:58.167919+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:28:59.168103+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:00.169028+00:00,0.04,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:01.169191+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:02.169337+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:03.169719+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:04.169921+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:05.170115+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:06.170319+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:07.171513+00:00,0.026,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:08.171689+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:09.172906+00:00,0.02,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:10.173911+00:00,0.021,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:11.174067+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:12.174647+00:00,0.024,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:13.175115+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:14.175313+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:15.176154+00:00,0.031,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:16.176323+00:00,0.024,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:17.177942+00:00,0.022,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:18.178137+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:19.178288+00:00,0.029,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:20.178911+00:00,0.03,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:21.179309+00:00,0.068,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:22.180080+00:00,0.029,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:23.180337+00:00,0.017,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:24.180511+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:25.180987+00:00,0.018,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:26.181730+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:27.181931+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:28.182677+00:00,0.023,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:29.182841+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:30.183799+00:00,0.029,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:31.183973+00:00,0.016,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:32.184660+00:00,0.032,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:33.185920+00:00,0.05,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:34.186061+00:00,0.07,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:35.186246+00:00,0.037,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:36.186432+00:00,0.013,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:37.186616+00:00,0.015,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:38.186772+00:00,0.016,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:39.186918+00:00,0.014,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:40.187054+00:00,0.012,502,,,HTTPError
|
||||||
|
2026-11-16T04:29:41.187224+00:00,2.018,,,,TimeoutError
|
||||||
|
2026-11-16T04:29:43.205246+00:00,1.718,200,ok,v2,
|
||||||
|
2026-11-16T04:29:44.924453+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:29:45.924601+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:29:46.924917+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:29:47.925891+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:29:48.927611+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:29:49.927750+00:00,0.035,200,ok,v2,
|
||||||
|
2026-11-16T04:29:50.928213+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:29:51.928341+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:29:52.928956+00:00,0.024,200,ok,v2,
|
||||||
|
2026-11-16T04:29:53.929395+00:00,0.047,200,ok,v2,
|
||||||
|
2026-11-16T04:29:54.931730+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:29:55.932346+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:29:56.933925+00:00,0.087,200,ok,v2,
|
||||||
|
2026-11-16T04:29:57.934953+00:00,0.09,200,ok,v2,
|
||||||
|
2026-11-16T04:29:58.935909+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:29:59.937797+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:30:00.938504+00:00,0.122,200,ok,v2,
|
||||||
|
2026-11-16T04:30:01.939919+00:00,0.089,200,ok,v2,
|
||||||
|
2026-11-16T04:30:02.943776+00:00,0.194,200,ok,v2,
|
||||||
|
2026-11-16T04:30:03.944373+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:30:04.945023+00:00,0.044,200,ok,v2,
|
||||||
|
2026-11-16T04:30:05.945906+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:30:06.946097+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:30:07.946917+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:30:08.948910+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:30:09.949744+00:00,0.067,200,ok,v2,
|
||||||
|
2026-11-16T04:30:10.950713+00:00,0.076,200,ok,v2,
|
||||||
|
2026-11-16T04:30:11.952916+00:00,0.055,200,ok,v2,
|
||||||
|
2026-11-16T04:30:12.953919+00:00,0.07,200,ok,v2,
|
||||||
|
2026-11-16T04:30:13.955288+00:00,0.043,200,ok,v2,
|
||||||
|
2026-11-16T04:30:14.955452+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:30:15.956921+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:30:16.957914+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:30:17.958455+00:00,0.031,200,ok,v2,
|
||||||
|
2026-11-16T04:30:18.958621+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:30:19.958872+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:30:20.959049+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:30:21.959206+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:30:22.959650+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:30:23.961158+00:00,0.064,200,ok,v2,
|
||||||
|
2026-11-16T04:30:24.961906+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:30:25.962841+00:00,0.099,200,ok,v2,
|
||||||
|
2026-11-16T04:30:26.963621+00:00,0.088,200,ok,v2,
|
||||||
|
2026-11-16T04:30:27.963785+00:00,0.077,200,ok,v2,
|
||||||
|
2026-11-16T04:30:28.964870+00:00,0.046,200,ok,v2,
|
||||||
|
2026-11-16T04:30:29.965618+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:30:30.965765+00:00,0.06,200,ok,v2,
|
||||||
|
2026-11-16T04:30:31.966719+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:30:32.967184+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:30:33.967429+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:30:34.975003+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:30:35.975195+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:30:36.975368+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:30:37.975932+00:00,0.056,200,ok,v2,
|
||||||
|
2026-11-16T04:30:38.977572+00:00,0.04,200,ok,v2,
|
||||||
|
2026-11-16T04:30:39.978506+00:00,0.047,200,ok,v2,
|
||||||
|
2026-11-16T04:30:40.979240+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:30:41.979896+00:00,0.064,200,ok,v2,
|
||||||
|
2026-11-16T04:30:42.980771+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:30:43.980952+00:00,0.068,200,ok,v2,
|
||||||
|
2026-11-16T04:30:44.982904+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:30:45.983450+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:30:46.983583+00:00,0.044,200,ok,v2,
|
||||||
|
2026-11-16T04:30:47.983770+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:30:48.983937+00:00,0.029,200,ok,v2,
|
||||||
|
2026-11-16T04:30:49.984333+00:00,0.055,200,ok,v2,
|
||||||
|
2026-11-16T04:30:50.984895+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:30:51.986016+00:00,0.072,200,ok,v2,
|
||||||
|
2026-11-16T04:30:52.986136+00:00,0.034,200,ok,v2,
|
||||||
|
2026-11-16T04:30:53.986390+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:30:54.986945+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:30:55.988921+00:00,0.033,200,ok,v2,
|
||||||
|
2026-11-16T04:30:56.990937+00:00,0.067,200,ok,v2,
|
||||||
|
2026-11-16T04:30:57.991954+00:00,0.07,200,ok,v2,
|
||||||
|
2026-11-16T04:30:58.992119+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:30:59.992369+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:31:00.992606+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:31:01.992892+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:31:02.993085+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:31:03.993542+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:31:04.993777+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:31:05.994843+00:00,0.024,200,ok,v2,
|
||||||
|
2026-11-16T04:31:06.995098+00:00,0.045,200,ok,v2,
|
||||||
|
2026-11-16T04:31:07.995323+00:00,0.026,200,ok,v2,
|
||||||
|
2026-11-16T04:31:08.995912+00:00,0.061,200,ok,v2,
|
||||||
|
2026-11-16T04:31:09.996925+00:00,0.046,200,ok,v2,
|
||||||
|
2026-11-16T04:31:10.997908+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:31:11.999900+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:31:13.000075+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:31:14.000289+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:31:15.000530+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:31:16.000712+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:31:17.000921+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:31:18.001136+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:31:19.001404+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:31:20.001570+00:00,0.042,200,ok,v2,
|
||||||
|
2026-11-16T04:31:21.001766+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:31:22.001910+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:31:23.003935+00:00,0.027,200,ok,v2,
|
||||||
|
2026-11-16T04:31:24.004936+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:31:25.005922+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:31:26.006100+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:31:27.006440+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:31:28.006700+00:00,0.03,200,ok,v2,
|
||||||
|
2026-11-16T04:31:29.008091+00:00,0.022,200,ok,v2,
|
||||||
|
2026-11-16T04:31:30.008260+00:00,0.025,200,ok,v2,
|
||||||
|
2026-11-16T04:31:31.008483+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:31:32.011981+00:00,0.023,200,ok,v2,
|
||||||
|
2026-11-16T04:31:33.012937+00:00,0.049,200,ok,v2,
|
||||||
|
2026-11-16T04:31:34.013948+00:00,0.101,200,ok,v2,
|
||||||
|
2026-11-16T04:31:35.014924+00:00,0.039,200,ok,v2,
|
||||||
|
2026-11-16T04:31:36.015929+00:00,0.038,200,ok,v2,
|
||||||
|
2026-11-16T04:31:37.016084+00:00,0.037,200,ok,v2,
|
||||||
|
2026-11-16T04:31:38.016554+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:31:39.016756+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:31:40.016993+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:31:41.017215+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:31:42.018155+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:31:43.018358+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:31:44.018534+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:31:45.018770+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:31:46.018943+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:31:47.019173+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:31:48.020924+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:31:49.021916+00:00,0.028,200,ok,v2,
|
||||||
|
2026-11-16T04:31:50.022771+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:31:51.023115+00:00,0.013,200,ok,v2,
|
||||||
|
2026-11-16T04:31:52.023336+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:31:53.023556+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:31:54.023722+00:00,0.036,200,ok,v2,
|
||||||
|
2026-11-16T04:31:55.024195+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:31:56.024507+00:00,0.016,200,ok,v2,
|
||||||
|
2026-11-16T04:31:57.024694+00:00,0.018,200,ok,v2,
|
||||||
|
2026-11-16T04:31:58.024905+00:00,0.014,200,ok,v2,
|
||||||
|
2026-11-16T04:31:59.025118+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:32:00.025787+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:32:01.026749+00:00,0.032,200,ok,v2,
|
||||||
|
2026-11-16T04:32:02.027922+00:00,0.091,200,ok,v2,
|
||||||
|
2026-11-16T04:32:03.028074+00:00,0.101,200,ok,v2,
|
||||||
|
2026-11-16T04:32:04.029934+00:00,0.041,200,ok,v2,
|
||||||
|
2026-11-16T04:32:05.030110+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:32:06.030283+00:00,0.015,200,ok,v2,
|
||||||
|
2026-11-16T04:32:07.030462+00:00,0.02,200,ok,v2,
|
||||||
|
2026-11-16T04:32:08.030648+00:00,0.017,200,ok,v2,
|
||||||
|
2026-11-16T04:32:09.030871+00:00,0.021,200,ok,v2,
|
||||||
|
2026-11-16T04:32:10.031072+00:00,0.019,200,ok,v2,
|
||||||
|
2026-11-16T04:32:11.031289+00:00,0.017,200,ok,v2,
|
||||||
|
@@ -0,0 +1,74 @@
|
|||||||
|
# Staging deployment, blocked rerun and health-timeout trial
|
||||||
|
|
||||||
|
Client date: 15 November 2026 (Eastern). Execution timestamps below are
|
||||||
|
16 November UTC. Billy approved PR 25 at 01:46:19 UTC; Vincent merged it at
|
||||||
|
01:51:04 as `a19fab34e39420811e73f91fcfbb82ee598bd74a`.
|
||||||
|
|
||||||
|
[Pricing build 4](https://ci.yebilly.me/job/secure-delivery/job/pricing/4/)
|
||||||
|
selected that full source/configuration commit. It began 02:00:09.554 UTC,
|
||||||
|
took 198.101 seconds and finished FAILURE. Twelve control tests, three app
|
||||||
|
tests, source/dependency gates and both image gates passed. The published image was:
|
||||||
|
|
||||||
|
```text
|
||||||
|
git.yebilly.me/ssw590-group1/pricing@sha256:63e2e3d49a5119b1064868b0b15b39a1719a60a632ff0ecdc3f676fcdc55de3b
|
||||||
|
```
|
||||||
|
|
||||||
|
The noninteractive SSH correction worked. Initial staging deployment ran
|
||||||
|
02:01:48.628–02:02:58.341 UTC (69.713 seconds) and passed all HTTPS health,
|
||||||
|
version, source-SHA and quantity=3 total=30 assertions. Its recap was
|
||||||
|
`ok=10 changed=4 unreachable=0 failed=0`.
|
||||||
|
|
||||||
|
The unchanged rerun ran 02:03:01.314–02:03:25.201 UTC (23.887 seconds).
|
||||||
|
Directory/template checks were unchanged, but Compose stopped because the
|
||||||
|
existing container was unhealthy: `ok=4 changed=0 unreachable=0 failed=1`.
|
||||||
|
This is **not** a passed idempotence gate. Jenkins skipped production approval
|
||||||
|
and deployment. All reports are archived in build 4 and copied to ignored
|
||||||
|
`build/evidence/assignment8-execution/jenkins-4/`. These records are not
|
||||||
|
known-good rollback selections in `delivery/releases/`.
|
||||||
|
|
||||||
|
## Diagnosis
|
||||||
|
|
||||||
|
Docker reported `Health check exceeded timeout (3s)`. Its recorded probe
|
||||||
|
durations were near three seconds, including successful probes. The staging
|
||||||
|
container later recovered without a restart; an HTTPS health request returned
|
||||||
|
`{"status":"ok","version":"v1"}`. Gunicorn remained running. The observed
|
||||||
|
container had no OOM kill, about 48.56 MiB usage against 64 MiB, and memory-limit
|
||||||
|
events without OOM events. CPU quota is 0.25. This supports a probe deadline
|
||||||
|
problem under these constraints; it does not establish that every later health
|
||||||
|
failure has that cause.
|
||||||
|
|
||||||
|
## Bounded diagnostic of the correction
|
||||||
|
|
||||||
|
At 02:06:37–02:08:24 UTC a temporary container ran the **same reviewed image**
|
||||||
|
with the same UID, read-only filesystem, capability restrictions, 64/96 MiB
|
||||||
|
RAM/RAM+swap, 0.25 CPU and 64 PID cap. It had no Docker network, published port,
|
||||||
|
proxy alias, deployment directory or app data volume. Only Docker's overall
|
||||||
|
health timeout was overridden to ten seconds. The HTTP request timeout remained
|
||||||
|
two seconds. Existing staging and shared services were unchanged.
|
||||||
|
|
||||||
|
Eight consecutive probes passed, taking 5.660, 3.183, 3.109, 2.905, 2.999,
|
||||||
|
3.183, 3.698 and 2.817 seconds. The final state was healthy; memory events
|
||||||
|
showed no limit hit or OOM. CPU throttling was observed. The temporary container
|
||||||
|
was removed by its exact newly created ID in a finally block. The
|
||||||
|
[exact diagnostic script](health-timeout-trial-20261115.py) and
|
||||||
|
[raw JSON](health-timeout-trial-20261115.json) preserve the experiment.
|
||||||
|
|
||||||
|
The Dockerfile correction changes only the overall health-check timeout from
|
||||||
|
three to ten seconds. It keeps the endpoint, request timeout, retry count,
|
||||||
|
cadence, startup period and all resource/security limits. It still needs review
|
||||||
|
and a successful assessed release; this diagnostic did not deploy production.
|
||||||
|
|
||||||
|
## v1 and v2 review sequence
|
||||||
|
|
||||||
|
The branch also prepares the required v2 source/test change: VERSION=v2,
|
||||||
|
UNIT_PRICE=12, quantity 3 total=36. Three local functional tests and twelve
|
||||||
|
control tests passed. The Windows functional environment used Flask 3.1.3 and
|
||||||
|
Werkzeug 3.1.8; deployment remains locked to Werkzeug 3.1.9 and must pass the
|
||||||
|
real Jenkins gates. Docker Desktop was not running; the remote runners remain
|
||||||
|
independent of it.
|
||||||
|
|
||||||
|
Keep two commits: first the health fix with v1 source, then the v2 app/test
|
||||||
|
change. Review both in one PR and merge with a merge commit, preserving their
|
||||||
|
SHAs. Run v1 with the first reviewed commit and v2 with the second; each still
|
||||||
|
requires staging/idempotence and real human production approval. Save and
|
||||||
|
review the actual successful release records before either recovery exercise.
|
||||||
@@ -0,0 +1,202 @@
|
|||||||
|
{
|
||||||
|
"releases": [
|
||||||
|
{
|
||||||
|
"version": "v1",
|
||||||
|
"build": 5,
|
||||||
|
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||||
|
"result": "SUCCESS",
|
||||||
|
"source": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"started": "2026-11-16T03:00:10.966000+00:00",
|
||||||
|
"completed": "2026-11-16T03:05:08.180000+00:00",
|
||||||
|
"total_seconds": 297.214,
|
||||||
|
"approval": {
|
||||||
|
"Approver": "vsun1",
|
||||||
|
"Decision": "approved",
|
||||||
|
"UTC": "2026-11-16T03:04:01Z"
|
||||||
|
},
|
||||||
|
"deployments": {
|
||||||
|
"staging-deploy": {
|
||||||
|
"started": "2026-11-16T03:01:27.245015+00:00",
|
||||||
|
"completed": "2026-11-16T03:02:26.405414+00:00",
|
||||||
|
"elapsed_seconds": 59.16,
|
||||||
|
"operation": "deploy",
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 3,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"staging-rerun": {
|
||||||
|
"started": "2026-11-16T03:02:29.440969+00:00",
|
||||||
|
"completed": "2026-11-16T03:03:10.939985+00:00",
|
||||||
|
"elapsed_seconds": 41.499,
|
||||||
|
"operation": "rerun",
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 0,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"production-deploy": {
|
||||||
|
"started": "2026-11-16T03:04:05.207821+00:00",
|
||||||
|
"completed": "2026-11-16T03:05:05.610689+00:00",
|
||||||
|
"elapsed_seconds": 60.403,
|
||||||
|
"operation": "deploy",
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 4,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"scans": {
|
||||||
|
"image-gate": {
|
||||||
|
"analyzed_targets": 2,
|
||||||
|
"high_critical": 0,
|
||||||
|
"report_sha256": "55ca73c4b493fa7a612671e02e6cf097c0b3fc011895712189704c8721b9028e"
|
||||||
|
},
|
||||||
|
"published-image-gate": {
|
||||||
|
"analyzed_targets": 2,
|
||||||
|
"high_critical": 0,
|
||||||
|
"report_sha256": "f375643ae8f6888e9f5ab582342c4d11bee8563936c86a9de08e7b7b5cd52ef8"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"packages": 9,
|
||||||
|
"advisories": 0
|
||||||
|
},
|
||||||
|
"source_secrets": {
|
||||||
|
"findings": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unit_tests": {
|
||||||
|
"started": "2026-11-16T03:00:34.908112+00:00",
|
||||||
|
"completed": "2026-11-16T03:00:35.815417+00:00",
|
||||||
|
"exit_code": 0,
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||||
|
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"records": [
|
||||||
|
"delivery/releases/v1-staging.json",
|
||||||
|
"delivery/releases/v1-production.json"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"version": "v2",
|
||||||
|
"build": 6,
|
||||||
|
"url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||||
|
"result": "SUCCESS",
|
||||||
|
"source": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"started": "2026-11-16T03:05:33.456000+00:00",
|
||||||
|
"completed": "2026-11-16T03:12:29.163000+00:00",
|
||||||
|
"total_seconds": 415.707,
|
||||||
|
"approval": {
|
||||||
|
"Approver": "vsun1",
|
||||||
|
"Decision": "approved",
|
||||||
|
"UTC": "2026-11-16T03:11:18Z"
|
||||||
|
},
|
||||||
|
"deployments": {
|
||||||
|
"staging-deploy": {
|
||||||
|
"started": "2026-11-16T03:06:46.416545+00:00",
|
||||||
|
"completed": "2026-11-16T03:07:46.522813+00:00",
|
||||||
|
"elapsed_seconds": 60.106,
|
||||||
|
"operation": "deploy",
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 3,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"staging-rerun": {
|
||||||
|
"started": "2026-11-16T03:07:49.044973+00:00",
|
||||||
|
"completed": "2026-11-16T03:08:34.532184+00:00",
|
||||||
|
"elapsed_seconds": 45.487,
|
||||||
|
"operation": "rerun",
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 0,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"production-deploy": {
|
||||||
|
"started": "2026-11-16T03:11:21.802336+00:00",
|
||||||
|
"completed": "2026-11-16T03:12:28.036700+00:00",
|
||||||
|
"elapsed_seconds": 66.234,
|
||||||
|
"operation": "deploy",
|
||||||
|
"ansible_exit_code": 0,
|
||||||
|
"recaps": [
|
||||||
|
{
|
||||||
|
"host": "startup",
|
||||||
|
"ok": 10,
|
||||||
|
"changed": 3,
|
||||||
|
"unreachable": 0,
|
||||||
|
"failed": 0
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"result": "passed"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"scans": {
|
||||||
|
"image-gate": {
|
||||||
|
"analyzed_targets": 2,
|
||||||
|
"high_critical": 0,
|
||||||
|
"report_sha256": "89d8912330a8fdfb0e5e8ccd1e41f971415c611ba80ee2dd6d484401ec2f6a09"
|
||||||
|
},
|
||||||
|
"published-image-gate": {
|
||||||
|
"analyzed_targets": 2,
|
||||||
|
"high_critical": 0,
|
||||||
|
"report_sha256": "32562513adffdd78782417083b51e56fd29f758a3e050faeda147dee822bc339"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"packages": 9,
|
||||||
|
"advisories": 0
|
||||||
|
},
|
||||||
|
"source_secrets": {
|
||||||
|
"findings": 0
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unit_tests": {
|
||||||
|
"started": "2026-11-16T03:05:54.830225+00:00",
|
||||||
|
"completed": "2026-11-16T03:05:55.609726+00:00",
|
||||||
|
"exit_code": 0,
|
||||||
|
"result": "passed"
|
||||||
|
},
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"records": [
|
||||||
|
"delivery/releases/v2-staging.json",
|
||||||
|
"delivery/releases/v2-production.json"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -0,0 +1,85 @@
|
|||||||
|
# Reviewed v1/v2 releases and production monitoring
|
||||||
|
|
||||||
|
Client date: 15 November 2026 Eastern; all times below are 16 November UTC.
|
||||||
|
Billy approved PR 26 at 02:56:00; Vincent merged it at 02:57:42 as
|
||||||
|
`231d11528a425114a8d3570afba56943c4d57d96`, preserving both source commits.
|
||||||
|
The merge-triggered manual workflow 15 passed in 2m7s before delivery began.
|
||||||
|
|
||||||
|
| Evidence | v1 | v2 |
|
||||||
|
|---|---|---|
|
||||||
|
| Source and configuration | `34f26e6948b7001ede8ca19f23b67a02082e6a9a` | `6bddbfba5a36e0e397537678ffb197e101fb0670` |
|
||||||
|
| Jenkins | [Build 5 SUCCESS](https://ci.yebilly.me/job/secure-delivery/job/pricing/5/) | [Build 6 SUCCESS](https://ci.yebilly.me/job/secure-delivery/job/pricing/6/) |
|
||||||
|
| Full run, including human wait | 03:00:10.966–03:05:08.180; 297.214 s | 03:05:33.456–03:12:29.163; 415.707 s |
|
||||||
|
| Initial staging | 59.160 s; ok=10, changed=3, failed=0 | 60.106 s; ok=10, changed=3, failed=0 |
|
||||||
|
| Unchanged staging rerun | 41.499 s; ok=10, changed=0, failed=0 | 45.487 s; ok=10, changed=0, failed=0 |
|
||||||
|
| Actual human approval | `vsun1`, 03:04:01 | `vsun1`, 03:11:18 |
|
||||||
|
| Production deployment | 03:04:05.208–03:05:05.611; 60.403 s | 03:11:21.802–03:12:28.037; 66.234 s |
|
||||||
|
| Verified quantity 3 total | USD 30 in both environments | USD 36 in both environments |
|
||||||
|
|
||||||
|
Both runs passed twelve control tests and three Flask tests, clean-source
|
||||||
|
scanning, all nine locked dependency audits (zero advisories), and pre-push and
|
||||||
|
registry-digest image gates (two analyzed targets, zero HIGH/CRITICAL findings).
|
||||||
|
No exception was added. Each source-SHA image was built once, pushed, pulled
|
||||||
|
and promoted by the same exact digest across staging and production.
|
||||||
|
|
||||||
|
Repository: `git.yebilly.me/ssw590-group1/pricing`
|
||||||
|
|
||||||
|
```text
|
||||||
|
v1 sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8
|
||||||
|
v2 sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b
|
||||||
|
```
|
||||||
|
|
||||||
|
The four selectors in `delivery/releases/` are copied unchanged from these
|
||||||
|
successful Jenkins builds. They include the real source/configuration SHAs,
|
||||||
|
digest, environment, expected version/total, build URL and creation time.
|
||||||
|
They pass `release.py verify` and need review/commit before recovery. Earlier
|
||||||
|
failed-attempt records were not substituted. Full reports and actual approval
|
||||||
|
records remain archived in Jenkins; exact local copies are retained in ignored
|
||||||
|
`build/evidence/assignment8-execution/jenkins-{5,6}/`.
|
||||||
|
[Machine-readable summary](releases-20261115.json) includes recaps, timestamps,
|
||||||
|
scan counts and full image-report SHA-256 hashes.
|
||||||
|
|
||||||
|
## Production monitoring, applied only after healthy v1
|
||||||
|
|
||||||
|
At 03:08:11 the previously reviewed production `/health` target and panel 8
|
||||||
|
were applied. The guarded helper required healthy production, compared earlier
|
||||||
|
probes/panels, validated the candidate with installed promtool, saved protected
|
||||||
|
backups and preserved both bind-mounted file inodes. Prometheus reloaded via
|
||||||
|
SIGHUP; Grafana provisioned the changed file. No container, volume, retention,
|
||||||
|
allowlist, credential or existing alert rule was replaced. The first dry-run
|
||||||
|
cleanup needed root inside Prometheus because docker cp created a root-owned
|
||||||
|
temporary file; that was corrected before active application.
|
||||||
|
|
||||||
|
[Applied metadata](monitoring-applied-20261115.json) records hashes and backup
|
||||||
|
`/root/ssw590-delivery-bootstrap/monitoring-20261116/`.
|
||||||
|
[Actual samples and targets](monitoring-runtime-20261115.json), observed at
|
||||||
|
03:14:11, showed production, Gitea and Jenkins probe_success=1, all six scrape
|
||||||
|
targets up and successful reload=1. The dashboard source retained its previous
|
||||||
|
seven panels; the actual Grafana UI also displayed the new pricing panel and
|
||||||
|
its data. A legacy SQL dashboard lookup returned no row, so it was not used
|
||||||
|
as proof of provisioning.
|
||||||
|
|
||||||
|
Prometheus supports [runtime SIGHUP reload](https://prometheus.io/docs/prometheus/latest/configuration/configuration/).
|
||||||
|
Grafana's [file provisioning](https://grafana.com/docs/grafana/latest/administration/provisioning/)
|
||||||
|
detects dashboard changes; visible runtime verification was performed separately.
|
||||||
|
|
||||||
|
## Observed availability during v2 promotion
|
||||||
|
|
||||||
|
The [post-release capture](runtime-20261115.json) at 03:28:08 verified both
|
||||||
|
environments as healthy v2 with the exact source SHA, HTTP 200 for identity,
|
||||||
|
health and total 36, and HTTP 400 for quantity 0. Both containers had zero OOM
|
||||||
|
events and no observed memory-limit events in that capture.
|
||||||
|
|
||||||
|
The production probe history contains one failed sample at **03:11:54.602**
|
||||||
|
during v2's 03:11:21.802–03:12:28.037 deployment window. Adjacent successful
|
||||||
|
samples were 03:11:24.602 and 03:12:24.602. The capture preserves exact HTTP
|
||||||
|
status and duration samples. A single failed 30-second-cadence sample does
|
||||||
|
not establish an exact 30-second outage or zero downtime between other samples.
|
||||||
|
The interval is shorter than the existing one-minute alert duration; no alert
|
||||||
|
firing or notification is claimed without separate evidence. The single-host
|
||||||
|
Compose replacement is not blue/green or highly available deployment.
|
||||||
|
|
||||||
|
The Grafana screenshot is retained in the manual's image folder. Production
|
||||||
|
rollback and deliberate staging failure/recovery remain **unexecuted** pending
|
||||||
|
review of the successful records and preserved staging-only configuration fault.
|
||||||
|
See [the recovery exercise instructions](../exercises/README.md).
|
||||||
@@ -0,0 +1,604 @@
|
|||||||
|
{
|
||||||
|
"observed_at": "2026-11-16T03:28:08.004273+00:00",
|
||||||
|
"endpoints": {
|
||||||
|
"staging": [
|
||||||
|
{
|
||||||
|
"path": "/",
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"service": "Startup Pricing",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/health",
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/price?quantity=3",
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"currency": "USD",
|
||||||
|
"quantity": 3,
|
||||||
|
"total": 36
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/price?quantity=0",
|
||||||
|
"http_status": 400,
|
||||||
|
"body": {
|
||||||
|
"error": "quantity must be between 1 and 1000"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"production": [
|
||||||
|
{
|
||||||
|
"path": "/",
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"service": "Startup Pricing",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/health",
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"status": "ok",
|
||||||
|
"version": "v2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/price?quantity=3",
|
||||||
|
"http_status": 200,
|
||||||
|
"body": {
|
||||||
|
"currency": "USD",
|
||||||
|
"quantity": 3,
|
||||||
|
"total": 36
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "/price?quantity=0",
|
||||||
|
"http_status": 400,
|
||||||
|
"body": {
|
||||||
|
"error": "quantity must be between 1 and 1000"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"containers": {
|
||||||
|
"staging": {
|
||||||
|
"running": true,
|
||||||
|
"oom_killed": false,
|
||||||
|
"health": "healthy",
|
||||||
|
"memory_events": "low 0\nhigh 0\nmax 0\noom 0\noom_kill 0\noom_group_kill 0\n"
|
||||||
|
},
|
||||||
|
"production": {
|
||||||
|
"running": true,
|
||||||
|
"oom_killed": false,
|
||||||
|
"health": "healthy",
|
||||||
|
"memory_events": "low 0\nhigh 0\nmax 0\noom 0\noom_kill 0\noom_group_kill 0\n"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"monitoring_samples": {
|
||||||
|
"probe_success": [
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "probe_success",
|
||||||
|
"instance": "https://app.yebilly.me/health",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"values": [
|
||||||
|
[
|
||||||
|
1794798504.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798534.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798564.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798594.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798624.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798654.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798684.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798714.602,
|
||||||
|
"0"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798744.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798774.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798804.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798834.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798864.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798894.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798924.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798954.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798984.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799014.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799044.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799074.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799104.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799134.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799164.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799194.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799224.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799254.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799284.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799314.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799344.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799374.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799404.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799434.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799464.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799494.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799524.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799554.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799584.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799614.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799644.602,
|
||||||
|
"1"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799674.602,
|
||||||
|
"1"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"probe_http_status_code": [
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "probe_http_status_code",
|
||||||
|
"instance": "https://app.yebilly.me/health",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"values": [
|
||||||
|
[
|
||||||
|
1794798504.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798534.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798564.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798594.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798624.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798654.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798684.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798714.602,
|
||||||
|
"502"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798744.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798774.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798804.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798834.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798864.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798894.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798924.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798954.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798984.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799014.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799044.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799074.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799104.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799134.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799164.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799194.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799224.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799254.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799284.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799314.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799344.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799374.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799404.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799434.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799464.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799494.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799524.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799554.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799584.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799614.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799644.602,
|
||||||
|
"200"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799674.602,
|
||||||
|
"200"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"probe_duration_seconds": [
|
||||||
|
{
|
||||||
|
"metric": {
|
||||||
|
"__name__": "probe_duration_seconds",
|
||||||
|
"instance": "https://app.yebilly.me/health",
|
||||||
|
"job": "https"
|
||||||
|
},
|
||||||
|
"values": [
|
||||||
|
[
|
||||||
|
1794798504.602,
|
||||||
|
"0.057399797"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798534.602,
|
||||||
|
"0.028300941"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798564.602,
|
||||||
|
"0.023132207"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798594.602,
|
||||||
|
"0.021246711"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798624.602,
|
||||||
|
"0.023551593"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798654.602,
|
||||||
|
"0.023607454"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798684.602,
|
||||||
|
"0.182590187"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798714.602,
|
||||||
|
"0.080492206"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798744.602,
|
||||||
|
"0.048286408"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798774.602,
|
||||||
|
"0.021541103"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798804.602,
|
||||||
|
"0.082225976"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798834.602,
|
||||||
|
"0.026266413"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798864.602,
|
||||||
|
"0.021229488"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798894.602,
|
||||||
|
"0.026039405"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798924.602,
|
||||||
|
"0.024995092"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798954.602,
|
||||||
|
"0.026780972"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794798984.602,
|
||||||
|
"0.022616423"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799014.602,
|
||||||
|
"0.079699801"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799044.602,
|
||||||
|
"0.023901787"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799074.602,
|
||||||
|
"0.029992619"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799104.602,
|
||||||
|
"0.022638427"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799134.602,
|
||||||
|
"0.082084913"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799164.602,
|
||||||
|
"0.03257138"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799194.602,
|
||||||
|
"0.028129282"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799224.602,
|
||||||
|
"0.02010407"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799254.602,
|
||||||
|
"0.081311747"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799284.602,
|
||||||
|
"0.027378471"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799314.602,
|
||||||
|
"0.020048075"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799344.602,
|
||||||
|
"0.018652785"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799374.602,
|
||||||
|
"0.019703541"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799404.602,
|
||||||
|
"0.020952708"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799434.602,
|
||||||
|
"0.020200855"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799464.602,
|
||||||
|
"0.081365277"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799494.602,
|
||||||
|
"0.030027777"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799524.602,
|
||||||
|
"0.020230579"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799554.602,
|
||||||
|
"0.028499939"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799584.602,
|
||||||
|
"0.024388546"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799614.602,
|
||||||
|
"0.02259808"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799644.602,
|
||||||
|
"0.030377942"
|
||||||
|
],
|
||||||
|
[
|
||||||
|
1794799674.602,
|
||||||
|
"0.080982268"
|
||||||
|
]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,68 @@
|
|||||||
|
# Reviewed recovery exercises
|
||||||
|
|
||||||
|
V1 and v2 have now completed Jenkins releases 5 and 6 with real human approvals.
|
||||||
|
The four successful records in `../releases/` were reviewed in PR 27.
|
||||||
|
Builds 8–10 completed both exercises; see [results](../evidence/recovery-20261115.md).
|
||||||
|
The commands below remain the reproducible procedure, not a request to repeat
|
||||||
|
the completed fault. Do not use failed attempts' records.
|
||||||
|
|
||||||
|
The patch here is a deliberate **staging-only** configuration fault: Gunicorn
|
||||||
|
binds to 8001 while the unchanged image healthcheck probes 8000. It changes no
|
||||||
|
image, host port, credential, shared service, production command or stored data.
|
||||||
|
The reviewed Jenkins `staging-failure` mode requires a staging record and uses
|
||||||
|
that record's existing v2 digest; it does not publish/rebuild an image.
|
||||||
|
|
||||||
|
## Commit and review sequence
|
||||||
|
|
||||||
|
1. Commit the actual release records, evidence, monitoring helper, manual and
|
||||||
|
this patch while the active template remains correct.
|
||||||
|
2. Apply this patch and commit the one changed template as
|
||||||
|
`Exercise staging-only Gunicorn bind mismatch`.
|
||||||
|
3. Immediately revert that second commit, creating a third commit. The final
|
||||||
|
branch/main template must be good; the bad configuration survives only as
|
||||||
|
a reviewed historical commit selected explicitly by SHA for the exercise.
|
||||||
|
4. Billy reviews all three commits, including the intermediate configuration
|
||||||
|
fault and its restoration. Use a merge commit, preserving history.
|
||||||
|
|
||||||
|
After the first commit, the two configuration commits can be made with:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
git apply delivery/exercises/staging-bind-mismatch.patch
|
||||||
|
git add delivery/ansible/templates/compose.yaml.j2
|
||||||
|
git commit -m "Exercise staging-only Gunicorn bind mismatch"
|
||||||
|
git revert --no-edit HEAD
|
||||||
|
```
|
||||||
|
|
||||||
|
## Execution after review/merge
|
||||||
|
|
||||||
|
First record the planned healthy production rollback decision and start the
|
||||||
|
HTTPS observer. Use `MODE=rollback-production` and
|
||||||
|
`RELEASE_RECORD=delivery/releases/v1-production.json`. The approved operation
|
||||||
|
must restore v1's exact image/configuration, source SHA and total 30. This is
|
||||||
|
an exercise on healthy v2, not a claimed production incident. A real human
|
||||||
|
must approve the Jenkins production input.
|
||||||
|
|
||||||
|
Then start a separate staging observer and select:
|
||||||
|
|
||||||
|
```text
|
||||||
|
MODE=staging-failure
|
||||||
|
RELEASE_RECORD=delivery/releases/v2-staging.json
|
||||||
|
STAGING_FAILURE_CONFIG=<full SHA of the reviewed bind-mismatch commit>
|
||||||
|
```
|
||||||
|
|
||||||
|
The SHA must be the actual preserved intermediate commit, not the final
|
||||||
|
revert or an invented placeholder. Leave SOURCE_COMMIT blank so the job uses
|
||||||
|
reviewed current main for its control code. Compose wait must block within
|
||||||
|
its 90-second bound and stop before production. Preserve that failure.
|
||||||
|
|
||||||
|
Recover with `MODE=recover-staging` and the same good v2 staging record, leaving
|
||||||
|
STAGING_FAILURE_CONFIG blank. It must restore the recorded good configuration,
|
||||||
|
verify source/version/total 36, and pass the unchanged rerun with changed=0.
|
||||||
|
Save decision/start/completion times, recaps, observer samples and monitoring
|
||||||
|
correlation. Samples cannot establish zero interruption between requests.
|
||||||
|
|
||||||
|
Both exercises are complete. The actual fault SHA is
|
||||||
|
`1e23001e7303d14630cfa97c8de36f31f30b81a0`, immediately reverted by
|
||||||
|
`29e580c4613f00a02f44bce0dbcee2fd8fdc83ae`. Main and live staging are good;
|
||||||
|
the fault is selected only by the explicit staging exercise. Production remains
|
||||||
|
v1 after its successful rollback.
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
diff --git a/delivery/ansible/templates/compose.yaml.j2 b/delivery/ansible/templates/compose.yaml.j2
|
||||||
|
--- a/delivery/ansible/templates/compose.yaml.j2
|
||||||
|
+++ b/delivery/ansible/templates/compose.yaml.j2
|
||||||
|
@@ -1,6 +1,9 @@
|
||||||
|
services:
|
||||||
|
app:
|
||||||
|
image: "{{ release_image }}"
|
||||||
|
+{% if target_env == 'staging' %}
|
||||||
|
+ command: ["gunicorn", "--bind", "0.0.0.0:8001", "--workers", "1", "--worker-tmp-dir", "/tmp", "app:app"]
|
||||||
|
+{% endif %}
|
||||||
|
restart: unless-stopped
|
||||||
|
read_only: true
|
||||||
|
tmpfs:
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||||
|
"expected_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"expected_version": "v1",
|
||||||
|
"expected_total": 30,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||||
|
"created_at": "2026-11-16T03:01:23.246375+00:00",
|
||||||
|
"target_env": "production",
|
||||||
|
"public_url": "https://app.yebilly.me"
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:59c880b2704f91668618d9a2ff0bc8fbab0af4239ceb916de261863890ef88d8",
|
||||||
|
"expected_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"configuration_commit": "34f26e6948b7001ede8ca19f23b67a02082e6a9a",
|
||||||
|
"expected_version": "v1",
|
||||||
|
"expected_total": 30,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/5/",
|
||||||
|
"created_at": "2026-11-16T03:01:23.246375+00:00",
|
||||||
|
"target_env": "staging",
|
||||||
|
"public_url": "https://staging.yebilly.me"
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"expected_version": "v2",
|
||||||
|
"expected_total": 36,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||||
|
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||||
|
"target_env": "production",
|
||||||
|
"public_url": "https://app.yebilly.me"
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"release_image": "git.yebilly.me/ssw590-group1/pricing@sha256:efe8658a0adf0854038d58199652030cbd0ef70047a1c6ebc7b09906cf1ec88b",
|
||||||
|
"expected_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"configuration_commit": "6bddbfba5a36e0e397537678ffb197e101fb0670",
|
||||||
|
"expected_version": "v2",
|
||||||
|
"expected_total": 36,
|
||||||
|
"proxy_network": "gitea_web",
|
||||||
|
"build_url": "https://ci.yebilly.me/job/secure-delivery/job/pricing/6/",
|
||||||
|
"created_at": "2026-11-16T03:06:40.913173+00:00",
|
||||||
|
"target_env": "staging",
|
||||||
|
"public_url": "https://staging.yebilly.me"
|
||||||
|
}
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
# Add frozen TikZRefinery baseline and demo build pipeline
|
||||||
|
|
||||||
|
Provide a reproducible C++/Qt workload for the DevOps demonstration by importing
|
||||||
|
TikZRefinery checkpoint `f4e3193d49a98efcf2f16c2aa22d6085ebe70f36`, baseline
|
||||||
|
0.1.4-alpha. Preserve all 435 committed files, attribution and original byte
|
||||||
|
identities, with a Git-blob/SHA-256 verification manifest. Keep upstream version
|
||||||
|
and source identity separate from `1.0.<build>` delivery artifacts.
|
||||||
|
|
||||||
|
Add an artifact-only Jenkins definition and repeatable build helpers for native
|
||||||
|
Qt compilation, eight CTest suites, both LaTeX report editions, Doxygen/Graphviz
|
||||||
|
source extraction, load sampling and a versioned application image archive.
|
||||||
|
Include a Windows packaging helper and bounded, non-root/offscreen package
|
||||||
|
checks. Existing pricing deployments, release/recovery jobs and runner identities
|
||||||
|
are retained. The separate provider-class naming change is not included.
|
||||||
|
|
||||||
|
Validation: fresh Windows and Droplet builds each passed all eight suites;
|
||||||
|
the portable Windows package loaded its bundled provider without the development
|
||||||
|
PATH. Both Windows report editions rebuilt and all 585 rendered pages matched
|
||||||
|
the frozen reports. Cloud report builds resolved all 51 authored figure mappings;
|
||||||
|
source extraction generated 25 class/collaboration graphs. Rehearsal image
|
||||||
|
1.0.1 passed its read-only, network-isolated smoke check; downloaded archive,
|
||||||
|
manifest, configuration and layer hashes were verified.
|
||||||
|
|
||||||
|
These results are command-line rehearsals. After review/merge, configure the
|
||||||
|
separate Jenkins job from protected main with script path `demo/Jenkinsfile`
|
||||||
|
and verify actual SCM checkout, stage/JUnit display, artifact archiving and
|
||||||
|
download. Hold the issue-linked provider rename until that baseline run passes.
|
||||||
|
See `demo/README.md` and `demo/evidence/baseline-20261125.json`.
|
||||||
@@ -0,0 +1,295 @@
|
|||||||
|
# TikZRefinery DevOps demonstration script
|
||||||
|
|
||||||
|
Vincent Sun and Billy Ye | SSW 590 | December 2, 2026
|
||||||
|
|
||||||
|
Plan for **16 minutes of presentation and 4 minutes for questions or delays**.
|
||||||
|
Demonstrate an issue becoming a reviewed source change, a cloud build, automated
|
||||||
|
test results and a versioned application artifact. TikZRefinery supplies the C++/Qt
|
||||||
|
workload; Gitea, Jenkins and Grafana supply the workflow and operational view.
|
||||||
|
|
||||||
|
This is a rehearsal plan. Before the final rehearsal, complete the reviewed
|
||||||
|
baseline Jenkins run and record the actual issue, change, job URL and build number.
|
||||||
|
The proposed provider naming refactor remains a candidate from the senior-project
|
||||||
|
handoff. Prepare its issue/comment and patch only after that baseline succeeds.
|
||||||
|
Zammad is a separate assignment. The unfinished VPN is outside this demonstration.
|
||||||
|
|
||||||
|
## Preparation before the presentation
|
||||||
|
|
||||||
|
Suggested roles: Vincent operates Git, Jenkins and the application; Billy explains
|
||||||
|
configuration and the tool comparison, and performs his own peer review. Agree on
|
||||||
|
the split together and rehearse the handovers. Approval must reflect Billy's actual
|
||||||
|
review, even during the timed demonstration.
|
||||||
|
|
||||||
|
Complete these steps before calling the walkthrough ready:
|
||||||
|
|
||||||
|
- Merge the reviewed security and baseline PRs, preserving both manual records.
|
||||||
|
Their current references are [security PR 30](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/30)
|
||||||
|
and [baseline PR 31](https://git.yebilly.me/ssw590-group1/vpn-dns-gateway/pulls/31).
|
||||||
|
- Configure the separate artifact job to load `demo/Jenkinsfile` from reviewed
|
||||||
|
`main`. Run it once and verify SCM checkout, stage execution, JUnit display,
|
||||||
|
artifact archiving, a downloaded artifact and its provenance/checksum. The
|
||||||
|
existing PR check and the new artifact job are separate checks.
|
||||||
|
- After that baseline passes, agree on the live issue/change and rehearse the
|
||||||
|
feature-branch, review, merge and artifact-build sequence. Reserve the actual
|
||||||
|
demonstration commit/push for the assessed workflow.
|
||||||
|
- Preserve the original snapshot manifest. The current verifier deliberately
|
||||||
|
rejects any changed imported byte. An intentional product increment needs an
|
||||||
|
explicit, tested provenance record for its changed files; do not simply disable
|
||||||
|
verification or continue claiming all files are unchanged from the original.
|
||||||
|
- Record the real demo issue URL, branch, expected behavior, baseline build URL,
|
||||||
|
artifact job URL and last successful fallback build. These values are pending.
|
||||||
|
- Sign in to Gitea, Jenkins and Grafana privately before screen sharing. Check Git
|
||||||
|
authentication beforehand; pause sharing if a password/token prompt appears.
|
||||||
|
- Test HTTPS from the actual classroom network. The cloud workers avoid the
|
||||||
|
laptop-to-Droplet SSH connection that previously failed on school Wi-Fi.
|
||||||
|
- Ensure the trusted agent is online and idle, toolchain images are present and
|
||||||
|
disk/memory headroom is adequate. Avoid overlapping manual and delivery builds
|
||||||
|
on this single-CPU host. Use normal build settings; do not clear shared caches.
|
||||||
|
- Open the issue, source diff, PR, artifact job, Grafana dashboard and artifact
|
||||||
|
output tabs in advance. Use the same build number throughout the presentation.
|
||||||
|
- Keep a completed Jenkins run and its downloaded artifacts available as a
|
||||||
|
clearly labelled fallback. Earlier SSH rehearsals are not Jenkins results.
|
||||||
|
|
||||||
|
The November 25 cloud rehearsal sampled approximately 146 seconds for native
|
||||||
|
build/tests, 75 seconds for reports, 10 seconds for architecture and 49 seconds for
|
||||||
|
the final package. These are sampled phase spans, not a measured Jenkins duration.
|
||||||
|
Measure the real job before accepting this timing plan.
|
||||||
|
|
||||||
|
## Timed walkthrough
|
||||||
|
|
||||||
|
| Time | Lead | Show and do |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| 0:00-1:00 | Vincent | Introduce the application and the issue-to-artifact workflow. |
|
||||||
|
| 1:00-2:00 | Vincent | Select the existing demo issue and post the planned-change comment. |
|
||||||
|
| 2:00-4:00 | Both | Make the agreed meaningful change, inspect the diff, commit/push, then review and merge through Gitea. |
|
||||||
|
| 4:00-4:30 | Vincent | Trigger the artifact job from the reviewed main revision. |
|
||||||
|
| 4:30-6:45 | Billy | Explain configuration while the build runs. |
|
||||||
|
| 6:45-8:45 | Billy | Present the two-tool SWOT chart below. |
|
||||||
|
| 8:45-10:00 | Vincent | Show live stages and cloud CPU/memory observations. |
|
||||||
|
| 10:00-12:00 | Vincent | Show tests, compiled report, versioned image archive and source identity. |
|
||||||
|
| 12:00-13:15 | Billy | Open the source-generated architecture output for the bonus. |
|
||||||
|
| 13:15-14:30 | Vincent | Illustrate the desktop workload using the verified Windows package. |
|
||||||
|
| 14:30-16:00 | Both | Recap traceability, protections and measured limits. |
|
||||||
|
| 16:00-20:00 | Both | Questions and timing reserve. |
|
||||||
|
|
||||||
|
### Opening and issue tracking
|
||||||
|
|
||||||
|
**Vincent:** "TikZRefinery is a desktop editor for a supported subset of TikZ. We
|
||||||
|
use a frozen senior-project checkpoint as the application workload in our DevOps
|
||||||
|
repository. The application's upstream baseline is 0.1.4-alpha. Our delivery
|
||||||
|
artifact has a separate version, so we can trace a build without rewriting the
|
||||||
|
senior project's history."
|
||||||
|
|
||||||
|
"We will follow one issue through a source change, Git review, cloud compilation,
|
||||||
|
automated tests and a packaged result. This lets us explain how the tools work
|
||||||
|
together using a real application."
|
||||||
|
|
||||||
|
Open the agreed existing issue. Show its acceptance criterion and submit a short
|
||||||
|
comment describing the work about to happen and how it will be checked. Prepare
|
||||||
|
the final wording after baseline verification, using the actual agreed change.
|
||||||
|
Read its intent aloud rather than reading every field.
|
||||||
|
|
||||||
|
### Source update and review
|
||||||
|
|
||||||
|
Perform the rehearsed edit after the issue comment. Show the meaningful source
|
||||||
|
diff and explain the effect in one sentence. Run these checks from the demo
|
||||||
|
checkout, then stage only the agreed files:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
git status --short --branch
|
||||||
|
git diff --check
|
||||||
|
git diff --stat
|
||||||
|
```
|
||||||
|
|
||||||
|
Use a commit message that describes the actual change and references the real
|
||||||
|
issue. Push the feature branch using the established Gitea login flow. Keep
|
||||||
|
credentials off screen. Show the pushed commit and PR. Billy reviews it, checks
|
||||||
|
the configured checks and submits his own decision. Vincent merges only after
|
||||||
|
the required approval and successful checks.
|
||||||
|
|
||||||
|
**Billy:** "Gitea keeps the issue, source revision, review and merge connected.
|
||||||
|
The required PR checks protect main. Our artifact job then builds from that
|
||||||
|
reviewed main revision on the trusted cloud worker."
|
||||||
|
|
||||||
|
If review or checks take longer than rehearsed, use the explanation/SWOT slots
|
||||||
|
while waiting. Keep their actual result visible; do not force a merge or present
|
||||||
|
an earlier green result as the current one.
|
||||||
|
|
||||||
|
### Trigger and configuration explanation
|
||||||
|
|
||||||
|
Open the separate artifact job and trigger its normal build after main contains
|
||||||
|
the reviewed increment. Show the build URL and checked-out revision.
|
||||||
|
|
||||||
|
**Vincent:** "The job checks source provenance before compiling. It runs the
|
||||||
|
application tests, builds both LaTeX report editions, extracts diagrams from C++
|
||||||
|
and packages an application image. A failed gate prevents a successful package."
|
||||||
|
|
||||||
|
**Billy:** "We keep the orchestration in source control, so a reviewer can see
|
||||||
|
the build policy alongside the application. The job uses our existing trusted
|
||||||
|
agent. Docker access makes that worker privileged with respect to the host, so
|
||||||
|
unreviewed source does not belong on it."
|
||||||
|
|
||||||
|
Use this configuration tour; explain purpose rather than reading syntax aloud:
|
||||||
|
|
||||||
|
| File | Point to explain |
|
||||||
|
| --- | --- |
|
||||||
|
| `demo/Jenkinsfile` | Reviewed-main ancestry check, named stages, one concurrent build per job, timeout, JUnit and archived artifacts. |
|
||||||
|
| `demo/ci/run-cloud.sh` | Agent-volume path mapping; sequential work; offline, read-only build containers with CPU, RAM and PID limits. The native/report/architecture limit is 768 MiB RAM and 0.75 CPU. |
|
||||||
|
| `demo/toolchain.json` and `demo/ci/toolchain.Dockerfile` | Verified image IDs plus the compiler, Qt, LaTeX, Doxygen and Graphviz environment. Package inventory records what was installed. |
|
||||||
|
| `demo/ci/build-report.sh` | Disposable report build, bibliography/index/reference work and figure-index validation. Historical canonical PDFs remain preserved. |
|
||||||
|
| `demo/ci/package.py` and `demo/ci/application.Dockerfile` | Eight required passing suites, versioned image, real provider module, non-root runtime and bounded headless smoke check. |
|
||||||
|
| `.gitea/workflows/manual.yml` | The existing Actions job builds the cumulative manual on main using `latex-local` and uploads its PDF and diagnostics. Its pinned action revisions make dependencies explicit. |
|
||||||
|
|
||||||
|
### Gitea Actions and Jenkins SWOT comparison
|
||||||
|
|
||||||
|
Use this as the required chart. The tradeoffs describe this group's deployment;
|
||||||
|
they do not claim one tool is universally better.
|
||||||
|
|
||||||
|
| SWOT | Gitea Actions in this project | Jenkins in this project |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| Strengths | Workflow YAML, source history and PDF artifacts are reached from the same Gitea project. The existing manual build is a compact, repeatable use case. | Named stages, test reports and artifacts make the multi-stage Qt/report/package workflow visible. The group also has established release and approval workflows. |
|
||||||
|
| Weaknesses | The workflow depends on the runner label and compiler image being available. Our pinned legacy artifact action needs deliberate compatibility maintenance. | The controller, agents, plugins and Java runtime add maintenance work. The trusted worker's Docker access needs careful separation from unreviewed builds. |
|
||||||
|
| Opportunities | Reuse the manual workflow for other course documents and strengthen source/artifact traceability without adding another control service. | Extend the verified baseline into rehearsed issue-linked increments and retain test, load and provenance records for each release. |
|
||||||
|
| Threats | Runner outages or incompatible action changes can block builds. Overlapping heavy jobs compete for the same Droplet resources. | Runtime/plugin vulnerabilities, resource contention and an incorrectly scoped trusted job can affect the shared host. The team must keep review and runtime updates effective. |
|
||||||
|
|
||||||
|
**Billy:** "We use Actions for the cumulative manual and Jenkins for the richer
|
||||||
|
application workflow. Both delegate work to separately operated workers, so
|
||||||
|
availability, maintenance and trust still belong to us. We compare them using the
|
||||||
|
work we actually operate."
|
||||||
|
|
||||||
|
For the tool mechanics, see the official
|
||||||
|
[Gitea Actions overview](https://docs.gitea.com/usage/actions/overview/) and
|
||||||
|
[Jenkins Pipeline handbook](https://www.jenkins.io/doc/book/pipeline/).
|
||||||
|
The chart's deployment tradeoffs are the group's engineering assessment.
|
||||||
|
|
||||||
|
### Cloud execution and load
|
||||||
|
|
||||||
|
Open [the Group 1 SRE dashboard](https://metrics.yebilly.me/d/group1-sre/group-1-sre)
|
||||||
|
with a time window covering the build. Show Jenkins' executing stage alongside
|
||||||
|
the CPU and available-memory panels. If a panel refresh is too coarse, show the
|
||||||
|
job's per-phase load CSV as additional evidence.
|
||||||
|
|
||||||
|
**Vincent:** "These processes run on The-Ocean, our 2 GiB, single-CPU Droplet.
|
||||||
|
The stage limits bound the build containers while Gitea, Jenkins, monitoring and
|
||||||
|
the earlier applications share the host. We observe CPU and available memory
|
||||||
|
before and during the build, and check available disk for the output."
|
||||||
|
|
||||||
|
"The measurements describe the shared host. Other services and dashboard refresh
|
||||||
|
intervals affect what we see, so we do not attribute every change solely to this
|
||||||
|
job. We keep the actual build times and samples together."
|
||||||
|
|
||||||
|
Do not promise a particular peak or a cold build. Use the real chart and CSV
|
||||||
|
values, units and timestamps; identify cache reuse if it affects the duration.
|
||||||
|
|
||||||
|
### Tests and deployment artifact
|
||||||
|
|
||||||
|
Open the current build's JUnit page. Explain the actual result. The baseline
|
||||||
|
registers eight suites covering the provider contract, core foundations,
|
||||||
|
rectangle/segment display, whole-element movement, rectangle resize, sidebar and
|
||||||
|
session history. Module loading and compatibility checks exercise the real
|
||||||
|
provider. These automated checks do not establish complete interactive acceptance.
|
||||||
|
|
||||||
|
Open the compiled `TikZRefinery-report.pdf` from that build. Then show:
|
||||||
|
|
||||||
|
- `TikZRefinery-1.0.N-linux-image.tar.gz`, using the actual Jenkins build number
|
||||||
|
in place of `N`, and the matching `ssw590-tikzrefinery:1.0.N` image tag.
|
||||||
|
- `delivery-info.json`: actual delivery version, upstream identity, downstream
|
||||||
|
commit, execution kind and image ID.
|
||||||
|
- `SHA256SUMS` and the package verification result.
|
||||||
|
- The same build's test and load records.
|
||||||
|
|
||||||
|
**Vincent:** "Here major and minor identify the delivery line; the final component
|
||||||
|
is the Jenkins build number. This is the required major.minor.changelist format.
|
||||||
|
The metadata connects the artifact to its source and toolchain. SHA-256 checks
|
||||||
|
detect byte changes during transfer; they do not establish authenticity by
|
||||||
|
themselves."
|
||||||
|
|
||||||
|
"The image is a deployable Linux desktop application package with a headless
|
||||||
|
runtime check. It is not a new website. The source is reviewed, the tests passed
|
||||||
|
and the saved image's manifest, configuration and layers were verified."
|
||||||
|
|
||||||
|
Download the small metadata/report files live. Downloading the full image during
|
||||||
|
the timed presentation is optional; its download/checksum procedure must already
|
||||||
|
have passed in the baseline rehearsal. Cite the current build's real results.
|
||||||
|
|
||||||
|
### Source architecture bonus
|
||||||
|
|
||||||
|
Open the current `TikZRefinery-1.0.N-architecture.zip`, extract it and open
|
||||||
|
`html/index.html`. Show one generated provider relationship graph and explain the
|
||||||
|
interface/implementation relationship. The baseline rehearsal produced 25 source
|
||||||
|
graphs; quote the current build's actual count if the increment changes it.
|
||||||
|
|
||||||
|
**Billy:** "Doxygen reads the C++ declarations and Graphviz draws the relationships.
|
||||||
|
These graphs are included with the build output. The separately authored TikZ/UML
|
||||||
|
report diagrams communicate the design; this output supplies source extraction."
|
||||||
|
|
||||||
|
### Windows application illustration
|
||||||
|
|
||||||
|
Use the verified portable Windows package to illustrate the workload. It is a
|
||||||
|
separate Windows baseline build, not the Linux artifact just produced by Jenkins.
|
||||||
|
Keep its `build-info.json` and source identity available if asked.
|
||||||
|
|
||||||
|
Before presenting, copy `demo/tikzrefinery/code/examples/explicit-coordinates/boxes-initial.tex`
|
||||||
|
to an ignored rehearsal folder. Open that copy, move the right rectangle, resize a
|
||||||
|
corner and use session undo/redo. Show how the source pane follows a committed
|
||||||
|
edit. Save only the disposable copy if demonstrating Save.
|
||||||
|
|
||||||
|
**Vincent:** "The application edits existing supported shapes. The rectangle
|
||||||
|
implementation is loaded as a separate module. Creation, folder browsing, plugin
|
||||||
|
updating and an integrated LaTeX/PDF viewer remain planned. Our DevOps workflow
|
||||||
|
builds and tests the implemented subset."
|
||||||
|
|
||||||
|
### Closing and questions
|
||||||
|
|
||||||
|
**Billy:** "We can trace the issue comment to a source change, reviewed main
|
||||||
|
revision, cloud run, automated result and versioned artifact. The configuration
|
||||||
|
and observed resource use explain how that workflow runs on our host."
|
||||||
|
|
||||||
|
**Vincent:** "We preserve failed results and prior artifacts rather than rewriting
|
||||||
|
them. The next increments can use the same review and artifact trail. We have
|
||||||
|
four minutes for questions."
|
||||||
|
|
||||||
|
Useful short answers:
|
||||||
|
|
||||||
|
- **Why two CI tools?** Actions builds the group manual; Jenkins orchestrates the
|
||||||
|
application, report, tests and package with the group's established agent model.
|
||||||
|
- **Does the laptop need Docker during the presentation?** The build workers run
|
||||||
|
on the Droplet. The Windows GUI package runs natively on the laptop.
|
||||||
|
- **What happens when a test fails?** The job stops before successful packaging;
|
||||||
|
Jenkins retains available test results and diagnostics. Inspect that failure.
|
||||||
|
- **Is the Linux GUI running in the browser?** No. The container is checked
|
||||||
|
offscreen; the classroom GUI illustration uses the separate Windows package.
|
||||||
|
- **Why keep two versions?** Upstream identifies the imported application
|
||||||
|
checkpoint; the delivery version identifies an artifact produced by this job.
|
||||||
|
|
||||||
|
## Recovery within the time limit
|
||||||
|
|
||||||
|
| Observed problem | Response |
|
||||||
|
| --- | --- |
|
||||||
|
| Jenkins waits for the agent or another job | Show the queue/agent state, continue the explanation and retain the real timing. Do not start competing heavy jobs. |
|
||||||
|
| Current build fails | Show the failed stage and diagnostics. Use the identified previous successful Jenkins build to explain the later stages, clearly distinguishing both runs. |
|
||||||
|
| Classroom web request returns 403 | Check the actual source network against the approved web allowlist through the established maintenance procedure. Keep authentication and source restrictions enabled. |
|
||||||
|
| Network or artifact download stalls | Show the completed run and pre-downloaded fallback files with their matching build/version. Do not label them as this live run. |
|
||||||
|
| Live review takes longer than planned | Continue the configuration/SWOT explanation. Preserve the real review requirement and use the timing reserve. |
|
||||||
|
| Time reaches 16 minutes | Stop optional GUI detail and additional graphs. Preserve time for questions. |
|
||||||
|
|
||||||
|
## Rubric evidence checklist
|
||||||
|
|
||||||
|
| Assessed area | Visible evidence |
|
||||||
|
| --- | --- |
|
||||||
|
| Issue tracking | Existing issue and newly posted plan comment before the edit. |
|
||||||
|
| Version control | Meaningful diff, purpose-specific commit, push and real review/merge. |
|
||||||
|
| Pipeline trigger | Current artifact build URL and triggering action. |
|
||||||
|
| Build visibility | Native compilation, LaTeX and packaging stage progress. |
|
||||||
|
| Automated tests | Current JUnit pass/fail page. |
|
||||||
|
| Versioned deployment artifact | Current `1.0.N` image archive and provenance. |
|
||||||
|
| Two-tool SWOT | The complete four-row comparison above. |
|
||||||
|
| Configuration | Explain the Jenkins, workflow, Docker and build-script roles. |
|
||||||
|
| Demo quality | Rehearsed handovers, clear source identities and timing. |
|
||||||
|
| Cloud execution | Droplet worker, stage timing and real load observations. |
|
||||||
|
| Architecture bonus | Source-generated graph opened from the current artifact. |
|
||||||
|
|
||||||
|
Assignment source: [Canvas Final Project Demo](https://sit.instructure.com/courses/188774/assignments/703597),
|
||||||
|
checked November 25, 2026. Canvas lists December 2 at 11:59 p.m.; the demonstration
|
||||||
|
itself has a 20-minute limit including questions. The script's speaker split and
|
||||||
|
minute-by-minute allocation are rehearsal choices.
|
||||||
Vendored
+38
@@ -0,0 +1,38 @@
|
|||||||
|
// Separate artifact-only demo job. Keep existing delivery/recovery jobs intact.
|
||||||
|
pipeline {
|
||||||
|
agent { label 'delivery-trusted' }
|
||||||
|
options {
|
||||||
|
disableConcurrentBuilds()
|
||||||
|
timeout(time: 45, unit: 'MINUTES')
|
||||||
|
buildDiscarder(logRotator(numToKeepStr: '10'))
|
||||||
|
}
|
||||||
|
environment { DELIVERY_VERSION = "1.0.${BUILD_NUMBER}" }
|
||||||
|
stages {
|
||||||
|
stage('Verify reviewed source and frozen baseline') {
|
||||||
|
steps {
|
||||||
|
sh 'python3 demo/ci/reset-output.py'
|
||||||
|
sh 'git merge-base --is-ancestor HEAD origin/main'
|
||||||
|
sh 'python3 demo/ci/verify-snapshot.py --require-tracked'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Build application and test provider') {
|
||||||
|
steps { sh 'sh demo/ci/run-cloud.sh native' }
|
||||||
|
}
|
||||||
|
stage('Compile LaTeX reports') {
|
||||||
|
steps { sh 'sh demo/ci/run-cloud.sh report' }
|
||||||
|
}
|
||||||
|
stage('Extract source architecture') {
|
||||||
|
steps { sh 'sh demo/ci/run-cloud.sh architecture' }
|
||||||
|
}
|
||||||
|
stage('Package versioned artifact') {
|
||||||
|
steps { sh 'sh demo/ci/run-cloud.sh package' }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
post {
|
||||||
|
always {
|
||||||
|
archiveArtifacts artifacts: 'build/demo/artifacts/*,build/demo/reports/*',
|
||||||
|
allowEmptyArchive: true, fingerprint: true
|
||||||
|
junit testResults: 'build/demo/reports/tests.xml', allowEmptyResults: true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
+174
@@ -0,0 +1,174 @@
|
|||||||
|
# TikZRefinery DevOps demo baseline
|
||||||
|
|
||||||
|
This directory imports the exact source checkpoint
|
||||||
|
`f4e3193d49a98efcf2f16c2aa22d6085ebe70f36` from
|
||||||
|
`https://github.com/Generic-Sun/TikZRefinery.git`. Its application/report baseline
|
||||||
|
is **0.1.4-alpha**. The senior-design repository remains the development home.
|
||||||
|
Its notices, author attribution and historical evidence are retained. No new
|
||||||
|
project-wide licence is granted by this import.
|
||||||
|
|
||||||
|
`snapshot.json` records all 435 original Git blob IDs, SHA-256 hashes and sizes.
|
||||||
|
`tikzrefinery/` contains raw committed blobs, not the senior checkout's untracked
|
||||||
|
work or old package binaries. Git attributes preserve those bytes on Windows
|
||||||
|
and Linux. Run `python demo/ci/verify-snapshot.py --require-tracked` from a Git
|
||||||
|
checkout before and after a build. This checks the index as well as the files on
|
||||||
|
disk, so an ignored but locally present upstream asset cannot hide an incomplete
|
||||||
|
commit. Stage intended snapshot files before using that check. Exported SSH
|
||||||
|
rehearsals without Git metadata can use the command without `--require-tracked`.
|
||||||
|
Do not regenerate canonical PDFs or change product source during baseline verification.
|
||||||
|
|
||||||
|
The proposed provider-class naming correction remains reserved for a separate
|
||||||
|
issue-linked demo increment after the baseline pipeline is verified. It is not
|
||||||
|
part of this import. Keep that increment and the import distinguishable in Git.
|
||||||
|
Neither a repository rename nor a commit/push is performed by these scripts.
|
||||||
|
|
||||||
|
## Build identities
|
||||||
|
|
||||||
|
The upstream `0.1.4-alpha` version and full source commit remain separate from
|
||||||
|
the demo's `major.minor.changelist` delivery identifier. Jenkins uses
|
||||||
|
`1.0.<BUILD_NUMBER>`. A command-line rehearsal defaults to `1.0.0` and explicitly
|
||||||
|
records that it is not a Jenkins run. It uses a separate rehearsal image name.
|
||||||
|
|
||||||
|
Keep `build-info.json`, `delivery-info.json` and `upstream-snapshot.json` with
|
||||||
|
the built application. BuildInfo reports the actual checkout seen by CMake;
|
||||||
|
an exported cloud rehearsal with no Git checkout truthfully reports that identity
|
||||||
|
as unavailable. Delivery metadata separately retains the upstream commit,
|
||||||
|
downstream commit or parent, modified state, input hashes and execution kind.
|
||||||
|
An old binary is never relabelled as the frozen source build.
|
||||||
|
|
||||||
|
## Windows application and report checks
|
||||||
|
|
||||||
|
Use the already-installed matching Qt kit, CMake, Ninja, MinGW and TinyTeX:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
./demo/ci/build-windows.ps1 -DeliveryVersion 1.0.0
|
||||||
|
```
|
||||||
|
|
||||||
|
The helper builds Release, runs all eight CTests, bundles the real rectangle DLL,
|
||||||
|
uses `windeployqt` for compiler/Qt dependencies and includes the matching offscreen
|
||||||
|
platform plugin for automated package checks. It refuses to overwrite a previous
|
||||||
|
package. Override tool paths or `-OutputDirectory` for another workstation.
|
||||||
|
The normal Windows platform plugin remains included for interactive use.
|
||||||
|
|
||||||
|
For a report rehearsal, copy the frozen tree into one task-local work directory
|
||||||
|
and run its `documents/build-report.ps1` there with an explicit output directory.
|
||||||
|
Its diagram-index generation writes to that disposable copy. Use the existing
|
||||||
|
shared TinyTeX installation and the complete upstream sequence. Do not replace
|
||||||
|
the imported canonical PDFs or historical index.
|
||||||
|
|
||||||
|
## Existing Droplet worker
|
||||||
|
|
||||||
|
The artifact-only `Jenkinsfile` uses the existing trusted delivery agent. It
|
||||||
|
does not bind registry or deployment credentials and does not deploy to the
|
||||||
|
pricing application environments. Its SCM definition must select reviewed
|
||||||
|
`main`; its first stage verifies ancestry before executing the build scripts.
|
||||||
|
Existing pricing release/recovery and manual-build jobs remain separate.
|
||||||
|
|
||||||
|
One-time administrator preparation:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
sh demo/ci/prepare-images.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
This verifies the existing manual compiler's full image ID, then builds a
|
||||||
|
Qt/CMake/compiler/Doxygen image and a separate runtime base on the existing
|
||||||
|
Droplet. Debian package versions are inventoried; rebuilding later may resolve
|
||||||
|
newer packages and produce different image IDs. `toolchain.json` records the
|
||||||
|
images actually verified for this baseline. The preparation output goes to
|
||||||
|
`build/demo/toolchain-observed.json`; review it before updating that record.
|
||||||
|
The ordinary pipeline refuses an unexpected local toolchain/runtime image ID.
|
||||||
|
|
||||||
|
Run stages sequentially from the checkout root:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
sh demo/ci/run-cloud.sh native
|
||||||
|
sh demo/ci/run-cloud.sh report
|
||||||
|
sh demo/ci/run-cloud.sh architecture
|
||||||
|
DELIVERY_VERSION=1.0.0 sh demo/ci/run-cloud.sh package
|
||||||
|
```
|
||||||
|
|
||||||
|
The wrapper accounts for the delivery agent's named-volume workspace: Docker
|
||||||
|
bind sources must use the volume's host path, not its container-visible path.
|
||||||
|
Application/report containers have no network, a read-only checkout/root,
|
||||||
|
dropped capabilities, a private temporary filesystem and bounded CPU/RAM/PIDs.
|
||||||
|
Only their dedicated output directory is writable. Each run clears its staging
|
||||||
|
artifacts and reports, retaining compiled caches and Jenkins' archived history;
|
||||||
|
a failure must not upload an older run's successful output. Heavy stages are sequential;
|
||||||
|
do not overlap them with another manual or delivery build on this single-CPU host.
|
||||||
|
|
||||||
|
The native stage compiles the application and real provider and runs all eight
|
||||||
|
offscreen suites, including incompatible-module rejection. The report stage
|
||||||
|
builds both editions with latexmk's bibliography/index/reference passes and
|
||||||
|
checks the upstream source/figure index. Architecture output comes from C++ via
|
||||||
|
Doxygen/Graphviz, distinct from the authored TikZ diagrams.
|
||||||
|
|
||||||
|
Packaging requires the eight passing suites, compiled report and generated
|
||||||
|
architecture. It builds a non-root application image, checks that its offscreen
|
||||||
|
event loop stays running, and emits an image archive, architecture ZIP, reports,
|
||||||
|
provenance and checksums under `build/demo/artifacts/`. Image names are immutable
|
||||||
|
within this workflow; select a new delivery version instead of overwriting one.
|
||||||
|
`verify-artifacts.py` checks every downloaded/staged checksum and the saved OCI
|
||||||
|
manifest, configuration and layer digests, plus the architecture ZIP's entry point.
|
||||||
|
It targets the existing Docker 29/containerd archive format and does not confuse
|
||||||
|
the engine's manifest ID with the separate configuration digest.
|
||||||
|
|
||||||
|
The Linux image is a desktop application container, not a web service. Its
|
||||||
|
default offscreen backend permits headless checks; displaying a real Linux GUI
|
||||||
|
requires an appropriate display backend. Use the freshly built Windows package
|
||||||
|
for the classroom's interactive application view. GUI-process and automated
|
||||||
|
tests do not establish complete product acceptance.
|
||||||
|
The application image directs its writable home/font cache into the bounded
|
||||||
|
temporary mount; its root filesystem remains read-only during the smoke check.
|
||||||
|
|
||||||
|
## Verification boundary and current evidence
|
||||||
|
|
||||||
|
The task's ignored records are under `build/evidence/demo-baseline-20261125/`.
|
||||||
|
Windows Release passed eight suites. The fresh portable package loaded its
|
||||||
|
bundled Qt and rectangle module with the development toolchain absent from PATH.
|
||||||
|
Both report editions rebuilt and all 585 rendered pages matched the frozen
|
||||||
|
baseline at the comparison resolution. Cloud stage results are recorded as they
|
||||||
|
actually complete; command-line execution is not labelled as a Jenkins build.
|
||||||
|
|
||||||
|
A real Jenkins run must additionally prove SCM checkout, stage scheduling,
|
||||||
|
JUnit display, artifact archiving/download and the corresponding source/version
|
||||||
|
identity. Publish the reviewed baseline before selecting it in a job. The
|
||||||
|
provider rename remains pending until that verification succeeds.
|
||||||
|
|
||||||
|
The first real run, [Jenkins build 1](https://ci.yebilly.me/job/tikzrefinery-demo/1/),
|
||||||
|
checked out merged main `d37297b` and stopped at the frozen-file gate: the global
|
||||||
|
`*.dvi` ignore rule had excluded one original asset from the 434-file Git input,
|
||||||
|
although the local and exported rehearsals contained all 435 files. It also
|
||||||
|
exposed a missing JUnit reporting plugin. The correction retains the original
|
||||||
|
1,268-byte blob, adds an exact ignore exception and checks tracked provenance.
|
||||||
|
This failed run does not establish application compilation or artifact delivery.
|
||||||
|
The [job setup and verification runbook](jenkins/README.md) records prerequisites
|
||||||
|
and the remaining checks for the reviewed rerun.
|
||||||
|
|
||||||
|
## Demonstration and ownership
|
||||||
|
|
||||||
|
Use [the timed demonstration script](DEMO_SCRIPT.md) for the proposed speaker
|
||||||
|
handoffs, configuration tour, two-tool SWOT and rubric evidence checklist.
|
||||||
|
Finalize its live issue/change and build references after the baseline Jenkins
|
||||||
|
run passes. The [November 25 web-access record](evidence/web-access-20261125.json)
|
||||||
|
captures the authorized home-source addition without publishing the address.
|
||||||
|
|
||||||
|
The professor's stated evaluation scope is the DevOps workflow. Zammad remains
|
||||||
|
a separate assignment and the unfinished VPN is not represented as implemented.
|
||||||
|
The final demonstration must show an existing issue and planned-change comment,
|
||||||
|
meaningful source change, commit/push, visible pipeline build/test/package,
|
||||||
|
versioned output, configuration explanations and cloud load. Present a SWOT
|
||||||
|
comparison of two tools actually used, such as Gitea Actions and Jenkins.
|
||||||
|
Doxygen output is a candidate for the optional source-extraction bonus.
|
||||||
|
|
||||||
|
Per-stage CSVs sample the host CPU counters and memory available through the
|
||||||
|
cloud agent's `/proc`, plus free space on its workspace filesystem. These are
|
||||||
|
observations of the shared host, not proof every change was caused by this job.
|
||||||
|
Use the existing Grafana dashboard during rehearsal to show the build window.
|
||||||
|
Keep the complete demonstration, explanation and questions within 20 minutes.
|
||||||
|
|
||||||
|
No new Droplet or plan is required by this preparation; the existing paid host
|
||||||
|
incurs transient build, storage and network use. Vincent owns the host and local
|
||||||
|
runtime availability; Billy reviews group changes. Retain source, artifacts,
|
||||||
|
test reports and required grading evidence. Remove only identified current-task
|
||||||
|
build scratch after review. Never prune shared images/volumes, runner identities,
|
||||||
|
older packages or unrelated coursework as part of demo cleanup.
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
ARG RUNTIME_IMAGE
|
||||||
|
FROM ${RUNTIME_IMAGE}
|
||||||
|
ENV HOME=/tmp XDG_CACHE_HOME=/tmp/.cache
|
||||||
|
COPY --chown=1000:1000 . /opt/tikzrefinery/
|
||||||
|
ENTRYPOINT ["/opt/tikzrefinery/TikZRefinery"]
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# Compile disposable copies; never refresh the frozen source's canonical PDFs/index.
|
||||||
|
set -eu
|
||||||
|
source=/workspace/demo/tikzrefinery
|
||||||
|
out=/output/report
|
||||||
|
mkdir -p "$out/source" "$out/results"
|
||||||
|
cp -a "$source/." "$out/source/"
|
||||||
|
cd "$out/source/documents/latex"
|
||||||
|
for edition in TikZRefinerySubmission TikZRefinery; do
|
||||||
|
folder="$out/results/$edition"
|
||||||
|
mkdir -p "$folder"
|
||||||
|
echo "Compiling $edition: LaTeX, bibliography, index and cross-references"
|
||||||
|
if ! latexmk -pdf -interaction=nonstopmode -halt-on-error -file-line-error \
|
||||||
|
-outdir="$folder" "$edition.tex" > "$folder/console.txt" 2>&1; then
|
||||||
|
tail -60 "$folder/console.txt"; exit 1
|
||||||
|
fi
|
||||||
|
if grep -Eq '(^!|undefined references|undefined citations|Citation .* undefined|Reference .* undefined|Rerun to get cross-references right|Label\(s\) may have changed)' "$folder/$edition.log"; then
|
||||||
|
echo "Unresolved report diagnostics: $edition" >&2; exit 1
|
||||||
|
fi
|
||||||
|
test -s "$folder/$edition.pdf"
|
||||||
|
done
|
||||||
|
# The upstream checker binds its index to all source inputs and final shipout maps.
|
||||||
|
python3 ../update-diagram-index.py --build-directory "$out/results" --record-sources
|
||||||
|
python3 ../update-diagram-index.py --build-directory "$out/results"
|
||||||
|
cp "$out/results/TikZRefinerySubmission/TikZRefinerySubmission.pdf" /output/artifacts/TikZRefinery-report.pdf
|
||||||
|
cp ../diagram-index.json /output/artifacts/diagram-index.json
|
||||||
@@ -0,0 +1,56 @@
|
|||||||
|
[CmdletBinding()]
|
||||||
|
param(
|
||||||
|
[string]$QtKit = 'C:/Qt/6.12.0/mingw_64',
|
||||||
|
[string]$CompilerBin = 'C:/Qt/Tools/mingw1310_64/bin',
|
||||||
|
[string]$CMakeBin = 'C:/Qt/Tools/CMake_64/bin',
|
||||||
|
[string]$NinjaBin = 'C:/Qt/Tools/Ninja',
|
||||||
|
[string]$DeliveryVersion = '1.0.0',
|
||||||
|
[string]$OutputDirectory = 'build/demo-windows',
|
||||||
|
[string]$BuildDirectory,
|
||||||
|
[string]$PythonExecutable = 'python'
|
||||||
|
)
|
||||||
|
Set-StrictMode -Version Latest
|
||||||
|
$ErrorActionPreference = 'Stop'
|
||||||
|
$PSNativeCommandUseErrorActionPreference = $true
|
||||||
|
$repository = (Resolve-Path (Join-Path $PSScriptRoot '../..')).Path
|
||||||
|
if ($DeliveryVersion -notmatch '^\d+\.\d+\.\d+$') { throw 'Use major.minor.changelist' }
|
||||||
|
Push-Location $repository
|
||||||
|
try {
|
||||||
|
& $PythonExecutable demo/ci/verify-snapshot.py
|
||||||
|
$output = (New-Item -ItemType Directory -Force $OutputDirectory).FullName
|
||||||
|
$build = if ($BuildDirectory) { [IO.Path]::GetFullPath($BuildDirectory) } else { Join-Path $output 'build' }
|
||||||
|
$package = Join-Path $output "TikZRefinery-windows-$DeliveryVersion"
|
||||||
|
if (Test-Path $package) { throw "Preserve existing package; choose another output directory: $package" }
|
||||||
|
$env:Path = "$QtKit/bin;$CompilerBin;$NinjaBin;" + $env:Path
|
||||||
|
$cmake = Join-Path $CMakeBin 'cmake.exe'
|
||||||
|
& $cmake -S demo/tikzrefinery/code -B $build -G Ninja -DCMAKE_BUILD_TYPE=Release `
|
||||||
|
"-DCMAKE_PREFIX_PATH=$QtKit" "-DCMAKE_CXX_COMPILER=$CompilerBin/g++.exe" `
|
||||||
|
"-DCMAKE_MAKE_PROGRAM=$NinjaBin/ninja.exe"
|
||||||
|
& $cmake --build $build --parallel 4
|
||||||
|
& (Join-Path $CMakeBin 'ctest.exe') --test-dir $build --output-on-failure `
|
||||||
|
--output-junit (Join-Path $output 'tests.xml')
|
||||||
|
New-Item -ItemType Directory -Path "$package/shape-plugins" -Force | Out-Null
|
||||||
|
Copy-Item "$build/TikZRefinery.exe" $package
|
||||||
|
Copy-Item "$build/shape-plugins/tkr_rectangle.dll" "$package/shape-plugins"
|
||||||
|
& "$QtKit/bin/windeployqt.exe" --release --compiler-runtime --no-translations `
|
||||||
|
--no-opengl-sw --no-system-d3d-compiler "$package/TikZRefinery.exe"
|
||||||
|
# windeployqt selects qwindows for normal desktop use. Include the matching
|
||||||
|
# offscreen plugin as well so package smoke checks need no visible window.
|
||||||
|
Copy-Item "$QtKit/plugins/platforms/qoffscreen.dll" "$package/platforms"
|
||||||
|
Copy-Item "$build/build-info.json" $package
|
||||||
|
Copy-Item demo/snapshot.json "$package/upstream-snapshot.json"
|
||||||
|
Copy-Item demo/tikzrefinery/code/examples "$package/examples" -Recurse
|
||||||
|
$downstream = (& git rev-parse HEAD).Trim()
|
||||||
|
$state = (& git status --porcelain --untracked-files=normal) -join "`n"
|
||||||
|
[ordered]@{
|
||||||
|
delivery_version = $DeliveryVersion
|
||||||
|
upstream_commit = 'f4e3193d49a98efcf2f16c2aa22d6085ebe70f36'
|
||||||
|
application_baseline = '0.1.4-alpha'
|
||||||
|
downstream_commit = $downstream
|
||||||
|
downstream_modified = [bool]$state
|
||||||
|
execution = 'Windows command-line rehearsal; not a Jenkins run'
|
||||||
|
} | ConvertTo-Json | Set-Content "$package/delivery-info.json" -Encoding utf8
|
||||||
|
& $PythonExecutable demo/ci/verify-snapshot.py
|
||||||
|
Compress-Archive -LiteralPath $package -DestinationPath "$package.zip"
|
||||||
|
Get-FileHash "$package.zip" -Algorithm SHA256 | Format-List
|
||||||
|
} finally { Pop-Location }
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
"""Generate source-based diagrams, separate from the authored architecture."""
|
||||||
|
from pathlib import Path
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
output = Path('/output/architecture')
|
||||||
|
output.mkdir(exist_ok=True)
|
||||||
|
configuration = output / 'Doxyfile'
|
||||||
|
configuration.write_text('''PROJECT_NAME = TikZRefinery
|
||||||
|
OUTPUT_DIRECTORY = /output/architecture
|
||||||
|
INPUT = /workspace/demo/tikzrefinery/code/src /workspace/demo/tikzrefinery/code/plugins /workspace/demo/tikzrefinery/code/plugin-api
|
||||||
|
RECURSIVE = YES
|
||||||
|
FILE_PATTERNS = *.h *.cpp
|
||||||
|
EXTRACT_ALL = YES
|
||||||
|
EXTRACT_PRIVATE = YES
|
||||||
|
GENERATE_HTML = YES
|
||||||
|
GENERATE_LATEX = NO
|
||||||
|
HAVE_DOT = YES
|
||||||
|
CLASS_GRAPH = YES
|
||||||
|
COLLABORATION_GRAPH = YES
|
||||||
|
DOT_IMAGE_FORMAT = svg
|
||||||
|
INTERACTIVE_SVG = NO
|
||||||
|
QUIET = YES
|
||||||
|
WARN_IF_UNDOCUMENTED = NO
|
||||||
|
WARN_LOGFILE = /output/reports/doxygen-warnings.txt
|
||||||
|
''')
|
||||||
|
subprocess.run(['doxygen', str(configuration)], check=True)
|
||||||
|
graphs = list((output / 'html').glob('*coll*graph.svg')) + list((output / 'html').glob('*inherit*graph.svg'))
|
||||||
|
assert graphs, 'No source-based class graph was generated'
|
||||||
|
print(f'PASS: generated {len(graphs)} class/collaboration graphs from C++ source')
|
||||||
@@ -0,0 +1,96 @@
|
|||||||
|
"""Package only successful tested builds; keep delivery and upstream identities separate."""
|
||||||
|
import hashlib
|
||||||
|
import json
|
||||||
|
import os
|
||||||
|
from pathlib import Path
|
||||||
|
import re
|
||||||
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
import tarfile
|
||||||
|
import xml.etree.ElementTree as ET
|
||||||
|
import zipfile
|
||||||
|
|
||||||
|
root = Path.cwd()
|
||||||
|
out = root / 'build/demo'
|
||||||
|
version = os.environ.get('DELIVERY_VERSION', '1.0.0')
|
||||||
|
assert re.fullmatch(r'\d+\.\d+\.\d+', version), 'Use major.minor.changelist'
|
||||||
|
|
||||||
|
def run(*args, **kwargs):
|
||||||
|
return subprocess.check_output(args, text=True, stderr=subprocess.STDOUT, **kwargs).strip()
|
||||||
|
|
||||||
|
def digest(path):
|
||||||
|
with path.open('rb') as stream:
|
||||||
|
return hashlib.file_digest(stream, 'sha256').hexdigest()
|
||||||
|
|
||||||
|
tests = ET.parse(out / 'reports/tests.xml')
|
||||||
|
cases = tests.findall('.//testcase')
|
||||||
|
assert len(cases) == 8 and all(case.find('failure') is None and case.find('error') is None
|
||||||
|
and case.find('skipped') is None for case in cases), 'Require all eight baseline suites'
|
||||||
|
expected = {'rectangle_plugin_contract','core_foundations','rectangle_display',
|
||||||
|
'segment_display','whole_element_drag','rectangle_resize','workspace_sidebar','session_history'}
|
||||||
|
assert {case.attrib['name'] for case in cases} == expected, 'Wrong suite set'
|
||||||
|
assert (out / 'artifacts/TikZRefinery-report.pdf').is_file()
|
||||||
|
assert (out / 'architecture/html/index.html').is_file()
|
||||||
|
snapshot = json.loads((root / 'demo/snapshot.json').read_text())
|
||||||
|
jenkins = bool(os.environ.get('BUILD_URL'))
|
||||||
|
try:
|
||||||
|
downstream = run('git', 'rev-parse', 'HEAD')
|
||||||
|
modified = bool(run('git', 'status', '--porcelain', '--untracked-files=normal'))
|
||||||
|
except subprocess.CalledProcessError:
|
||||||
|
assert not jenkins, 'Jenkins must retain its real checkout identity'
|
||||||
|
downstream = os.environ.get('DOWNSTREAM_PARENT_COMMIT', 'unavailable')
|
||||||
|
modified = True
|
||||||
|
source_hashes = {p.relative_to(root / 'demo').as_posix(): hashlib.sha256(p.read_bytes()).hexdigest()
|
||||||
|
for p in sorted((root / 'demo').rglob('*')) if p.is_file()}
|
||||||
|
record = dict(delivery_version=version, application_baseline=snapshot['application_baseline'],
|
||||||
|
upstream_repository=snapshot['upstream_repository'], upstream_commit=snapshot['upstream_commit'],
|
||||||
|
downstream_commit_or_parent=downstream, downstream_modified=modified,
|
||||||
|
execution='Jenkins' if jenkins else 'SSH command-line rehearsal; not a Jenkins run',
|
||||||
|
build_url=os.environ.get('BUILD_URL'), source_sha256=source_hashes,
|
||||||
|
toolchain=json.loads((root / 'demo/toolchain.json').read_text()))
|
||||||
|
bundle = out / 'application-bundle'
|
||||||
|
bundle.mkdir(exist_ok=True)
|
||||||
|
(bundle / 'shape-plugins').mkdir(exist_ok=True)
|
||||||
|
for source, destination in [(out/'native/TikZRefinery',bundle/'TikZRefinery'),
|
||||||
|
(out/'native/shape-plugins/tkr_rectangle.so',bundle/'shape-plugins/tkr_rectangle.so'),
|
||||||
|
(out/'native/build-info.json',bundle/'build-info.json'),
|
||||||
|
(root/'demo/snapshot.json',bundle/'upstream-snapshot.json')]:
|
||||||
|
shutil.copy2(source, destination)
|
||||||
|
(bundle / 'delivery-info.json').write_text(json.dumps(record, indent=2) + '\n')
|
||||||
|
image = ('ssw590-tikzrefinery' if jenkins else 'ssw590-tikzrefinery-rehearsal') + ':' + version
|
||||||
|
exists = subprocess.run(['docker','image','inspect',image], stdout=subprocess.DEVNULL,stderr=subprocess.DEVNULL).returncode == 0
|
||||||
|
assert not exists, f'Preserve existing artifact {image}; select a new delivery version'
|
||||||
|
environment = dict(os.environ, DOCKER_BUILDKIT='0')
|
||||||
|
subprocess.run(['docker','build','--memory=512m','--memory-swap=768m','--cpu-quota=50000',
|
||||||
|
'--build-arg','RUNTIME_IMAGE=ssw590-demo-runtime:20261125',
|
||||||
|
'-t',image,'-f','demo/ci/application.Dockerfile',str(bundle)],check=True,env=environment)
|
||||||
|
record['application_image'] = image
|
||||||
|
record['application_image_id'] = run('docker','image','inspect','-f','{{.Id}}',image)
|
||||||
|
smoke = subprocess.run(['docker','run','--rm','--network','none','--read-only','--cap-drop','ALL',
|
||||||
|
'--security-opt','no-new-privileges','--memory=256m','--memory-swap=384m',
|
||||||
|
'--cpus=0.5','--pids-limit=128','--tmpfs','/tmp:rw,nosuid,nodev,size=32m',
|
||||||
|
'--entrypoint','sh',image,'-c','timeout 5s ./TikZRefinery'],
|
||||||
|
stdout=subprocess.PIPE,stderr=subprocess.STDOUT,text=True)
|
||||||
|
(out/'reports/application-smoke.txt').write_text(smoke.stdout)
|
||||||
|
assert smoke.returncode == 124, ('Expected GUI event loop to remain running offscreen',smoke.returncode,smoke.stdout)
|
||||||
|
archive = out / 'artifacts' / f'TikZRefinery-{version}-linux-image.tar.gz'
|
||||||
|
with subprocess.Popen(['docker','save',image],stdout=subprocess.PIPE) as process:
|
||||||
|
import gzip
|
||||||
|
with gzip.open(archive, 'wb') as stream:
|
||||||
|
shutil.copyfileobj(process.stdout,stream)
|
||||||
|
assert process.wait() == 0
|
||||||
|
with tarfile.open(archive,'r:gz') as tar:
|
||||||
|
manifest = json.load(tar.extractfile('manifest.json'))
|
||||||
|
assert image in manifest[0]['RepoTags']
|
||||||
|
record['image_archive_sha256'] = digest(archive)
|
||||||
|
(out/'artifacts/delivery-info.json').write_text(json.dumps(record,indent=2)+'\n')
|
||||||
|
with zipfile.ZipFile(out/'artifacts'/f'TikZRefinery-{version}-architecture.zip','w',zipfile.ZIP_DEFLATED) as archive_docs:
|
||||||
|
for file in sorted((out/'architecture/html').rglob('*')):
|
||||||
|
if file.is_file():
|
||||||
|
archive_docs.write(file,file.relative_to(out/'architecture'))
|
||||||
|
checksums = []
|
||||||
|
for path in sorted((out/'artifacts').iterdir()):
|
||||||
|
if path.is_file() and path.name != 'SHA256SUMS':
|
||||||
|
checksums.append(digest(path) + ' ' + path.name)
|
||||||
|
(out/'artifacts/SHA256SUMS').write_text('\n'.join(checksums)+'\n')
|
||||||
|
print(json.dumps({key:record[key] for key in ['delivery_version','execution','application_image','application_image_id']},indent=2))
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# Administrator preparation on the existing host; no application/service restart.
|
||||||
|
set -eu
|
||||||
|
base=ssw590-manual-ci:20261007
|
||||||
|
expected=sha256:5d24657a4578977fc7709165b82fc869f09a654a58ab4a0c8defd9d2cd662d5d
|
||||||
|
[ "$(docker image inspect -f '{{.Id}}' "$base")" = "$expected" ] || {
|
||||||
|
echo 'Existing manual toolchain ID differs; investigate before building.' >&2; exit 1;
|
||||||
|
}
|
||||||
|
mkdir -p build/demo
|
||||||
|
export DOCKER_BUILDKIT=0
|
||||||
|
docker build --force-rm --memory=512m --memory-swap=768m --cpu-quota=50000 \
|
||||||
|
-t ssw590-demo-toolchain:20261125 -f demo/ci/toolchain.Dockerfile demo/ci
|
||||||
|
docker build --force-rm --memory=512m --memory-swap=768m --cpu-quota=50000 \
|
||||||
|
-t ssw590-demo-runtime:20261125 -f demo/ci/runtime.Dockerfile demo/ci
|
||||||
|
python3 - <<'PY'
|
||||||
|
import json, subprocess
|
||||||
|
from pathlib import Path
|
||||||
|
def identity(name):
|
||||||
|
return subprocess.check_output(['docker','image','inspect','-f','{{.Id}}',name],text=True).strip()
|
||||||
|
record = {name: identity(name) for name in ['ssw590-demo-toolchain:20261125','ssw590-demo-runtime:20261125']}
|
||||||
|
Path('build/demo/toolchain-observed.json').write_text(json.dumps(record,indent=2)+'\n')
|
||||||
|
print(json.dumps(record,indent=2))
|
||||||
|
PY
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
"""Clear per-run staging outputs, retaining compiler/report caches and archived runs."""
|
||||||
|
from pathlib import Path
|
||||||
|
import shutil
|
||||||
|
|
||||||
|
root = Path.cwd().resolve()
|
||||||
|
assert (root / 'demo/snapshot.json').is_file(), 'Run from the demo repository root'
|
||||||
|
for name in ('artifacts', 'reports'):
|
||||||
|
target = root / 'build/demo' / name
|
||||||
|
resolved = target.resolve()
|
||||||
|
assert not target.is_symlink() and resolved == root / 'build/demo' / name
|
||||||
|
assert resolved.is_relative_to(root / 'build/demo')
|
||||||
|
if target.exists():
|
||||||
|
shutil.rmtree(target)
|
||||||
|
target.mkdir(parents=True)
|
||||||
|
print('Fresh per-run artifacts/reports; build caches retained')
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# The same stages are used by Jenkins and explicitly labelled SSH rehearsals.
|
||||||
|
set -eu
|
||||||
|
phase=${1:?choose native, report, architecture or package}
|
||||||
|
root=$(pwd)
|
||||||
|
out="$root/build/demo"
|
||||||
|
if [ "$phase" = native ]; then python3 demo/ci/reset-output.py; fi
|
||||||
|
# The Docker daemon resolves bind sources on the host. Jenkins' workspace lives
|
||||||
|
# inside its named volume, so its container-visible path is not a host path.
|
||||||
|
case "$root" in
|
||||||
|
/home/jenkins/agent/*)
|
||||||
|
volume_root=$(docker volume inspect -f '{{.Mountpoint}}' ssw590-delivery-workspace)
|
||||||
|
host_root="$volume_root/${root#/home/jenkins/agent/}"
|
||||||
|
;;
|
||||||
|
*) host_root="$root";;
|
||||||
|
esac
|
||||||
|
mkdir -p "$out/artifacts" "$out/reports"
|
||||||
|
python3 demo/ci/verify-snapshot.py
|
||||||
|
test -s demo/toolchain.json || { echo 'Prepare and verify the host images before this pipeline.' >&2; exit 1; }
|
||||||
|
python3 - <<'PY'
|
||||||
|
import json, subprocess
|
||||||
|
for name, expected in json.load(open('demo/toolchain.json')).items():
|
||||||
|
actual=subprocess.check_output(['docker','image','inspect','-f','{{.Id}}',name],text=True).strip()
|
||||||
|
assert actual==expected, (name, 'local toolchain changed')
|
||||||
|
PY
|
||||||
|
toolchain=ssw590-demo-toolchain:20261125
|
||||||
|
python3 demo/ci/sample-load.py "$out/reports/$phase-load.csv" &
|
||||||
|
sampler=$!
|
||||||
|
trap 'kill "$sampler" 2>/dev/null || true; wait "$sampler" 2>/dev/null || true' EXIT HUP INT TERM
|
||||||
|
run() {
|
||||||
|
docker run --rm --network none --read-only --cap-drop ALL \
|
||||||
|
--security-opt no-new-privileges --memory=768m --memory-swap=1536m \
|
||||||
|
--cpus=0.75 --pids-limit=256 --user "$(id -u):$(id -g)" \
|
||||||
|
--tmpfs /tmp:rw,nosuid,nodev,size=128m -e HOME=/tmp -e QT_QPA_PLATFORM=offscreen \
|
||||||
|
-e GIT_CONFIG_COUNT=1 -e GIT_CONFIG_KEY_0=safe.directory -e GIT_CONFIG_VALUE_0=/workspace \
|
||||||
|
--mount "type=bind,source=$host_root,target=/workspace,readonly" \
|
||||||
|
--mount "type=bind,source=$host_root/build/demo,target=/output" \
|
||||||
|
-w /workspace "$toolchain" sh -eu -c "$1"
|
||||||
|
}
|
||||||
|
case "$phase" in
|
||||||
|
native)
|
||||||
|
echo '=== Build C++/Qt application and provider; run all registered CTests ==='
|
||||||
|
run 'cmake -S demo/tikzrefinery/code -B /output/native -G Ninja -DCMAKE_BUILD_TYPE=Release
|
||||||
|
cmake --build /output/native --parallel 1
|
||||||
|
ctest --test-dir /output/native --output-on-failure --output-junit /output/reports/tests.xml
|
||||||
|
cp /opt/demo-toolchain/packages.txt /output/reports/toolchain-packages.txt'
|
||||||
|
;;
|
||||||
|
report)
|
||||||
|
echo '=== Compile both authored report editions ==='
|
||||||
|
run 'sh demo/ci/build-report.sh'
|
||||||
|
;;
|
||||||
|
architecture)
|
||||||
|
echo '=== Extract architecture from the frozen C++ source ==='
|
||||||
|
run 'python3 demo/ci/extract-architecture.py'
|
||||||
|
;;
|
||||||
|
package)
|
||||||
|
echo '=== Package versioned deployable application image and reports ==='
|
||||||
|
python3 demo/ci/package.py
|
||||||
|
python3 demo/ci/verify-artifacts.py
|
||||||
|
;;
|
||||||
|
*) echo 'Unknown phase' >&2; exit 1;;
|
||||||
|
esac
|
||||||
|
python3 demo/ci/verify-snapshot.py
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
FROM node:22-bookworm-slim@sha256:c3de60bf2f9dd0ac6370e6117950ff62d6e339527e7472301c9c78a017978392
|
||||||
|
RUN apt-get update \
|
||||||
|
&& apt-get install -y --no-install-recommends \
|
||||||
|
libqt6widgets6 libqt6gui6 libqt6core6 qt6-qpa-plugins fonts-dejavu-core \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
ENV QT_QPA_PLATFORM=offscreen
|
||||||
|
USER node
|
||||||
|
WORKDIR /opt/tikzrefinery
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
"""Read /proc host counters visible to the cloud agent; never inspect processes."""
|
||||||
|
import csv
|
||||||
|
from datetime import datetime, timezone
|
||||||
|
from pathlib import Path
|
||||||
|
import shutil
|
||||||
|
import signal
|
||||||
|
import sys
|
||||||
|
import time
|
||||||
|
|
||||||
|
running = True
|
||||||
|
def stop(*_):
|
||||||
|
global running
|
||||||
|
running = False
|
||||||
|
signal.signal(signal.SIGTERM, stop)
|
||||||
|
signal.signal(signal.SIGINT, stop)
|
||||||
|
|
||||||
|
def cpu():
|
||||||
|
fields = [int(n) for n in Path('/proc/stat').read_text().splitlines()[0].split()[1:9]]
|
||||||
|
return sum(fields), fields[3] + fields[4]
|
||||||
|
|
||||||
|
last_total, last_idle = cpu()
|
||||||
|
with open(sys.argv[1], 'w', newline='') as stream:
|
||||||
|
writer = csv.writer(stream)
|
||||||
|
writer.writerow(['utc','host_cpu_percent','host_mem_available_kib','filesystem_free_bytes'])
|
||||||
|
while running:
|
||||||
|
time.sleep(1)
|
||||||
|
total, idle = cpu()
|
||||||
|
memory = dict(line.split(':', 1) for line in Path('/proc/meminfo').read_text().splitlines())
|
||||||
|
usage = 100 * (1 - (idle-last_idle) / max(1, total-last_total))
|
||||||
|
writer.writerow([datetime.now(timezone.utc).isoformat(),round(usage,2),
|
||||||
|
int(memory['MemAvailable'].split()[0]),shutil.disk_usage('.').free])
|
||||||
|
stream.flush()
|
||||||
|
last_total, last_idle = total, idle
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
# Existing, tested TeX compiler image transferred to The-Ocean on November 14.
|
||||||
|
# prepare-images.sh verifies its complete local image ID before this build.
|
||||||
|
FROM ssw590-manual-ci:20261007
|
||||||
|
RUN apt-get update \
|
||||||
|
&& apt-get install -y --no-install-recommends \
|
||||||
|
build-essential cmake ninja-build qt6-base-dev qt6-qpa-plugins \
|
||||||
|
fonts-dejavu-core doxygen graphviz \
|
||||||
|
&& mkdir -p /opt/demo-toolchain \
|
||||||
|
&& dpkg-query -W -f='${Package} ${Version}\n' > /opt/demo-toolchain/packages.txt \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
WORKDIR /workspace
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
"""Check transport hashes and the saved OCI manifest/configuration/layer chain."""
|
||||||
|
import hashlib
|
||||||
|
import json
|
||||||
|
from pathlib import Path
|
||||||
|
import re
|
||||||
|
import sys
|
||||||
|
import tarfile
|
||||||
|
import zipfile
|
||||||
|
|
||||||
|
folder = Path(sys.argv[1] if len(sys.argv) > 1 else 'build/demo/artifacts').resolve()
|
||||||
|
for line in (folder / 'SHA256SUMS').read_text().splitlines():
|
||||||
|
expected, name = line.split(' ', 1)
|
||||||
|
assert Path(name).name == name and re.fullmatch(r'[0-9a-f]{64}', expected)
|
||||||
|
with (folder / name).open('rb') as stream:
|
||||||
|
assert hashlib.file_digest(stream, 'sha256').hexdigest() == expected, name
|
||||||
|
record = json.loads((folder / 'delivery-info.json').read_text())
|
||||||
|
version = record['delivery_version']
|
||||||
|
assert re.fullmatch(r'\d+\.\d+\.\d+', version)
|
||||||
|
with tarfile.open(folder / f'TikZRefinery-{version}-linux-image.tar.gz', 'r:gz') as archive:
|
||||||
|
compatibility = json.load(archive.extractfile('manifest.json'))[0]
|
||||||
|
assert record['application_image'] in compatibility['RepoTags']
|
||||||
|
index = json.load(archive.extractfile('index.json'))
|
||||||
|
descriptor = next(row for row in index['manifests'] if row['digest'] == record['application_image_id'])
|
||||||
|
def blob_name(digest):
|
||||||
|
assert re.fullmatch(r'sha256:[0-9a-f]{64}', digest)
|
||||||
|
return 'blobs/sha256/' + digest.split(':')[1]
|
||||||
|
manifest_bytes = archive.extractfile(blob_name(descriptor['digest'])).read()
|
||||||
|
assert 'sha256:' + hashlib.sha256(manifest_bytes).hexdigest() == descriptor['digest']
|
||||||
|
manifest = json.loads(manifest_bytes)
|
||||||
|
references = [manifest['config'], *manifest['layers']]
|
||||||
|
members = {member.name: member for member in archive.getmembers()}
|
||||||
|
for reference in sorted(references, key=lambda row: members[blob_name(row['digest'])].offset_data):
|
||||||
|
name = blob_name(reference['digest'])
|
||||||
|
assert members[name].isfile(), name
|
||||||
|
with archive.extractfile(name) as stream:
|
||||||
|
assert 'sha256:' + hashlib.file_digest(stream, 'sha256').hexdigest() == reference['digest'], name
|
||||||
|
with zipfile.ZipFile(folder / f'TikZRefinery-{version}-architecture.zip') as docs:
|
||||||
|
assert 'html/index.html' in docs.namelist()
|
||||||
|
print(f'PASS: version {version}, artifact checksums, OCI manifest/config/{len(manifest["layers"])} layers and architecture ZIP')
|
||||||
@@ -0,0 +1,45 @@
|
|||||||
|
"""Verify the exact frozen source input, independent of either Git checkout."""
|
||||||
|
import argparse
|
||||||
|
import hashlib
|
||||||
|
import json
|
||||||
|
from pathlib import Path
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
parser = argparse.ArgumentParser(description=__doc__)
|
||||||
|
parser.add_argument('--require-tracked', action='store_true',
|
||||||
|
help='Also verify that the Git index contains every original blob.')
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
DEMO = Path(__file__).resolve().parents[1]
|
||||||
|
SOURCE = DEMO / 'tikzrefinery'
|
||||||
|
manifest = json.loads((DEMO / 'snapshot.json').read_text(encoding='utf-8'))
|
||||||
|
expected = manifest['files']
|
||||||
|
if args.require_tracked:
|
||||||
|
index = subprocess.check_output(
|
||||||
|
['git', 'ls-files', '--stage', '-z', '--', 'demo/tikzrefinery'], cwd=DEMO.parent)
|
||||||
|
tracked = {}
|
||||||
|
for row in index.decode('utf-8').split('\0'):
|
||||||
|
if not row:
|
||||||
|
continue
|
||||||
|
metadata, path = row.split('\t', 1)
|
||||||
|
mode, blob, stage = metadata.split()
|
||||||
|
assert stage == '0', ('Unresolved snapshot index entry', path)
|
||||||
|
tracked[path.removeprefix('demo/tikzrefinery/')] = (mode, blob)
|
||||||
|
assert set(tracked) == set(expected), {
|
||||||
|
'untracked_snapshot_files': sorted(set(expected) - set(tracked)),
|
||||||
|
'unexpected_tracked_files': sorted(set(tracked) - set(expected))}
|
||||||
|
for name, identity in expected.items():
|
||||||
|
assert tracked[name] == (identity['mode'], identity['git_blob']), (
|
||||||
|
'Git index differs from the frozen upstream blob', name)
|
||||||
|
actual = {p.relative_to(SOURCE).as_posix() for p in SOURCE.rglob('*') if p.is_file()}
|
||||||
|
assert actual == set(expected), {'missing': sorted(set(expected) - actual),
|
||||||
|
'extra': sorted(actual - set(expected))}
|
||||||
|
for name, identity in expected.items():
|
||||||
|
data = (SOURCE / name).read_bytes()
|
||||||
|
assert hashlib.sha256(data).hexdigest() == identity['sha256'], name
|
||||||
|
git_blob = hashlib.sha1(b'blob ' + str(len(data)).encode() + b'\0' + data).hexdigest()
|
||||||
|
assert git_blob == identity['git_blob'], name
|
||||||
|
print(json.dumps({'result': 'passed', 'upstream_commit': manifest['upstream_commit'],
|
||||||
|
'application_baseline': manifest['application_baseline'],
|
||||||
|
'verified_files': len(expected),
|
||||||
|
'git_index_verified': args.require_tracked}, indent=2))
|
||||||
@@ -0,0 +1,80 @@
|
|||||||
|
{
|
||||||
|
"recorded_at_utc": "2026-11-26T00:35:06.371423+00:00",
|
||||||
|
"upstream_commit": "f4e3193d49a98efcf2f16c2aa22d6085ebe70f36",
|
||||||
|
"upstream_repository": "https://github.com/Generic-Sun/TikZRefinery.git",
|
||||||
|
"application_baseline": "0.1.4-alpha",
|
||||||
|
"verified_upstream_files": 435,
|
||||||
|
"windows": {
|
||||||
|
"tests_passed": 8,
|
||||||
|
"portable_module_load": "passed without development PATH",
|
||||||
|
"artifact": "TikZRefinery-windows-1.0.0.zip",
|
||||||
|
"sha256": "f1ec99e422d960a82b341b5c5f3cbb5443208f5479c79420fe863cf9a5b169e6"
|
||||||
|
},
|
||||||
|
"cloud": {
|
||||||
|
"execution": "SSH command-line rehearsal; not a Jenkins run",
|
||||||
|
"tests_passed": 8,
|
||||||
|
"image": "ssw590-tikzrefinery-rehearsal:1.0.1",
|
||||||
|
"image_id": "sha256:be98447bc0128ea294e1d65467c107fe752fe15e98c9e733ff6d062b3802b6dc",
|
||||||
|
"archive_sha256": "df81c32154fa8233d7cb78b6733525c5dce1c07662b588bd78437f4ee7969507",
|
||||||
|
"source_graphs": 25,
|
||||||
|
"figure_index_entries": 51,
|
||||||
|
"loads": {
|
||||||
|
"architecture-load": {
|
||||||
|
"samples": 11,
|
||||||
|
"first_utc": "2026-11-26T00:11:21.260377+00:00",
|
||||||
|
"last_utc": "2026-11-26T00:11:31.267178+00:00",
|
||||||
|
"sampled_span_seconds": 10.007,
|
||||||
|
"host_cpu_peak_percent": 100.0,
|
||||||
|
"host_mem_available_min_kib": 882268
|
||||||
|
},
|
||||||
|
"native-load": {
|
||||||
|
"samples": 147,
|
||||||
|
"first_utc": "2026-11-26T00:02:27.557402+00:00",
|
||||||
|
"last_utc": "2026-11-26T00:04:53.692922+00:00",
|
||||||
|
"sampled_span_seconds": 146.136,
|
||||||
|
"host_cpu_peak_percent": 100.0,
|
||||||
|
"host_mem_available_min_kib": 551432
|
||||||
|
},
|
||||||
|
"package-load": {
|
||||||
|
"samples": 50,
|
||||||
|
"first_utc": "2026-11-26T00:25:01.675756+00:00",
|
||||||
|
"last_utc": "2026-11-26T00:25:50.842932+00:00",
|
||||||
|
"sampled_span_seconds": 49.167,
|
||||||
|
"host_cpu_peak_percent": 100.0,
|
||||||
|
"host_mem_available_min_kib": 857376
|
||||||
|
},
|
||||||
|
"report-load": {
|
||||||
|
"samples": 76,
|
||||||
|
"first_utc": "2026-11-26T00:06:16.498330+00:00",
|
||||||
|
"last_utc": "2026-11-26T00:07:31.564264+00:00",
|
||||||
|
"sampled_span_seconds": 75.066,
|
||||||
|
"host_cpu_peak_percent": 100.0,
|
||||||
|
"host_mem_available_min_kib": 821652
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"windows_report_render_comparison": [
|
||||||
|
{
|
||||||
|
"edition": "submission",
|
||||||
|
"pages": 258,
|
||||||
|
"render_dpi": 65,
|
||||||
|
"identical_pages": 258,
|
||||||
|
"differing_pages": [],
|
||||||
|
"output_sha256": "850f98a70d286b94f2de3a857f1ed183cbce715a873f87f7c14930daa060f954"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"edition": "developer",
|
||||||
|
"pages": 327,
|
||||||
|
"render_dpi": 65,
|
||||||
|
"identical_pages": 327,
|
||||||
|
"differing_pages": [],
|
||||||
|
"output_sha256": "f002e78fa9cf6562e9ecf98cc31e3f6136a1961b8f45fb411ed262f695a9c937"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"jenkins_verification": "pending reviewed baseline commit/merge, SCM run and artifact download",
|
||||||
|
"remote_main_observed": "72bf10dcecc8db65dce4750c05bf841bea9b0834",
|
||||||
|
"downstream_parent": "fbda9516fe384e245a311386f72c73480fafbfaa",
|
||||||
|
"downstream_modified": true,
|
||||||
|
"provider_rename": "not prepared or implemented; reserved until baseline Jenkins verification",
|
||||||
|
"ownership": "Vincent handles commits/pushes; no publication performed"
|
||||||
|
}
|
||||||
@@ -0,0 +1,124 @@
|
|||||||
|
{
|
||||||
|
"observations_completed_utc": "2026-11-26T05:23:22Z",
|
||||||
|
"job_url": "https://ci.yebilly.me/job/tikzrefinery-demo/",
|
||||||
|
"settings": {
|
||||||
|
"disabled": "false",
|
||||||
|
"definition": "org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition",
|
||||||
|
"url": "https://git.yebilly.me/ssw590-group1/vpn-dns-gateway.git",
|
||||||
|
"branch": "*/main",
|
||||||
|
"script_path": "demo/Jenkinsfile",
|
||||||
|
"lightweight": "true",
|
||||||
|
"trigger_count": 0
|
||||||
|
},
|
||||||
|
"existing_checkout_credential_reused": true,
|
||||||
|
"readiness": {
|
||||||
|
"observed_utc": "2026-11-26T05:23:22Z",
|
||||||
|
"toolchain_images": {
|
||||||
|
"ssw590-demo-toolchain:20261125": "sha256:b09f82b3ba76f4445ff596c8c9423ed97d1d4e0fb6de1a3396a43bea972a4471",
|
||||||
|
"ssw590-demo-runtime:20261125": "sha256:ae1ded13e2320283ddc1f18892e3aebd5ce005c949bb56c62964313f37475dd9"
|
||||||
|
},
|
||||||
|
"memory_available_kib": 599628,
|
||||||
|
"swap_free_kib": 1490012,
|
||||||
|
"root_free_bytes": 5586022400,
|
||||||
|
"agent_running": true,
|
||||||
|
"manual_action_active": false
|
||||||
|
},
|
||||||
|
"first_run": {
|
||||||
|
"build_url": "https://ci.yebilly.me/job/tikzrefinery-demo/1/",
|
||||||
|
"revision": "d37297b88993fd8c5428c2e732f32f4c9324b51b",
|
||||||
|
"result": "FAILURE",
|
||||||
|
"duration_ms": 26453,
|
||||||
|
"scm_checkout_verified": true,
|
||||||
|
"main_ancestry_passed": true,
|
||||||
|
"source_gate_error": "Missing original documents/assets/loop-example/loop-boxes.dvi; 434 of 435 originals tracked",
|
||||||
|
"post_action_error": "No such DSL method junit; required plugin was absent",
|
||||||
|
"native_report_architecture_package_stages": "skipped after source-gate failure",
|
||||||
|
"deployable_artifact_produced": false
|
||||||
|
},
|
||||||
|
"reporting_plugin_preparation": {
|
||||||
|
"observed_utc": "2026-11-26T05:21:32Z",
|
||||||
|
"official_update_center": true,
|
||||||
|
"plugins": {
|
||||||
|
"junit": {
|
||||||
|
"version": "1458.1460.vd53b_087eeb_2c",
|
||||||
|
"required_core": "2.555.3"
|
||||||
|
},
|
||||||
|
"plugin-util-api": {
|
||||||
|
"version": "7.1403.vd380b_c42e90c",
|
||||||
|
"required_core": "2.555.3"
|
||||||
|
},
|
||||||
|
"font-awesome-api": {
|
||||||
|
"version": "7.3.1-1013.v0835a_879ec6d",
|
||||||
|
"required_core": "2.555.3"
|
||||||
|
},
|
||||||
|
"bootstrap5-api": {
|
||||||
|
"version": "5.3.9-1156.va_4c7fef67c56",
|
||||||
|
"required_core": "2.555.3"
|
||||||
|
},
|
||||||
|
"jquery3-api": {
|
||||||
|
"version": "3.7.1-687.v68d468e40b_30",
|
||||||
|
"required_core": "2.555.1"
|
||||||
|
},
|
||||||
|
"echarts-api": {
|
||||||
|
"version": "6.1.0-1321.v86c4c5114494",
|
||||||
|
"required_core": "2.555.3"
|
||||||
|
},
|
||||||
|
"antisamy-markup-formatter": {
|
||||||
|
"version": "173.v680e3a_b_69ff3",
|
||||||
|
"required_core": "2.479.1"
|
||||||
|
},
|
||||||
|
"prism-api": {
|
||||||
|
"version": "1.30.0-741.v034eb_0b_0a_a_fa_",
|
||||||
|
"required_core": "2.555.1"
|
||||||
|
},
|
||||||
|
"checks-api": {
|
||||||
|
"version": "441.v54e82638ca_71",
|
||||||
|
"required_core": "2.555.3"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"installation_and_extensions_ui": "Success",
|
||||||
|
"junit_enabled_ui": true,
|
||||||
|
"junit_step_visible_in_snippet_generator": true,
|
||||||
|
"controller_started_at": "2026-11-23T06:31:09.102475939Z",
|
||||||
|
"restart_requested": false
|
||||||
|
},
|
||||||
|
"local_repair_validation": {
|
||||||
|
"result": "passed",
|
||||||
|
"indexed_snapshot": {
|
||||||
|
"result": "passed",
|
||||||
|
"upstream_commit": "f4e3193d49a98efcf2f16c2aa22d6085ebe70f36",
|
||||||
|
"application_baseline": "0.1.4-alpha",
|
||||||
|
"verified_files": 435,
|
||||||
|
"git_index_verified": true
|
||||||
|
},
|
||||||
|
"missing_index_entry_rejected": true,
|
||||||
|
"clean_index_export": {
|
||||||
|
"result": "passed",
|
||||||
|
"upstream_commit": "f4e3193d49a98efcf2f16c2aa22d6085ebe70f36",
|
||||||
|
"application_baseline": "0.1.4-alpha",
|
||||||
|
"verified_files": 435,
|
||||||
|
"git_index_verified": false
|
||||||
|
},
|
||||||
|
"upstream_asset_sha256": "3e06555552c50c1f5abcac8a1d3fb2eedf7ff4a34c40d94859aa7d5082009a21",
|
||||||
|
"clean_export_bytes": 11050972,
|
||||||
|
"real_index_sha256_after_negative_test": "2633ae6ac5822ce1389418cf4faba97fbbfcc1eb7172c2852652f67060515000"
|
||||||
|
},
|
||||||
|
"monitoring_view": {
|
||||||
|
"url": "https://metrics.yebilly.me/d/group1-sre/group-1-sre",
|
||||||
|
"chrome_charts_rendered": [
|
||||||
|
"CPU utilization",
|
||||||
|
"available memory",
|
||||||
|
"root filesystem availability",
|
||||||
|
"HTTPS availability"
|
||||||
|
],
|
||||||
|
"window": "Last 30 minutes; 30-second refresh; America/New_York",
|
||||||
|
"attribution_limit": "Shared host; build 1 did not execute application compilation"
|
||||||
|
},
|
||||||
|
"remaining": [
|
||||||
|
"Human commit/push/review/merge of the asset and verifier correction",
|
||||||
|
"Real Jenkins rerun from corrected reviewed main",
|
||||||
|
"JUnit, stage, archive, download and source/version verification",
|
||||||
|
"Separate Jenkins core 2.580.2 security maintenance",
|
||||||
|
"Issue-linked product increment only after the baseline passes"
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
{
|
||||||
|
"authorized_by": "Vincent Sun",
|
||||||
|
"event_date_eastern": "2026-11-25",
|
||||||
|
"applied_at_utc": "2026-11-26T04:22:34.316662+00:00",
|
||||||
|
"change": "Append current SSH connection IPv4 as /32 to existing CI_TEAM_IPS web allowlist",
|
||||||
|
"personal_address_values_recorded": false,
|
||||||
|
"existing_team_entries": 1,
|
||||||
|
"new_team_entries": 2,
|
||||||
|
"existing_entries_preserved": true,
|
||||||
|
"compose_change_scope": "caddy environment CI_TEAM_IPS only",
|
||||||
|
"recreated_service": "caddy",
|
||||||
|
"validation": "passed",
|
||||||
|
"proxy_image_and_persistent_mounts_preserved": true,
|
||||||
|
"other_running_container_ids_preserved": true,
|
||||||
|
"proxy_and_compose_source_files_unchanged": true,
|
||||||
|
"root_only_rollback_directory": "/root/ssw590-web-access-20261125",
|
||||||
|
"public_checks_at_utc": "2026-11-26T04:25:17.0999004Z",
|
||||||
|
"home_anonymous_https": {
|
||||||
|
"https://ci.yebilly.me/login": 200,
|
||||||
|
"https://ci.yebilly.me/api/json": 403,
|
||||||
|
"https://metrics.yebilly.me/login": 200,
|
||||||
|
"https://metrics.yebilly.me/api/user": 401,
|
||||||
|
"https://git.yebilly.me/": 200,
|
||||||
|
"https://app.yebilly.me/health": 200,
|
||||||
|
"https://staging.yebilly.me/health": 200
|
||||||
|
},
|
||||||
|
"unlisted_droplet_source_https": {
|
||||||
|
"https://ci.yebilly.me/login": 403,
|
||||||
|
"https://metrics.yebilly.me/login": 403
|
||||||
|
},
|
||||||
|
"chrome_observation": {
|
||||||
|
"jenkins": "Sign in to Jenkins form visible",
|
||||||
|
"grafana": "Existing authenticated session reached Grafana home"
|
||||||
|
},
|
||||||
|
"account_permissions_or_credentials_changed": false,
|
||||||
|
"new_cloud_resources_or_plan_changes": false,
|
||||||
|
"source_commit_or_push_performed_by_codex": false
|
||||||
|
}
|
||||||
@@ -0,0 +1,104 @@
|
|||||||
|
# TikZRefinery Jenkins job
|
||||||
|
|
||||||
|
Use the separate [tikzrefinery-demo job](https://ci.yebilly.me/job/tikzrefinery-demo/).
|
||||||
|
It was created after verification of baseline PR #31's merge `d37297b`.
|
||||||
|
Existing pricing, recovery and multibranch jobs retain their configurations.
|
||||||
|
|
||||||
|
| Setting | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| Item type | Pipeline |
|
||||||
|
| Definition | Pipeline script from SCM; Git |
|
||||||
|
| Repository | `https://git.yebilly.me/ssw590-group1/vpn-dns-gateway.git` |
|
||||||
|
| Checkout credential | Existing `gitea-jenkins-bot`; no new credential |
|
||||||
|
| Branch | `*/main` |
|
||||||
|
| Script path | `demo/Jenkinsfile` |
|
||||||
|
| Lightweight checkout | Enabled |
|
||||||
|
| Triggers and parameters | None; trigger manually after review/merge |
|
||||||
|
| Agent | Existing `delivery-trusted` label, one executor |
|
||||||
|
| Concurrent builds | Disabled |
|
||||||
|
| Pipeline timeout and retention | 45 minutes; ten builds |
|
||||||
|
|
||||||
|
The pipeline definition supplies the label, timeout, retention, source gates,
|
||||||
|
stage sequence and report/artifact publishers. It binds no pricing deployment
|
||||||
|
or registry credentials and performs no pricing promotion. Keep reviewed `main`
|
||||||
|
as its SCM selection; do not switch it to a PR branch or use Replay to bypass
|
||||||
|
the source gate.
|
||||||
|
|
||||||
|
## Controller and worker prerequisites
|
||||||
|
|
||||||
|
The controller must provide the JUnit Pipeline step, in addition to the existing
|
||||||
|
Git, Declarative Pipeline and artifact archiving capabilities. Its official
|
||||||
|
[JUnit plugin](https://plugins.jenkins.io/junit/) consumes the CTest XML report;
|
||||||
|
it does not execute or replace the C++ tests. Use the compatible release offered
|
||||||
|
by this controller's official update center, with its required dependencies.
|
||||||
|
Record the actual installed version after verifying that installation completed.
|
||||||
|
Do not install a release requiring a newer Jenkins core by forcing compatibility.
|
||||||
|
|
||||||
|
On November 26, the official update center installed JUnit
|
||||||
|
`1458.1460.vd53b_087eeb_2c` and its eight required dependency plugins; installation
|
||||||
|
and loading extensions each reported success, and the installed JUnit entry was
|
||||||
|
enabled. The Pipeline Snippet Generator also lists the `junit` step, confirming
|
||||||
|
that it is available to pipelines. No restart was requested. This is the compatible version offered to the
|
||||||
|
existing Jenkins 2.580.1 controller, rather than a forced newer-core release.
|
||||||
|
|
||||||
|
The controller separately advertises a core update to 2.580.2 for the
|
||||||
|
[October 28 security advisory](https://www.jenkins.io/security/advisory/2026-10-28/).
|
||||||
|
That maintenance is still pending; installing JUnit does not apply a core update.
|
||||||
|
|
||||||
|
The existing worker needs Git, Python 3, Docker, its workspace volume and the two
|
||||||
|
image identities in `demo/toolchain.json`. `demo/ci/run-cloud.sh` verifies those
|
||||||
|
identities and maps its container workspace to the volume's actual host path.
|
||||||
|
Do not run `prepare-images.sh` merely to check readiness; rebuilding can change
|
||||||
|
the verified identities.
|
||||||
|
|
||||||
|
Before starting, confirm the agent is connected and idle, no manual Actions or
|
||||||
|
other heavy delivery build is running, and the existing host has space for the
|
||||||
|
new checkout, compiler outputs, image archive and Jenkins archive copy. Observe
|
||||||
|
available RAM and swap alongside the configured stage limits. The November 26
|
||||||
|
preflight observed 5.3 GiB available disk and about 687 MiB available RAM with
|
||||||
|
swap after the Actions build completed; these are historical observations, not
|
||||||
|
a permanent capacity guarantee. No new instance or plan is required.
|
||||||
|
|
||||||
|
The existing [Group 1 SRE dashboard](https://metrics.yebilly.me/d/group1-sre/group-1-sre?from=now-30m&to=now&refresh=30s&timezone=America%2FNew_York)
|
||||||
|
was checked in Chrome: CPU, available-memory, root-filesystem and HTTPS charts
|
||||||
|
rendered. Retain the 30-minute window and 30-second refresh for rehearsal, then
|
||||||
|
adjust the window to include the real build. These charts describe the shared
|
||||||
|
host; build 1 never reached application compilation, so its graph window must
|
||||||
|
not be presented as successful native-build load evidence.
|
||||||
|
|
||||||
|
## First run and correction
|
||||||
|
|
||||||
|
[Build 1](https://ci.yebilly.me/job/tikzrefinery-demo/1/) used reviewed main
|
||||||
|
`d37297b88993fd8c5428c2e732f32f4c9324b51b` and the real cloud agent. Checkout and
|
||||||
|
main ancestry verification passed. The snapshot gate correctly rejected the
|
||||||
|
missing `documents/assets/loop-example/loop-boxes.dvi`: the local file existed,
|
||||||
|
but `*.dvi` excluded it from Git. Its original upstream SHA-256 is
|
||||||
|
`3e06555552c50c1f5abcac8a1d3fb2eedf7ff4a34c40d94859aa7d5082009a21`.
|
||||||
|
Compilation and later stages were skipped. Post-processing then reported that
|
||||||
|
the `junit` step was unavailable. Preserve this failed build as evidence.
|
||||||
|
|
||||||
|
The prepared correction adds the exact upstream blob and a narrow ignore
|
||||||
|
exception, verifies both all 435 working files and their indexed blob identities,
|
||||||
|
and archives diagnostics before publishing test results. The original source
|
||||||
|
manifest and product code stay unchanged. Commit/push/review the correction
|
||||||
|
before the next baseline run from `main`.
|
||||||
|
|
||||||
|
## Verification after the reviewed correction
|
||||||
|
|
||||||
|
1. Record the triggering identity, current build URL, main revision and agent.
|
||||||
|
2. Confirm the first stage verifies the main ancestry and all 435 indexed/raw
|
||||||
|
upstream blobs. Observe the native, report, architecture and package stages.
|
||||||
|
3. Check the JUnit interface shows the eight expected passing suites. Keep
|
||||||
|
failures visible and inspect diagnostics rather than marking them successful.
|
||||||
|
4. Download this build's image archive, architecture ZIP, report, provenance and
|
||||||
|
`SHA256SUMS` through Jenkins. Run `demo/ci/verify-artifacts.py` against the
|
||||||
|
downloaded artifact folder, and compare its source/build identity with the UI.
|
||||||
|
5. Open a source-generated diagram and report. Show live shared-host monitoring
|
||||||
|
and retain the actual per-stage load CSVs and elapsed times.
|
||||||
|
6. Record the result, including cache reuse and shared-host limitations. A prior
|
||||||
|
Windows/SSH rehearsal is not a substitute for this Jenkins verification.
|
||||||
|
|
||||||
|
Only after the baseline passes should the separate issue-linked product
|
||||||
|
increment be prepared. Retain artifacts and required grading evidence; remove
|
||||||
|
only reproducible scratch from the current task. Never prune shared images,
|
||||||
|
volumes, runner identities or older evidence during preparation.
|
||||||
+2619
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,267 @@
|
|||||||
|
# Byte-compiled / optimized / DLL files
|
||||||
|
__pycache__/
|
||||||
|
*.py[codz]
|
||||||
|
*$py.class
|
||||||
|
|
||||||
|
# C extensions
|
||||||
|
*.so
|
||||||
|
|
||||||
|
# Distribution / packaging
|
||||||
|
.Python
|
||||||
|
build/
|
||||||
|
develop-eggs/
|
||||||
|
dist/
|
||||||
|
downloads/
|
||||||
|
eggs/
|
||||||
|
.eggs/
|
||||||
|
lib/
|
||||||
|
lib64/
|
||||||
|
parts/
|
||||||
|
sdist/
|
||||||
|
var/
|
||||||
|
wheels/
|
||||||
|
share/python-wheels/
|
||||||
|
*.egg-info/
|
||||||
|
.installed.cfg
|
||||||
|
*.egg
|
||||||
|
MANIFEST
|
||||||
|
|
||||||
|
# PyInstaller
|
||||||
|
# Usually these files are written by a python script from a template
|
||||||
|
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
||||||
|
*.manifest
|
||||||
|
*.spec
|
||||||
|
|
||||||
|
# Installer logs
|
||||||
|
pip-log.txt
|
||||||
|
pip-delete-this-directory.txt
|
||||||
|
|
||||||
|
# Unit test / coverage reports
|
||||||
|
htmlcov/
|
||||||
|
.tox/
|
||||||
|
.nox/
|
||||||
|
.coverage
|
||||||
|
.coverage.*
|
||||||
|
.cache
|
||||||
|
nosetests.xml
|
||||||
|
coverage.xml
|
||||||
|
*.cover
|
||||||
|
*.py.cover
|
||||||
|
.hypothesis/
|
||||||
|
.pytest_cache/
|
||||||
|
cover/
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
*.mo
|
||||||
|
*.pot
|
||||||
|
|
||||||
|
# Django stuff:
|
||||||
|
*.log
|
||||||
|
local_settings.py
|
||||||
|
db.sqlite3
|
||||||
|
db.sqlite3-journal
|
||||||
|
|
||||||
|
# Flask stuff:
|
||||||
|
instance/
|
||||||
|
.webassets-cache
|
||||||
|
|
||||||
|
# Scrapy stuff:
|
||||||
|
.scrapy
|
||||||
|
|
||||||
|
# Sphinx documentation
|
||||||
|
docs/_build/
|
||||||
|
|
||||||
|
# PyBuilder
|
||||||
|
.pybuilder/
|
||||||
|
target/
|
||||||
|
|
||||||
|
# Jupyter Notebook
|
||||||
|
.ipynb_checkpoints
|
||||||
|
|
||||||
|
# IPython
|
||||||
|
profile_default/
|
||||||
|
ipython_config.py
|
||||||
|
|
||||||
|
# pyenv
|
||||||
|
# For a library or package, you might want to ignore these files since the code is
|
||||||
|
# intended to run in multiple environments; otherwise, check them in:
|
||||||
|
# .python-version
|
||||||
|
|
||||||
|
# pipenv
|
||||||
|
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
||||||
|
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
||||||
|
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
||||||
|
# install all needed dependencies.
|
||||||
|
# Pipfile.lock
|
||||||
|
|
||||||
|
# UV
|
||||||
|
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
||||||
|
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
||||||
|
# commonly ignored for libraries.
|
||||||
|
# uv.lock
|
||||||
|
|
||||||
|
# poetry
|
||||||
|
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
||||||
|
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
||||||
|
# commonly ignored for libraries.
|
||||||
|
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
||||||
|
# poetry.lock
|
||||||
|
# poetry.toml
|
||||||
|
|
||||||
|
# pdm
|
||||||
|
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
||||||
|
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
||||||
|
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
||||||
|
# pdm.lock
|
||||||
|
# pdm.toml
|
||||||
|
.pdm-python
|
||||||
|
.pdm-build/
|
||||||
|
|
||||||
|
# pixi
|
||||||
|
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
||||||
|
# pixi.lock
|
||||||
|
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
||||||
|
# in the .venv directory. It is recommended not to include this directory in version control.
|
||||||
|
.pixi
|
||||||
|
|
||||||
|
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
||||||
|
__pypackages__/
|
||||||
|
|
||||||
|
# Celery stuff
|
||||||
|
celerybeat-schedule
|
||||||
|
celerybeat.pid
|
||||||
|
|
||||||
|
# Redis
|
||||||
|
*.rdb
|
||||||
|
*.aof
|
||||||
|
*.pid
|
||||||
|
|
||||||
|
# RabbitMQ
|
||||||
|
mnesia/
|
||||||
|
rabbitmq/
|
||||||
|
rabbitmq-data/
|
||||||
|
|
||||||
|
# ActiveMQ
|
||||||
|
activemq-data/
|
||||||
|
|
||||||
|
# SageMath parsed files
|
||||||
|
*.sage.py
|
||||||
|
|
||||||
|
# Environments
|
||||||
|
.env
|
||||||
|
.envrc
|
||||||
|
.venv
|
||||||
|
env/
|
||||||
|
venv/
|
||||||
|
ENV/
|
||||||
|
env.bak/
|
||||||
|
venv.bak/
|
||||||
|
|
||||||
|
# Spyder project settings
|
||||||
|
.spyderproject
|
||||||
|
.spyproject
|
||||||
|
|
||||||
|
# Rope project settings
|
||||||
|
.ropeproject
|
||||||
|
|
||||||
|
# mkdocs documentation
|
||||||
|
/site
|
||||||
|
|
||||||
|
# mypy
|
||||||
|
.mypy_cache/
|
||||||
|
.dmypy.json
|
||||||
|
dmypy.json
|
||||||
|
|
||||||
|
# Pyre type checker
|
||||||
|
.pyre/
|
||||||
|
|
||||||
|
# pytype static type analyzer
|
||||||
|
.pytype/
|
||||||
|
|
||||||
|
# Cython debug symbols
|
||||||
|
cython_debug/
|
||||||
|
|
||||||
|
# PyCharm
|
||||||
|
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
||||||
|
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
||||||
|
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
||||||
|
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
||||||
|
# .idea/
|
||||||
|
|
||||||
|
# Abstra
|
||||||
|
# Abstra is an AI-powered process automation framework.
|
||||||
|
# Ignore directories containing user credentials, local state, and settings.
|
||||||
|
# Learn more at https://abstra.io/docs
|
||||||
|
.abstra/
|
||||||
|
|
||||||
|
# Visual Studio Code
|
||||||
|
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
||||||
|
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
||||||
|
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
||||||
|
# you could uncomment the following to ignore the entire vscode folder
|
||||||
|
# .vscode/
|
||||||
|
# Temporary file for partial code execution
|
||||||
|
tempCodeRunnerFile.py
|
||||||
|
|
||||||
|
# Ruff stuff:
|
||||||
|
.ruff_cache/
|
||||||
|
|
||||||
|
# PyPI configuration file
|
||||||
|
.pypirc
|
||||||
|
|
||||||
|
# TikZRefinery: LaTeX-generated files
|
||||||
|
*.aux
|
||||||
|
*.bbl
|
||||||
|
*.bcf
|
||||||
|
*.blg
|
||||||
|
*.fdb_latexmk
|
||||||
|
*.fls
|
||||||
|
*.glg
|
||||||
|
*.glo
|
||||||
|
*.gls
|
||||||
|
*.idx
|
||||||
|
*.ilg
|
||||||
|
*.ind
|
||||||
|
*.ist
|
||||||
|
*.lof
|
||||||
|
*.lot
|
||||||
|
*.out
|
||||||
|
*.run.xml
|
||||||
|
*.synctex.gz
|
||||||
|
*.toc
|
||||||
|
*.xdv
|
||||||
|
|
||||||
|
# PDFs created beside LaTeX sources are disposable. The reviewed report at
|
||||||
|
# documents/TikZRefinery.pdf remains tracked.
|
||||||
|
documents/latex/*.pdf
|
||||||
|
documents/template/SeniorDesignReportTemplate.pdf
|
||||||
|
|
||||||
|
# Workspace-local document tools and caches
|
||||||
|
.tectonic-cache/
|
||||||
|
tools/tectonic*/
|
||||||
|
|
||||||
|
# Qt/C++ build products and local CMake configuration
|
||||||
|
code/build*/
|
||||||
|
code/packages/
|
||||||
|
code/CMakeUserPresets.json
|
||||||
|
*.user
|
||||||
|
|
||||||
|
# Completed coursework, local review material and workstation settings
|
||||||
|
/documents/submissions/
|
||||||
|
/documents/slides/
|
||||||
|
/code/tests/fixtures/demo2-pre-correction/
|
||||||
|
/.vscode/
|
||||||
|
/work/
|
||||||
|
|
||||||
|
# Operating-system metadata
|
||||||
|
.DS_Store
|
||||||
|
Thumbs.db
|
||||||
|
Desktop.ini
|
||||||
|
|
||||||
|
# Marimo
|
||||||
|
marimo/_static/
|
||||||
|
marimo/_lsp/
|
||||||
|
__marimo__/
|
||||||
|
|
||||||
|
# Streamlit
|
||||||
|
.streamlit/secrets.toml
|
||||||
@@ -0,0 +1,101 @@
|
|||||||
|
# TikZRefinery - Agent Instructions
|
||||||
|
|
||||||
|
## Working relationship
|
||||||
|
- A chat may span design, implementation, documentation and review. Continue
|
||||||
|
successive work items there; new chats and compaction-based restarts are optional.
|
||||||
|
- Explain significant design choices clearly, one decision at a time when asked.
|
||||||
|
Check existing decisions before reopening settled questions.
|
||||||
|
- Distinguish discussion, approved design and authorization to implement.
|
||||||
|
Once work is authorized, complete routine steps without repeated permission
|
||||||
|
requests; raise material scope changes or unresolved design choices.
|
||||||
|
|
||||||
|
## Authority and starting context
|
||||||
|
- Follow Vincent's current instructions and the controlled project requirements.
|
||||||
|
- Before modifying the project, read README.md and these authoritative sources:
|
||||||
|
- documents/latex/tkrAIAgentRequirements.tex (AI Directives; stable filename)
|
||||||
|
- documents/latex/tkrAIAgentGuide.tex
|
||||||
|
- documents/latex/tkrReportRoadmap.tex
|
||||||
|
- Read the smallest sufficient set of affected sources; expand for dependencies
|
||||||
|
or inconsistencies. Reuse current context already established and refresh it
|
||||||
|
when sources change or the task requires it.
|
||||||
|
- When resuming work, read HANDOFF.md and verify it against files and Git state.
|
||||||
|
Its proposed next action is not new authorization to implement.
|
||||||
|
- This file is the concise entry point. Detailed requirements and procedures
|
||||||
|
remain in their controlled sources; flag conflicts rather than silently
|
||||||
|
changing rules or maintaining contradictory copies.
|
||||||
|
|
||||||
|
## Preserve work and respect scope
|
||||||
|
- Inspect Git status before editing. Preserve unrelated uncommitted changes,
|
||||||
|
user-edited examples, submissions, evidence and designated baseline packages.
|
||||||
|
- Commit or push only when explicitly authorized for the current work.
|
||||||
|
- Focused audit, coursework and workflow chats stay within their assignment.
|
||||||
|
Do not replace the main development handoff's next action merely because
|
||||||
|
the chat was forked from it; preserve that state during authorized cleanup.
|
||||||
|
- A review request authorizes investigation and findings, not automatic fixes.
|
||||||
|
|
||||||
|
## Sources, evidence and readable documentation
|
||||||
|
- Use authored TeX for report information and generated PDFs for visual checks.
|
||||||
|
Do not extract PDF text to look up requirements or design decisions.
|
||||||
|
- Put settled decisions in the appropriate requirement registers, use cases,
|
||||||
|
tests and diagrams. Preserve stable IDs and reciprocal traceability.
|
||||||
|
- Use applicable UML notation in editable TikZ; route relationships with
|
||||||
|
horizontal/vertical segments and elbows, preserving arrow/ownership semantics.
|
||||||
|
- Prefer concise requirements and TikZ diagrams to duplicated narrative.
|
||||||
|
Use linked overview/detail views when they improve understanding.
|
||||||
|
- Separate implemented behavior, planned design and verified results. Attribute
|
||||||
|
recollections, stakeholder statements, sources and assumptions accurately.
|
||||||
|
AI-generated statements are not evidence.
|
||||||
|
- Record material assistance and decisions as required by the AI guide.
|
||||||
|
- For material design/code changes, follow its bidirectional change-impact review:
|
||||||
|
update affected records or record unchanged reviews and reasoned deferrals.
|
||||||
|
- Explicit design approval authorizes routine documentation updates under
|
||||||
|
AI-REQ-017 unless narrower instructions apply. Flag unclear approval or approved
|
||||||
|
decisions left undocumented; check linked diagram contents and status. This
|
||||||
|
does not authorize code, commits, pushing or external publication.
|
||||||
|
|
||||||
|
## Implementation conventions
|
||||||
|
- Follow code/CODING_GUIDE.md and applicable Developer Requirements: tkr class
|
||||||
|
names, descriptive identifier prefixes, private m_ members, named numeric
|
||||||
|
values, separate class files, inheritance limits and explicit ownership.
|
||||||
|
- Keep responsibilities bounded. Do not add inheritance or abstractions solely
|
||||||
|
to satisfy a naming pattern or arbitrary class/file size.
|
||||||
|
- Keep code and architectural documentation aligned. Identify which side needs
|
||||||
|
correction rather than assuming either is always current.
|
||||||
|
|
||||||
|
## Builds, checks and versions
|
||||||
|
- Use existing local toolchains before downloading or installing software.
|
||||||
|
- Configure the Qt/MinGW environment as described in code/README.md, then run:
|
||||||
|
- Build: cmake --build code/build --parallel 4
|
||||||
|
- Test: ctest --test-dir code/build --output-on-failure
|
||||||
|
- Use shared TinyTeX: C:\Users\vince\Documents\Projects\Tools\LaTeX\TinyTeX
|
||||||
|
- Report build from the repository root: ./documents/build-report.ps1
|
||||||
|
- For diagram lookup use documents/DIAGRAM_INDEX.md (generated source/status/
|
||||||
|
page index); classify new figures in documents/diagram-manifest.json. An index
|
||||||
|
does not replace whole-document review for material design changes/additions.
|
||||||
|
- After material report changes, build both editions, inspect diagnostics,
|
||||||
|
render affected pages and verify layout and navigation.
|
||||||
|
- Run checks appropriate to the change; report actual results and limitations.
|
||||||
|
- For visible application increments, refresh and launch a runnable package for
|
||||||
|
Vincent's review, following current package/baseline instructions.
|
||||||
|
- After Windows computer use, send the required completion summary and reset
|
||||||
|
the CUA session to release capture bindings. Do not recapture to check the border.
|
||||||
|
- Follow the version policy in Document History and the AI guide. Read current
|
||||||
|
metadata; do not hard-code the current version or test count here.
|
||||||
|
|
||||||
|
## Reviews and continuity
|
||||||
|
- Code reviews examine defects and regressions in a defined change. Architecture
|
||||||
|
audits compare requirements, diagrams, code and test evidence in both directions;
|
||||||
|
planned features are not automatically defects.
|
||||||
|
- Report actionable findings with references, evidence and unresolved questions.
|
||||||
|
- Refresh HANDOFF.md at meaningful stopping points and before transferring
|
||||||
|
unfinished work. Include date, branch/commit, uncommitted work, verified results,
|
||||||
|
limits, open decisions and the next proposed or authorized action.
|
||||||
|
- Keep that file a concise checkpoint. Put durable decisions and historical
|
||||||
|
evidence in their authoritative records; retain a dated snapshot when stale.
|
||||||
|
|
||||||
|
## Workspace cleanup
|
||||||
|
- Keep reproducible scratch in a clearly named task-local work directory.
|
||||||
|
- Remove only verified, reproducible scratch created for the current work;
|
||||||
|
validate absolute cleanup paths and preserve anything awaiting review.
|
||||||
|
- Retain deliverables, editable sources and required evidence. Report cleanup
|
||||||
|
and intentionally retained temporary material.
|
||||||
@@ -0,0 +1,99 @@
|
|||||||
|
# Changelog
|
||||||
|
|
||||||
|
Notable project changes are recorded here, newest first. Entries distinguish
|
||||||
|
implemented application behavior from reviewed designs and documentation changes.
|
||||||
|
Detailed report revisions remain in
|
||||||
|
[Document History](documents/latex/tkrDocumentHistory.tex).
|
||||||
|
|
||||||
|
## 0.1.4-alpha - November 24, 2026
|
||||||
|
|
||||||
|
Documentation audit (version retained at Vincent's request):
|
||||||
|
|
||||||
|
- Matched the reviewed course template's front-matter order: contents, generated
|
||||||
|
List of Tables, then List of Figures; refreshed both editions and diagram pages.
|
||||||
|
- Reconciled all active report figures with current code and reviewed design;
|
||||||
|
replaced the active frozen deployment with current 3D physical/module views.
|
||||||
|
- Added the current Undo/Redo candidate sequence and corrected edit/Open/Save
|
||||||
|
history boundaries, typed lifelines, planned labels and connector spacing.
|
||||||
|
- Added a List of Figures and a build-generated source/status/page index, with
|
||||||
|
an explicit manifest for new diagrams. Whole-document design review remains
|
||||||
|
required; the application, packages and historical evidence are unchanged.
|
||||||
|
|
||||||
|
Implementation follow-up against the agreed report baseline:
|
||||||
|
|
||||||
|
- Refreshed Demo 3 for the working Alpha; moved the live demonstration directly
|
||||||
|
after progress. Moved full Document History to Appendix A with a separate
|
||||||
|
front-matter version paragraph/link, and recorded Milestone 3 coverage.
|
||||||
|
|
||||||
|
- Added document-owned session undo/redo for completed moves and rectangle
|
||||||
|
resizing, exact source snapshots, atomic acceptance and standard Edit shortcuts.
|
||||||
|
- Save retains history; successful Open clears it; changed edits after Undo drop
|
||||||
|
the abandoned redo branch. No automatic eviction yet, as approved.
|
||||||
|
- Passed eight Debug and eight Release suites; built the matching runnable
|
||||||
|
package. Added a viewport repaint to clear stale selection handles after restoration.
|
||||||
|
- Updated current architecture/evidence while retaining generic transactions and
|
||||||
|
file-store extraction as planned. Preserved prior packages and report baselines.
|
||||||
|
|
||||||
|
Earlier documentation-only reconciliation:
|
||||||
|
|
||||||
|
- Reconciled agreed undo/redo architecture with planned class, activity and
|
||||||
|
separate new-edit and history-restoration sequence views.
|
||||||
|
- Corrected stale class labels/counts, provider/source boundaries and the future
|
||||||
|
compile-on-save path. Clarified that implementation details remain open.
|
||||||
|
- Strengthened AI-REQ-017 and AGENTS.md: approved designs trigger routine report
|
||||||
|
updates; unclear approval or missing documentation must be flagged.
|
||||||
|
- Preserved the 0.1.3-alpha app, Demo 3 and matching reports. Documentation only;
|
||||||
|
no undo/redo implementation, package rebuild or new application test results.
|
||||||
|
|
||||||
|
## 0.1.3-alpha — November 23, 2026 implementation follow-up
|
||||||
|
|
||||||
|
- Implemented the collapsible Shapes/Files sidebar shell with Qt standard icons,
|
||||||
|
retained session page/width, rectangle-provider status and guarded Open.
|
||||||
|
- Kept creation disabled and folder browsing as an explicit placeholder.
|
||||||
|
Catalogue/creation and shared-service ownership remain planned.
|
||||||
|
- Passed all seven Debug and Release suites; checked the running package,
|
||||||
|
collapse/reopen, page switching, unsaved-work guard and About identity.
|
||||||
|
- Refreshed current architecture/UI views, both report editions and local Demo 3
|
||||||
|
material. Preserved the prior reports and identity-only demo binary evidence,
|
||||||
|
older packages and edited examples. No commit/push/upload in this follow-up.
|
||||||
|
|
||||||
|
## 0.1.3-alpha — November 22, 2026
|
||||||
|
|
||||||
|
Documentation release, completed November 23. The application and its packages
|
||||||
|
remain at 0.1.2-alpha; the frozen 0.10.3 demonstration package is preserved.
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- Reviewed designs for a collapsible Shapes/Files sidebar, shape catalogue,
|
||||||
|
click/drag creation, cancellation, boundary fitting and rejection/retry.
|
||||||
|
- Planned shared-service ownership, class responsibilities, MVC allocation,
|
||||||
|
catalogue data records and creation activity, with editable UML and UI sketches.
|
||||||
|
- Seven product requirements, linked planned checks and reciprocal traceability.
|
||||||
|
- AI directive AI-REQ-017 and a bidirectional change-impact review checklist.
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Renamed the displayed AI requirements appendix and register to AI Directives,
|
||||||
|
preserving existing identifiers and references.
|
||||||
|
- Updated architecture, use cases, validation plans, roadmap, glossary and project
|
||||||
|
guidance; rebuilt both architectural report editions.
|
||||||
|
- Recorded default Qt styling, deferred Qlementine and kept icon selection open.
|
||||||
|
|
||||||
|
The sidebar and creation workflow are planned, not implemented. New-document
|
||||||
|
behavior, insertion contexts, folder interactions and API/construction details
|
||||||
|
remain open. The original documentation pass changed no application source or
|
||||||
|
package.
|
||||||
|
|
||||||
|
### Demo preparation — November 23, 2026
|
||||||
|
|
||||||
|
- Updated Demo 3 around the required diagrams and a live Alpha showcase, opening
|
||||||
|
with progress since Demo 2. Retained the earlier demo sources and packages.
|
||||||
|
- Preserved vector diagrams in the demo PDF and live slide assets to improve
|
||||||
|
clarity when enlarged, without changing the presentation content.
|
||||||
|
- Built a fresh 0.1.3-alpha Windows package from the unchanged feature source at
|
||||||
|
checkpoint `7a2965a`, matching the architectural baseline. Sidebar and creation
|
||||||
|
remain planned. Six Release test suites and a bounded native edit/save/reopen
|
||||||
|
check passed. This rebuild adds no application feature implementation.
|
||||||
|
|
||||||
|
This changelog begins with 0.1.3-alpha. Earlier changes remain in Document History
|
||||||
|
and Git history; historical versions have not been renumbered.
|
||||||
@@ -0,0 +1,131 @@
|
|||||||
|
# TikZRefinery snapshot for the DevOps demonstration
|
||||||
|
|
||||||
|
Prepared November 25, 2026 for Vincent's SSW 590 workflow demonstration.
|
||||||
|
The application and architectural baseline remain **0.1.4-alpha**.
|
||||||
|
Use the full Git commit ID supplied with this checkpoint as the frozen upstream
|
||||||
|
identity. This is an input to the DevOps project, not a new pipeline or release.
|
||||||
|
|
||||||
|
## What the snapshot provides
|
||||||
|
|
||||||
|
- C++17/Qt Widgets editor, separate rectangle provider module, constrained
|
||||||
|
move/resize, collapsible sidebar shell and exact-source session undo/redo.
|
||||||
|
- Eight CTest suites, including actual module loading and negative compatibility
|
||||||
|
cases. Offscreen GUI tests do not establish interactive or full product acceptance.
|
||||||
|
- Authored LaTeX, editable UML/TikZ, report build script, diagram manifest/index
|
||||||
|
and the two reviewed report PDFs.
|
||||||
|
- Existing project attribution, course-material notices and dependency information.
|
||||||
|
No project-wide licence has been selected; this checkpoint does not grant one.
|
||||||
|
|
||||||
|
Creation, folder browsing, generic transactions, plugin updating and integrated
|
||||||
|
LaTeX/PDF viewing remain planned. Do not present the sidebar shell as creation.
|
||||||
|
|
||||||
|
## Transfer and provenance
|
||||||
|
|
||||||
|
Keep TikZRefinery's main development here. Import the exact checkpoint into the
|
||||||
|
existing DevOps repository, retaining the upstream repository URL, full commit
|
||||||
|
ID, baseline version and attribution in that repository's import record.
|
||||||
|
|
||||||
|
The other local chat can fetch from
|
||||||
|
`C:/Users/vince/Documents/Projects/TikZRefinery` without a GitHub push. A Git
|
||||||
|
fetch transfers objects and refs; an unrelated DevOps history should consume a
|
||||||
|
documented snapshot rather than merging TikZRefinery's main branch blindly.
|
||||||
|
GitHub remote: `https://github.com/Generic-Sun/TikZRefinery.git`.
|
||||||
|
|
||||||
|
The old runnable packages and their build metadata are historical evidence.
|
||||||
|
They still identify their original parent commit and modified working tree;
|
||||||
|
creating this checkpoint does not relabel or rebuild those binaries. Build the
|
||||||
|
new demonstration artifact from the frozen source. If importing into another
|
||||||
|
repository, retain this upstream identity separately from that pipeline's commit.
|
||||||
|
|
||||||
|
## Verified Windows build
|
||||||
|
|
||||||
|
Run from the TikZRefinery checkout root in PowerShell with the installed matching
|
||||||
|
Qt/MinGW kit. These are the existing workstation paths, not portable defaults:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
$env:Path = 'C:\Qt\6.12.0\mingw_64\bin;C:\Qt\Tools\mingw1310_64\bin;C:\Qt\Tools\Ninja;' + $env:Path
|
||||||
|
& C:\Qt\Tools\CMake_64\bin\cmake.exe -S code -B work/devops-build -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=C:/Qt/6.12.0/mingw_64 -DCMAKE_CXX_COMPILER=C:/Qt/Tools/mingw1310_64/bin/g++.exe -DCMAKE_MAKE_PROGRAM=C:/Qt/Tools/Ninja/ninja.exe
|
||||||
|
& C:\Qt\Tools\CMake_64\bin\cmake.exe --build work/devops-build --parallel 4
|
||||||
|
& C:\Qt\Tools\CMake_64\bin\ctest.exe --test-dir work/devops-build --output-on-failure
|
||||||
|
```
|
||||||
|
|
||||||
|
Stop on any failed command. The verified kit is Qt 6.12.0, GCC 13.1.0,
|
||||||
|
CMake 3.30.5 and Ninja 1.12.1. Project minima are CMake 3.21, C++17 and Qt 6.2
|
||||||
|
Core/Widgets. A Linux/cloud application build is **not verified** by this record;
|
||||||
|
the DevOps chat must select and prove its own worker configuration.
|
||||||
|
|
||||||
|
Use the runnable package procedure in [code/README.md](code/README.md): deploy
|
||||||
|
the Qt/compiler runtime and matching `shape-plugins/tkr_rectangle.dll` alongside
|
||||||
|
the application. A standalone development executable is not a portable artifact.
|
||||||
|
Build the host/provider with compatible kit and configuration. Keep fresh
|
||||||
|
`build-info.json` with the artifact and retain pipeline test reports.
|
||||||
|
|
||||||
|
## Report stage
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
./documents/build-report.ps1 -OutputDirectory work/devops-report
|
||||||
|
```
|
||||||
|
|
||||||
|
The script uses shared TinyTeX at
|
||||||
|
`C:/Users/vince/Documents/Projects/Tools/LaTeX/TinyTeX/bin/windows`, PowerShell
|
||||||
|
and standard-library Python. It runs the bibliography/index and final LaTeX
|
||||||
|
passes, builds both editions, generates a versioned report ZIP, and refreshes
|
||||||
|
the diagram index. For a different worker, provide its TinyTeX path using
|
||||||
|
`-TinyTeXBin`; do not assume this workstation's installation exists there.
|
||||||
|
|
||||||
|
## Workflow boundaries and checks
|
||||||
|
|
||||||
|
The DevOps chat's reviewed direction is a frozen input followed by an issue,
|
||||||
|
planned-change comment, meaningful enhancement, commit/push, pipeline, tests and
|
||||||
|
versioned artifact. That enhancement and pipeline integration are separate work;
|
||||||
|
this source checkpoint alone does not demonstrate the complete workflow.
|
||||||
|
|
||||||
|
The pipeline's required `major.minor.changelist` delivery identifier must be
|
||||||
|
recorded separately from the upstream `0.1.4-alpha` baseline, not used to rewrite
|
||||||
|
TikZRefinery's historical version. Authored TikZ diagrams are not evidence of
|
||||||
|
architecture extraction from source; the optional extraction bonus needs its own
|
||||||
|
tool and verified output.
|
||||||
|
|
||||||
|
Keep the requested provider naming correction for the separate demo change:
|
||||||
|
`tkrRectangleShapeProvider` to `tkrShapeProviderRectangle`. Update the class,
|
||||||
|
matching header/implementation names, both CMake target references and affected
|
||||||
|
current documentation together; run the eight suites and verify the actual
|
||||||
|
module still loads. The class name is distinct from the DLL filename, provider
|
||||||
|
ID and interface contract; this proposal does not require changing those public
|
||||||
|
identities. Have the DevOps chat confirm this choice, prepare the issue/comment
|
||||||
|
and rehearse the change after its baseline pipeline works. It is not implemented
|
||||||
|
in this checkpoint. The assignment permits a code or LaTeX change and manual or
|
||||||
|
automatic pipeline triggering; reserve the final commit/push for that workflow.
|
||||||
|
|
||||||
|
November 25 checks: a fresh Windows Release build passed all eight suites;
|
||||||
|
the existing Debug build also passed all eight. Report sources and the canonical
|
||||||
|
PDFs match the November 24 complete TinyTeX/visual/navigation checks (258-page
|
||||||
|
submission, 327-page developer edition, 51 figures). No new report build,
|
||||||
|
native application review, package refresh or cloud build is claimed here.
|
||||||
|
Machine-readable checks and test output are under
|
||||||
|
`code/tests/evidence/devops-snapshot-2026-11-25/`.
|
||||||
|
The audit script there checks this workstation's retained protected files as
|
||||||
|
well as staged build inputs; it is not a portable CI test. Use CTest for the
|
||||||
|
imported application and establish the DevOps pipeline's own artifact checks.
|
||||||
|
|
||||||
|
This commit includes source, reports and compact evidence. Existing local
|
||||||
|
contact sheets, backup patches, submissions, slides and installed packages are
|
||||||
|
preserved outside the snapshot selection. Their omission does not remove the
|
||||||
|
application, report inputs or automated tests required to reproduce builds.
|
||||||
|
|
||||||
|
## Maintenance impact and AI-assistance record
|
||||||
|
|
||||||
|
Vincent authorized a commit usable by his DevOps chat and permitted reading it
|
||||||
|
for context. The relevant chat is **Main**, in `vpn-dns-gateway`; its latest
|
||||||
|
discussion chooses a frozen TikZRefinery input for the existing DevOps repository.
|
||||||
|
It was read without sending a message or changing that project.
|
||||||
|
|
||||||
|
This is a repository checkpoint of previously implemented, documented and logged
|
||||||
|
work, with fresh build checks and transfer guidance. Product requirements,
|
||||||
|
stories, use cases, contracts, class/MVC/behavior diagrams, test definitions and
|
||||||
|
verification/validation statuses were reviewed unchanged. No design or product
|
||||||
|
behavior is added. Report metadata, historical prompt log and canonical PDFs are
|
||||||
|
preserved at their already-reviewed baseline; this maintenance record and the
|
||||||
|
Git commit record the new assistance without regenerating graded artifacts.
|
||||||
|
README and HANDOFF link the checkpoint. No push, external publication, package
|
||||||
|
deletion, pipeline execution or message to the DevOps chat is authorized here.
|
||||||
@@ -0,0 +1,84 @@
|
|||||||
|
# TikZRefinery - current checkpoint
|
||||||
|
|
||||||
|
Updated November 25, 2026. Branch main; checkpoint parent
|
||||||
|
7a2965a4f14e8ac8ca6dbb531e605b91ee6dccb3. Vincent authorized a local commit
|
||||||
|
of the current 0.1.4-alpha baseline for his DevOps demonstration. Its resulting
|
||||||
|
identity is available from Git history; no push is authorized.
|
||||||
|
Read AGENTS.md, README and controlled directives/guide/roadmap; verify Git/files.
|
||||||
|
|
||||||
|
## DevOps source checkpoint
|
||||||
|
|
||||||
|
Read the DevOps chat Main in vpn-dns-gateway: use an exact TikZRefinery input
|
||||||
|
with provenance in the existing DevOps repository. DEVOPS_SNAPSHOT.md provides
|
||||||
|
the handoff, build/report prerequisites, package/identity boundaries and reviewed
|
||||||
|
unchanged impact record. Fresh Windows Release build: eight suites passed;
|
||||||
|
existing Debug build: eight passed. Evidence: code/tests/evidence/devops-snapshot-2026-11-25/.
|
||||||
|
No application feature or report-source changes were made for this checkpoint;
|
||||||
|
canonical PDFs remain the verified November 24 outputs. No package is rebuilt,
|
||||||
|
relabelled or deleted. Existing large review images and backup patches remain
|
||||||
|
local, outside the compact commit selection; coursework/slides/packages remain
|
||||||
|
ignored. No other chat was messaged and no DevOps project file was changed.
|
||||||
|
|
||||||
|
Next action for DevOps: fetch this local checkpoint or, after Vincent pushes it,
|
||||||
|
the GitHub commit; prove its chosen worker's build/test/package stages before
|
||||||
|
the issue-to-artifact rehearsal. Reserve the proposed provider-class suffix
|
||||||
|
rename for the separately issue-linked demo change; it is not implemented here.
|
||||||
|
Main TikZRefinery feature work remains a separate
|
||||||
|
authorization. All earlier package-cleanup limits below still apply.
|
||||||
|
|
||||||
|
## Completed: course-template front-matter lists
|
||||||
|
|
||||||
|
Vincent requested inspection of his previous-course DesignBook template open in
|
||||||
|
Chrome/Overleaf. Read its prologue without editing: contentspage, tablelistpage,
|
||||||
|
figurelistpage. The retained local template and active Cornell class support the
|
||||||
|
same order. Browser control was released and CUA reset; Overleaf is unchanged.
|
||||||
|
|
||||||
|
Both canonical reports remain 0.1.4-alpha. Front matter is now Contents -> List of
|
||||||
|
Tables -> List of Figures, with generated captions, numbering, hyperlinks and
|
||||||
|
PDF bookmarks. Added captions/stable labels to fourteen existing technical tables
|
||||||
|
(including seven use-case specifications). Three local 11-point table formats
|
||||||
|
avoid orphaned rows/following text. Original table bodies and product mappings
|
||||||
|
are preserved. RPT-049 is Done; product and AI directive statuses are unchanged.
|
||||||
|
|
||||||
|
Canonical PDFs: documents/TikZRefinery.pdf (258 pages, 61 listed tables/51 figures)
|
||||||
|
and TikZRefinery-Developers-Edition.pdf (327 pages, 65 tables/51 figures).
|
||||||
|
The diagram index was regenerated for the new pagination. The reader-facing
|
||||||
|
lists complement its editable-source/status data, not replace it. Broader design
|
||||||
|
changes/additions still require whole-document impact and visual review.
|
||||||
|
|
||||||
|
Checks: complete TinyTeX sequence in both editions; all list and internal named
|
||||||
|
links and all 51 diagram page mappings resolve. No errors, unresolved references/
|
||||||
|
citations, duplicate destinations, overfull boxes or oversized floats. Five
|
||||||
|
underfull notices each were visually checked. Affected navigation, captioned
|
||||||
|
tables, history, roadmap and internal guide/log pages reviewed. All 756 protected
|
||||||
|
source, diagram, package, slide and archive files match their recorded hashes.
|
||||||
|
No application tests rerun, code/package change, commit, push or cloud edit.
|
||||||
|
|
||||||
|
Evidence/checks/contact sheets/cleanup and the previous checkpoint:
|
||||||
|
documents/assets/front-matter-lists-2026-11-24/.
|
||||||
|
Pre-task reports: documents/submissions/baselines/architecture-0.1.4-alpha-before-table-list-2026-11-24/.
|
||||||
|
Final dated reports: documents/submissions/architecture-0.1.4-alpha-front-matter-lists-2026-11-24/.
|
||||||
|
|
||||||
|
## Previous completed audit and implementation state
|
||||||
|
|
||||||
|
The diagram audit reconciled all 51 active figures, current 3D physical/module
|
||||||
|
deployment, candidate/source/history acceptance, current Undo/Redo, Open/Save
|
||||||
|
history effects, typed lifelines and planned-design labels. Its evidence and
|
||||||
|
frozen predecessor sources remain in documents/assets/diagram-audit-2026-11-24/.
|
||||||
|
Use documents/DIAGRAM_INDEX.md and diagram-index.json for current page locations;
|
||||||
|
maintain diagram-manifest.json when adding views. Complete report builds refresh
|
||||||
|
these using final auxiliary/shipout records and reject changed build inputs.
|
||||||
|
|
||||||
|
Existing uncommitted 0.1.4-alpha implementation is preserved: rectangle DLL,
|
||||||
|
sidebar shell and bounded session history; eight Debug/eight Release suites in
|
||||||
|
prior dated evidence. Thirteen host classes plus provider interface/module.
|
||||||
|
Scene-owned plugin store; creation disabled. Catalogue/shared services, generic
|
||||||
|
transactions, folder browsing, provider updating and compiler/PDF remain planned.
|
||||||
|
Actual tkrRectangleShapeProvider still needs the coordinated requested
|
||||||
|
tkrShapeProviderRectangle rename in a later authorized code/files/build/test task.
|
||||||
|
DLL filename/plugin ID are separate. Prior reports/decks/packages remain intact.
|
||||||
|
|
||||||
|
Next proposed action: Vincent reviews the refreshed reports, then authorizes any
|
||||||
|
implementation or final-demo work. Earlier package cleanup remains unresolved
|
||||||
|
because his request ended at 'though add'. Do not infer deletion or commit/push
|
||||||
|
permission from this documentation follow-up.
|
||||||
@@ -0,0 +1,135 @@
|
|||||||
|
# TikZRefinery
|
||||||
|
|
||||||
|
TikZRefinery is a Stevens Senior Design project developing a desktop editor for
|
||||||
|
graphically refining TikZ diagrams while preserving editable TikZ source.
|
||||||
|
It aims to make precise layout changes easier, including corrections to diagrams
|
||||||
|
that begin as AI-generated code. The project uses C++17 and Qt Widgets.
|
||||||
|
|
||||||
|
## Current capabilities
|
||||||
|
|
||||||
|
The Alpha supports a conservative subset of explicit-coordinate TikZ:
|
||||||
|
|
||||||
|
- Display rectangles, straight lines and default arrows in centimetres.
|
||||||
|
- Load rectangle presentation, selection, movement and resizing from a separate
|
||||||
|
native shape plugin through the Qt Core SDK.
|
||||||
|
- Move supported shapes and resize rectangles using corner handles.
|
||||||
|
- Flip rectangles when corners cross, retain thin minimum dimensions, and stop
|
||||||
|
edits at the furthest valid position inside a declared editing boundary.
|
||||||
|
- Collapse/reopen a Shapes/Files sidebar, retain its page/width during the session,
|
||||||
|
inspect rectangle-provider status and open files through the existing unsaved-work guard.
|
||||||
|
- Fit the canvas to its pane, preview gestures, cancel edits, and save/reopen
|
||||||
|
source while preserving unrelated bytes and checking observed external changes.
|
||||||
|
|
||||||
|
Session undo/redo restores exact source for completed moves/resizes; Save retains
|
||||||
|
history and successful Open clears it. History has no automatic eviction yet.
|
||||||
|
|
||||||
|
Broader TikZ syntax, label and endpoint editing, provider management, manual
|
||||||
|
zoom controls, and integrated LaTeX compilation/PDF viewing remain unfinished.
|
||||||
|
Existing test evidence covers the bounded subset; it does not establish full
|
||||||
|
product acceptance. See [the code overview](code/README.md) for details.
|
||||||
|
|
||||||
|
## Build and run
|
||||||
|
|
||||||
|
Use the matching Qt 6/MinGW kit, CMake and Ninja described in
|
||||||
|
[code/README.md](code/README.md). That guide provides the verified Windows setup,
|
||||||
|
build/test commands, startup examples and portable package procedure.
|
||||||
|
|
||||||
|
For an already configured environment, from the repository root:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
cmake --build code/build --parallel 4
|
||||||
|
ctest --test-dir code/build --output-on-failure
|
||||||
|
```
|
||||||
|
|
||||||
|
The development executable needs the Qt/compiler runtime environment. A deployed
|
||||||
|
Windows package includes those dependencies; keep its executable with its runtime
|
||||||
|
files. Preserve user-edited examples when refreshing a package.
|
||||||
|
|
||||||
|
## Repository structure
|
||||||
|
|
||||||
|
```text
|
||||||
|
TikZRefinery/
|
||||||
|
|-- README.md Project introduction and getting started
|
||||||
|
|-- CHANGELOG.md Notable changes by version
|
||||||
|
|-- AGENTS.md Instructions for AI-assisted work
|
||||||
|
|-- HANDOFF.md Current unfinished-work checkpoint
|
||||||
|
|-- documents/
|
||||||
|
| |-- TikZRefinery.pdf Submission edition of the architectural report
|
||||||
|
| |-- TikZRefinery-Developers-Edition.pdf
|
||||||
|
| |-- latex/ Authoritative report sources
|
||||||
|
| |-- assets/ Editable diagrams and retained evidence
|
||||||
|
| `-- template/ Original course materials
|
||||||
|
`-- code/
|
||||||
|
|-- src/ Application source
|
||||||
|
|-- tests/ Automated checks and evidence
|
||||||
|
|-- examples/ Supported TikZ samples
|
||||||
|
`-- resources/ Application resources
|
||||||
|
```
|
||||||
|
|
||||||
|
## Architecture and documentation
|
||||||
|
|
||||||
|
- [Changelog](CHANGELOG.md), distinguishing delivered behavior from planned design
|
||||||
|
- [Submission report](documents/TikZRefinery.pdf)
|
||||||
|
- [Developer's edition](documents/TikZRefinery-Developers-Edition.pdf), including
|
||||||
|
the internal AI directives, operating guide and assistance log
|
||||||
|
- [Coding conventions](code/CODING_GUIDE.md)
|
||||||
|
|
||||||
|
The authored TeX and editable TikZ diagrams are the documentation sources.
|
||||||
|
[Diagram index](documents/DIAGRAM_INDEX.md) locates every active figure, source,
|
||||||
|
reviewed status and page in both report editions. After its contents, the report
|
||||||
|
provides generated Lists of Tables and Figures with linked page locations.
|
||||||
|
Builds refresh the index from the [manifest](documents/diagram-manifest.json)
|
||||||
|
and final LaTeX records using standard-library Python. Classify new figures in
|
||||||
|
the manifest. Broader design changes still require whole-document review.
|
||||||
|
Build both report editions using the existing shared TinyTeX installation:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
./documents/build-report.ps1
|
||||||
|
```
|
||||||
|
|
||||||
|
The script completes the bibliography/index sequence and writes PDFs, a versioned
|
||||||
|
submission ZIP and build results under `work/`. After a material report change,
|
||||||
|
check diagnostics, layout and navigation before replacing the published PDFs.
|
||||||
|
Version policy and revision history are maintained in
|
||||||
|
[Document History](documents/latex/tkrDocumentHistory.tex); the application build
|
||||||
|
reads its architectural baseline from the report metadata. Feature-based
|
||||||
|
numbering and the frozen-package exception are controlled in Document History;
|
||||||
|
rectangle extraction is implemented in `code/packages/0.1.2-alpha/`; the
|
||||||
|
frozen 0.10.3 demonstration package is preserved.
|
||||||
|
|
||||||
|
The [reviewed plugin contract](documents/latex/tkrPluginDesign.tex) separates
|
||||||
|
the current rectangle extraction and later palette/creation
|
||||||
|
and update features. Its requirements, UML views and planned checks are linked
|
||||||
|
from the report. The [sidebar and creation design](documents/latex/tkrSidebarDesign.tex)
|
||||||
|
now includes an implemented shell in `code/packages/0.1.3-alpha/`. Creation is
|
||||||
|
disabled and folder browsing is a placeholder; catalogue/creation and shared
|
||||||
|
service ownership remain planned. Seven suites pass in Debug and Release.
|
||||||
|
[Shell evidence](code/tests/evidence/sidebar-shell-2026-11-23/README.md) records
|
||||||
|
the scope and native review. Earlier packages remain unchanged; Qt standard
|
||||||
|
icons are used. Demo materials remain local under `documents/slides/demo3/`.
|
||||||
|
|
||||||
|
The report and application now share **0.1.4-alpha**, implementing bounded
|
||||||
|
session undo/redo for completed coordinate edits. Generic transactions remain
|
||||||
|
planned. Demo 3 now presents **0.1.4-alpha**, with the live showcase immediately
|
||||||
|
after progress. Earlier slides/reports remain preserved. Submit the slide PDF
|
||||||
|
for Demo 3 and the canonical submission report for Milestone 3; neither has been
|
||||||
|
uploaded by the agent. The complete Document History is now Appendix A, linked
|
||||||
|
from its distinct front-matter version page.
|
||||||
|
|
||||||
|
## Working on the project
|
||||||
|
|
||||||
|
For the frozen 0.1.4-alpha input to the separate DevOps demonstration, see
|
||||||
|
[snapshot and build guidance](DEVOPS_SNAPSHOT.md). Its source checkpoint does
|
||||||
|
not relabel the preserved packages or establish a cloud-build result.
|
||||||
|
|
||||||
|
AI agents start with [AGENTS.md](AGENTS.md). For continuation of unfinished work,
|
||||||
|
consult [HANDOFF.md](HANDOFF.md) and verify it against current sources and Git
|
||||||
|
state. One chat may cover design, implementation and review across several work
|
||||||
|
items; starting another chat is optional. The handoff is a dated checkpoint,
|
||||||
|
while requirements and architectural decisions remain in the report.
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
No project-wide license has been selected. Original project work remains under
|
||||||
|
the applicable default copyright rules. Third-party and course-provided
|
||||||
|
materials retain their own terms and notices.
|
||||||
@@ -0,0 +1,147 @@
|
|||||||
|
cmake_minimum_required(VERSION 3.21)
|
||||||
|
set(strReportSource "${CMAKE_CURRENT_SOURCE_DIR}/../documents/latex/TikZRefinery.tex")
|
||||||
|
file(STRINGS "${strReportSource}" strVersionLine REGEX "^\\\\newcommand\{\\\\DocumentVersion\}")
|
||||||
|
string(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+(-[A-Za-z0-9.-]+)?" strDocumentVersion "${strVersionLine}")
|
||||||
|
string(REGEX MATCH "[0-9]+\\.[0-9]+\\.[0-9]+" strProjectVersion "${strDocumentVersion}")
|
||||||
|
if(NOT strProjectVersion)
|
||||||
|
message(FATAL_ERROR "Cannot read the shared project version from the report source")
|
||||||
|
endif()
|
||||||
|
project(TikZRefinery VERSION ${strProjectVersion} LANGUAGES CXX)
|
||||||
|
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS "${strReportSource}")
|
||||||
|
|
||||||
|
find_package(Git QUIET)
|
||||||
|
add_custom_target(tikzrefinery_build_info
|
||||||
|
COMMAND "${CMAKE_COMMAND}"
|
||||||
|
"-DSOURCE_ROOT=${CMAKE_CURRENT_SOURCE_DIR}/.."
|
||||||
|
"-DBINARY_ROOT=${CMAKE_CURRENT_BINARY_DIR}"
|
||||||
|
"-DPROJECT_VERSION=${PROJECT_VERSION}"
|
||||||
|
"-DREPORT_VERSION=${strDocumentVersion}"
|
||||||
|
"-DGIT_EXECUTABLE=${GIT_EXECUTABLE}"
|
||||||
|
-P "${CMAKE_CURRENT_SOURCE_DIR}/cmake/WriteBuildInfo.cmake"
|
||||||
|
BYPRODUCTS "${CMAKE_CURRENT_BINARY_DIR}/generated/BuildInfo.h"
|
||||||
|
"${CMAKE_CURRENT_BINARY_DIR}/build-info.json"
|
||||||
|
VERBATIM)
|
||||||
|
|
||||||
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||||
|
set(CMAKE_AUTOMOC ON)
|
||||||
|
|
||||||
|
find_package(Qt6 6.2 REQUIRED COMPONENTS Core Widgets)
|
||||||
|
|
||||||
|
add_library(tikzrefinery_shape_api INTERFACE)
|
||||||
|
target_include_directories(tikzrefinery_shape_api INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/plugin-api")
|
||||||
|
target_link_libraries(tikzrefinery_shape_api INTERFACE Qt6::Core)
|
||||||
|
set(strShapeBuildKey "${CMAKE_CXX_COMPILER_ID}-${CMAKE_CXX_COMPILER_VERSION}-${CMAKE_SYSTEM_NAME}-${CMAKE_SIZEOF_VOID_P}-${CMAKE_BUILD_TYPE}-Qt${Qt6Core_VERSION}")
|
||||||
|
file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/generated")
|
||||||
|
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/generated/ShapeBuildContract.h"
|
||||||
|
"#pragma once\nnamespace TikzRefinery::ShapeBuildContract { inline constexpr char pBuildKey[] = \"${strShapeBuildKey}\"; }\n")
|
||||||
|
configure_file(plugins/rectangle/rectangle-plugin.json.in
|
||||||
|
"${CMAKE_CURRENT_BINARY_DIR}/generated/rectangle-plugin.json" @ONLY)
|
||||||
|
add_library(tkr_rectangle_plugin MODULE
|
||||||
|
plugins/rectangle/tkrRectangleShapeProvider.h plugins/rectangle/tkrRectangleShapeProvider.cpp)
|
||||||
|
target_include_directories(tkr_rectangle_plugin PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/generated")
|
||||||
|
target_link_libraries(tkr_rectangle_plugin PRIVATE tikzrefinery_shape_api)
|
||||||
|
set_target_properties(tkr_rectangle_plugin PROPERTIES PREFIX "" OUTPUT_NAME "tkr_rectangle"
|
||||||
|
LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/shape-plugins"
|
||||||
|
RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/shape-plugins")
|
||||||
|
|
||||||
|
# Source interpretation and editing remain usable without a GUI application.
|
||||||
|
add_library(tikzrefinery_core STATIC
|
||||||
|
src/model/EditorTypes.h
|
||||||
|
src/model/tkrTikzDocument.h src/model/tkrTikzDocument.cpp
|
||||||
|
src/parsing/tkrTikzParserExplicit.h src/parsing/tkrTikzParserExplicit.cpp
|
||||||
|
src/geometry/tkrCoordinateMapper.h src/geometry/tkrCoordinateMapper.cpp
|
||||||
|
src/geometry/ShapeGeometryLimits.h
|
||||||
|
src/editing/tkrEditService.h src/editing/tkrEditService.cpp
|
||||||
|
src/editing/tkrEditHistory.h src/editing/tkrEditHistory.cpp
|
||||||
|
)
|
||||||
|
target_include_directories(tikzrefinery_core PUBLIC src)
|
||||||
|
target_link_libraries(tikzrefinery_core PUBLIC Qt6::Core tikzrefinery_shape_api)
|
||||||
|
|
||||||
|
add_library(tikzrefinery_editor STATIC
|
||||||
|
src/controller/tkrEditorController.h src/controller/tkrEditorController.cpp
|
||||||
|
src/ui/tkrDiagramScene.h src/ui/tkrDiagramScene.cpp
|
||||||
|
src/ui/tkrDiagramView.h src/ui/tkrDiagramView.cpp
|
||||||
|
src/ui/tkrMainWindow.h src/ui/tkrMainWindow.cpp
|
||||||
|
src/ui/tkrWorkspaceSidebar.h src/ui/tkrWorkspaceSidebar.cpp
|
||||||
|
src/ui/tkrShapePalette.h src/ui/tkrShapePalette.cpp
|
||||||
|
src/ui/tkrFolderBrowser.h src/ui/tkrFolderBrowser.cpp
|
||||||
|
src/plugins/tkrShapePluginStore.h src/plugins/tkrShapePluginStore.cpp
|
||||||
|
src/plugins/ShapeProviderAdapter.h
|
||||||
|
)
|
||||||
|
target_include_directories(tikzrefinery_editor PUBLIC src "${CMAKE_CURRENT_BINARY_DIR}/generated")
|
||||||
|
add_dependencies(tikzrefinery_editor tikzrefinery_build_info tkr_rectangle_plugin)
|
||||||
|
target_link_libraries(tikzrefinery_editor PUBLIC tikzrefinery_core Qt6::Widgets)
|
||||||
|
|
||||||
|
qt_add_executable(TikZRefinery src/main.cpp)
|
||||||
|
add_dependencies(TikZRefinery tikzrefinery_build_info)
|
||||||
|
target_link_libraries(TikZRefinery PRIVATE tikzrefinery_editor)
|
||||||
|
set_target_properties(TikZRefinery PROPERTIES WIN32_EXECUTABLE TRUE)
|
||||||
|
|
||||||
|
foreach(strTarget IN ITEMS tikzrefinery_core tikzrefinery_editor TikZRefinery tkr_rectangle_plugin)
|
||||||
|
if(MSVC)
|
||||||
|
target_compile_options(${strTarget} PRIVATE /W4 /permissive- /utf-8)
|
||||||
|
else()
|
||||||
|
target_compile_options(${strTarget} PRIVATE -Wall -Wextra -Wpedantic)
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
|
|
||||||
|
include(CTest)
|
||||||
|
if(BUILD_TESTING)
|
||||||
|
# A real second module with incompatible metadata exercises rejection before activation.
|
||||||
|
file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/test-plugin-metadata")
|
||||||
|
file(READ "${CMAKE_CURRENT_BINARY_DIR}/generated/rectangle-plugin.json" strBadMetadata)
|
||||||
|
set(iIncompatibleApiVersion 99)
|
||||||
|
string(REPLACE "\"apiVersion\": 1" "\"apiVersion\": ${iIncompatibleApiVersion}" strBadMetadata "${strBadMetadata}")
|
||||||
|
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/test-plugin-metadata/rectangle-plugin.json" "${strBadMetadata}")
|
||||||
|
add_library(tkr_incompatible_rectangle_plugin MODULE
|
||||||
|
plugins/rectangle/tkrRectangleShapeProvider.h plugins/rectangle/tkrRectangleShapeProvider.cpp)
|
||||||
|
target_include_directories(tkr_incompatible_rectangle_plugin PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/test-plugin-metadata")
|
||||||
|
target_link_libraries(tkr_incompatible_rectangle_plugin PRIVATE tikzrefinery_shape_api)
|
||||||
|
set_target_properties(tkr_incompatible_rectangle_plugin PROPERTIES PREFIX "" OUTPUT_NAME "tkr_bad_rectangle"
|
||||||
|
LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/test-plugins"
|
||||||
|
RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/test-plugins")
|
||||||
|
add_executable(tikzrefinery_plugin_tests tests/PluginTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_plugin_tests PRIVATE tikzrefinery_editor)
|
||||||
|
target_compile_definitions(tikzrefinery_plugin_tests PRIVATE
|
||||||
|
TKR_RECTANGLE_PLUGIN_PATH="$<TARGET_FILE:tkr_rectangle_plugin>"
|
||||||
|
TKR_INCOMPATIBLE_PLUGIN_PATH="$<TARGET_FILE:tkr_incompatible_rectangle_plugin>")
|
||||||
|
add_dependencies(tikzrefinery_plugin_tests tkr_incompatible_rectangle_plugin)
|
||||||
|
add_test(NAME rectangle_plugin_contract COMMAND tikzrefinery_plugin_tests)
|
||||||
|
set_tests_properties(rectangle_plugin_contract PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
add_executable(tikzrefinery_core_tests tests/CoreTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_core_tests PRIVATE tikzrefinery_core)
|
||||||
|
add_test(NAME core_foundations COMMAND tikzrefinery_core_tests)
|
||||||
|
add_executable(tikzrefinery_rectangle_tests tests/RectangleTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_rectangle_tests PRIVATE tikzrefinery_editor)
|
||||||
|
target_compile_definitions(tikzrefinery_rectangle_tests PRIVATE
|
||||||
|
TKR_CORPUS_DIRECTORY="${CMAKE_CURRENT_SOURCE_DIR}/examples/explicit-coordinates")
|
||||||
|
add_test(NAME rectangle_display COMMAND tikzrefinery_rectangle_tests)
|
||||||
|
set_tests_properties(rectangle_display PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
add_executable(tikzrefinery_segment_tests tests/SegmentTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_segment_tests PRIVATE tikzrefinery_editor)
|
||||||
|
target_compile_definitions(tikzrefinery_segment_tests PRIVATE
|
||||||
|
TKR_CORPUS_DIRECTORY="${CMAKE_CURRENT_SOURCE_DIR}/examples/explicit-coordinates")
|
||||||
|
add_test(NAME segment_display COMMAND tikzrefinery_segment_tests)
|
||||||
|
set_tests_properties(segment_display PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
add_executable(tikzrefinery_drag_tests tests/DragTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_drag_tests PRIVATE tikzrefinery_editor)
|
||||||
|
target_compile_definitions(tikzrefinery_drag_tests PRIVATE
|
||||||
|
TKR_CORPUS_DIRECTORY="${CMAKE_CURRENT_SOURCE_DIR}/examples/explicit-coordinates"
|
||||||
|
TKR_TEST_WORK_DIRECTORY="${CMAKE_CURRENT_BINARY_DIR}/test-work")
|
||||||
|
add_test(NAME whole_element_drag COMMAND tikzrefinery_drag_tests)
|
||||||
|
set_tests_properties(whole_element_drag PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
add_executable(tikzrefinery_resize_tests tests/ResizeTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_resize_tests PRIVATE tikzrefinery_editor)
|
||||||
|
add_test(NAME rectangle_resize COMMAND tikzrefinery_resize_tests)
|
||||||
|
set_tests_properties(rectangle_resize PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
add_executable(tikzrefinery_sidebar_tests tests/SidebarTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_sidebar_tests PRIVATE tikzrefinery_editor)
|
||||||
|
add_test(NAME workspace_sidebar COMMAND tikzrefinery_sidebar_tests)
|
||||||
|
set_tests_properties(workspace_sidebar PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
add_executable(tikzrefinery_history_tests tests/HistoryTests.cpp)
|
||||||
|
target_link_libraries(tikzrefinery_history_tests PRIVATE tikzrefinery_editor)
|
||||||
|
add_test(NAME session_history COMMAND tikzrefinery_history_tests)
|
||||||
|
set_tests_properties(session_history PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
||||||
|
endif()
|
||||||
@@ -0,0 +1,168 @@
|
|||||||
|
# C++ and Qt coding guide
|
||||||
|
|
||||||
|
These conventions implement Vincent's naming and structure decisions from
|
||||||
|
October 1-15, 2026. Instructor suggestions are recorded through Vincent's account.
|
||||||
|
|
||||||
|
## Names
|
||||||
|
|
||||||
|
- Project-owned classes use `tkr<MainClassName><Specification>`: a literal
|
||||||
|
lowercase `tkr` prefix followed by PascalCase components. The specification
|
||||||
|
suffix is optional and identifies a specialization: `tkrMainWindow` and
|
||||||
|
`tkrTikzParserExplicit`. Existing Qt/vendor types retain their names.
|
||||||
|
- Structs and enums use PascalCase: `SourceRange`, `DragKind`.
|
||||||
|
- Methods use camelCase and describe an operation: `applyCoordinateEdits()`.
|
||||||
|
- Variables and parameters combine a type/category prefix with a descriptive
|
||||||
|
name. Include coordinate space or units where relevant: `ptTikzPosition`,
|
||||||
|
`rSceneUnitsPerCentimeter`.
|
||||||
|
- Private member variables add `m_`: `m_baSource`, `m_pScene`.
|
||||||
|
`m_` means member; restricting it to private members is our project convention.
|
||||||
|
- Header and implementation filenames match their primary class.
|
||||||
|
- Enum values use PascalCase: `DragKind::WholeElement`.
|
||||||
|
|
||||||
|
| Prefix | Type or category | Example |
|
||||||
|
|---|---|---|
|
||||||
|
| `i` | `int` | `iArgumentCount` |
|
||||||
|
| `n` | `qsizetype` size or index | `nStart` |
|
||||||
|
| `u` | `quint64` ID or revision | `uDocumentRevision` |
|
||||||
|
| `b` | `bool` | `bSafeToEdit` |
|
||||||
|
| `r` | `qreal` | `rLineWidthPoints` |
|
||||||
|
| `str` | `QString` | `strFilePath` |
|
||||||
|
| `ba` | `QByteArray` | `baSource` |
|
||||||
|
| `pt` | `QPointF` | `ptScenePosition` |
|
||||||
|
| `vec` | `QVector<T>` | `vecElements` |
|
||||||
|
| `list` | `QStringList` | `listDiagnostics` |
|
||||||
|
| `p` | Raw pointer | `pParent` |
|
||||||
|
| `ref` | Reference to another object | `m_refDocument` |
|
||||||
|
| `up` | `std::unique_ptr<T>` | `m_upController` |
|
||||||
|
| `iter` | Iterator | `iterEdit` |
|
||||||
|
|
||||||
|
For domain records and concrete objects, use a readable type/category word,
|
||||||
|
such as `coordinateEdit`, `parseResult`, `resultSave`, `mapper`, or `fileSource`.
|
||||||
|
Extend this table when a new category appears. Update names when types change.
|
||||||
|
Prefixes do not establish ownership; declarations and documented lifetimes do.
|
||||||
|
|
||||||
|
## Files and dependencies
|
||||||
|
|
||||||
|
Each primary class has its own `.h` and `.cpp`, grouped by responsibility:
|
||||||
|
`model`, `parsing`, `geometry`, `editing`, `controller`, and `ui`.
|
||||||
|
Small cross-component records share `model/EditorTypes.h`.
|
||||||
|
|
||||||
|
An inheritance path may contain at most three project-defined class levels:
|
||||||
|
main/base class, child, and grandchild (two levels after the main class).
|
||||||
|
Qt's existing ancestry is excluded. This is a maximum, not a target. The
|
||||||
|
initial classes are `final` and introduce no custom inheritance chains.
|
||||||
|
The extracted rectangle implementation is also `final` and realizes
|
||||||
|
`tkrShapeProvider`, a two-level project-defined interface chain.
|
||||||
|
Favor composition and explicit references. A specialization suffix describes
|
||||||
|
the role; it does not itself imply inheritance. The explicit parser has no
|
||||||
|
project-defined base. Do not create base classes solely to satisfy a name.
|
||||||
|
|
||||||
|
The report's Developer Requirements subsection controls these conventions:
|
||||||
|
REQ-A-005 retains its historical ID after moving out of Architecture;
|
||||||
|
REQ-DEV-001 through REQ-DEV-005 govern class names, other identifiers,
|
||||||
|
inheritance depth, documented ownership, and named numeric values. Checks
|
||||||
|
TC-030 through TC-033 and TC-066 are planned review/build procedures.
|
||||||
|
|
||||||
|
The document, parser and mapper depend on Qt Core, without widgets or a LaTeX
|
||||||
|
process. Widgets request actions; parsing identifies source; the model applies
|
||||||
|
validated edits; the controller coordinates them and performs file I/O.
|
||||||
|
|
||||||
|
## Named numeric values
|
||||||
|
|
||||||
|
Keep numeric literals in named definitions. Give each value a name that
|
||||||
|
describes its purpose and units, such as `iHitRadiusViewportPixels`. Use a
|
||||||
|
local `constexpr` when one method needs it, a file-local constant when
|
||||||
|
several helpers share it, or a class member when the class owns the value.
|
||||||
|
Use named enum values for numeric keys. Derive related values from the same
|
||||||
|
definition instead of giving each occurrence of a number a separate name.
|
||||||
|
|
||||||
|
Start the review in `tkrDiagramScene`: name the default scene dimensions,
|
||||||
|
the hit radius, and the item-data keys. Keep related PGF arrow geometry
|
||||||
|
coefficients together in a named definition with their source reference.
|
||||||
|
These are review examples, not a claim that the existing code conforms.
|
||||||
|
|
||||||
|
## Ownership
|
||||||
|
|
||||||
|
- `main.cpp` owns one `tkrMainWindow` on the stack. The accepted final-window close
|
||||||
|
ends the event loop, then stack destruction releases the window.
|
||||||
|
- The document owns `tkrEditHistory` by value; only the document records/traverses
|
||||||
|
its session snapshots. Candidate source, parsed records and history are prepared
|
||||||
|
before document acceptance publishes them with non-allocating swaps.
|
||||||
|
- The window owns its document by value and controller through `unique_ptr`.
|
||||||
|
The controller is destroyed before the document.
|
||||||
|
- The window owns its scene through QObject parenting. Widgets and actions
|
||||||
|
also have Qt parents. The scene owns its graphics items.
|
||||||
|
- The window's central widget tree owns `tkrWorkspaceSidebar`, which parents
|
||||||
|
its tab strip, content stack and Shapes/Files pages. The pages own their
|
||||||
|
controls. Provider description text is copied; no provider pointer is retained.
|
||||||
|
- The controller holds non-owning document/scene references and owns its parser,
|
||||||
|
mapper and stateless edit service by value. Referenced objects must outlive it.
|
||||||
|
- The scene owns its `tkrShapePluginStore` and mapper calibration by value. The
|
||||||
|
store owns a `QPluginLoader` and borrows its root provider interface. The
|
||||||
|
binding is fixed for the scene lifetime; the native module remains resident.
|
||||||
|
The edit service borrows the interface only for a request. API records contain
|
||||||
|
values, without private source ranges, widgets or graphics pointers.
|
||||||
|
- Do not combine QObject-parent ownership and `unique_ptr` ownership of the
|
||||||
|
same object. `WA_DeleteOnClose` must not be set on this stack-owned window.
|
||||||
|
|
||||||
|
## Source and editing contracts
|
||||||
|
|
||||||
|
- Preserve source as bytes. Use byte offsets consistently for source ranges.
|
||||||
|
Decoding the read-only source view must never become the saved representation.
|
||||||
|
- Coordinate values are in centimeters; scene positions use scene units.
|
||||||
|
Viewport pixels and zoom must not alter source geometry.
|
||||||
|
- Element IDs are scoped to a document revision. Reparse after a committed
|
||||||
|
edit and discard stale element records. IDs are not yet persistent identities.
|
||||||
|
- Apply coordinate replacements as one validated batch, from the end backwards.
|
||||||
|
Check revision, bounds, overlaps and expected original text before mutation.
|
||||||
|
- Whole-element and rectangle-corner dragging preview geometry during movement and commits source
|
||||||
|
once on release. Escape, focus loss, or cancelling an interaction restores
|
||||||
|
geometry from the unchanged document. Endpoint dragging remains unimplemented.
|
||||||
|
- Drag displacement is rounded to 0.000001 cm on release. Decimal string
|
||||||
|
addition preserves the original coordinate precision and element dimensions;
|
||||||
|
only values on changed axes are replaced. A candidate source/scene is validated
|
||||||
|
before the model is changed. The edit service constrains both preview and
|
||||||
|
release to the same stroke-aware extent and independent 0.01 cm rectangle
|
||||||
|
minima; crossing flips around the fixed corner. Limits are normal interaction.
|
||||||
|
- Saving uses `QSaveFile` with direct-write fallback disabled. Mark saved only
|
||||||
|
after successful replacement. A baseline comparison detects observed external
|
||||||
|
changes, but does not eliminate a concurrent-write race after that comparison.
|
||||||
|
|
||||||
|
## Implementation status
|
||||||
|
|
||||||
|
The parser conservatively interprets explicit-coordinate rectangles, lines and arrows,
|
||||||
|
retaining numeric byte ranges and a separate non-movable comparison extent.
|
||||||
|
The scene draws these records through the mapper, including PGF's default curved
|
||||||
|
`to` arrowheads for `->`, `<-` and `<->`. Items are selectable; scene event
|
||||||
|
handlers control whole-element movement instead of Qt's `ItemIsMovable` flag.
|
||||||
|
The edit service prepares geometry and source replacements; the controller
|
||||||
|
coordinates candidate validation and the document applies guarded source changes. No item
|
||||||
|
pointers survive a reparse/rebuild. Endpoint handlers remain unsupported.
|
||||||
|
Unsupported input returns diagnostics without a partial diagram. Core parsing
|
||||||
|
remains independent of Widgets. The separate rectangle module supplies geometry,
|
||||||
|
presentation, selection and operations; host validation/source rewriting and
|
||||||
|
document acceptance stay in the application. See [the SDK](plugin-api/README.md).
|
||||||
|
No integrated LaTeX/PDF, undo stack, provider management, creation, zoom controls
|
||||||
|
or loop support is implemented. General product acceptance remains pending.
|
||||||
|
|
||||||
|
Keep TODOs specific, and return a clear unavailable/failure result from unfinished
|
||||||
|
operations. Avoid reporting an empty parse as successful editable interpretation.
|
||||||
|
|
||||||
|
## Reference documentation
|
||||||
|
|
||||||
|
- [Qt CMake setup](https://doc.qt.io/qt-6/cmake-get-started.html)
|
||||||
|
- [QObject ownership](https://doc.qt.io/qt-6/objecttrees.html)
|
||||||
|
- [Window close behavior](https://doc.qt.io/qt-6/qwidget.html#close)
|
||||||
|
- [QSaveFile replacement and failure behavior](https://doc.qt.io/qt-6/qsavefile.html)
|
||||||
|
|
||||||
|
|
||||||
|
## Current sidebar shell and planned shared-service refactor
|
||||||
|
|
||||||
|
The [planned sidebar design](../documents/latex/tkrSidebarDesign.tex) moves shared
|
||||||
|
store/catalogue ownership to the main window and gives views borrowed access.
|
||||||
|
The current shell already has bounded sidebar, palette and folder-placeholder
|
||||||
|
classes, parented through the main window central widget tree. Provider summary
|
||||||
|
text is copied; the scene still owns the store. The catalogue and shared-service
|
||||||
|
refactor remain planned. The current
|
||||||
|
ownership list above remains the code's actual contract. Concrete constructor,
|
||||||
|
teardown and API signatures require review before implementation.
|
||||||
@@ -0,0 +1,287 @@
|
|||||||
|
# TikZRefinery application
|
||||||
|
|
||||||
|
This directory contains the C++/Qt Alpha implementation of the desktop
|
||||||
|
graphical TikZ editor. Vincent selected C++ with Qt on October 1, 2026.
|
||||||
|
|
||||||
|
- `src/` contains application source code.
|
||||||
|
- `tests/` contains automated tests.
|
||||||
|
- `examples/` contains sample TikZ documents and demonstrations.
|
||||||
|
- `resources/` contains application-owned icons, fixtures, and other resources.
|
||||||
|
|
||||||
|
## Class organization
|
||||||
|
|
||||||
|
| Class | Location | Responsibility |
|
||||||
|
|---|---|---|
|
||||||
|
| `tkrTikzDocument` | `src/model/` | Preserve source bytes, parsed records, revisions and minimal edits |
|
||||||
|
| `tkrTikzParserExplicit` | `src/parsing/` | Interpret explicit cm rectangles/segments, byte ranges and fixed extent |
|
||||||
|
| `tkrEditService` | `src/editing/` | Prepare constrained move/resize geometry and coordinate replacements |
|
||||||
|
| `tkrCoordinateMapper` | `src/geometry/` | Convert centimeter coordinates and scene positions |
|
||||||
|
| `tkrEditorController` | `src/controller/` | Coordinate model/scene, parsing, file I/O and saving |
|
||||||
|
| `tkrDiagramScene` | `src/ui/` | Display/select elements, report body/corner gestures and preview geometry |
|
||||||
|
| `tkrDiagramView` | `src/ui/` | Fit the canvas to the pane and paint the fixed editing extent |
|
||||||
|
| `tkrMainWindow` | `src/ui/` | Own the document/controller/scene and provide application controls |
|
||||||
|
| `tkrWorkspaceSidebar` | `src/ui/` | Own tab strip/pages; retain collapsed, selected-page and width state |
|
||||||
|
| `tkrShapePalette` | `src/ui/` | Show copied rectangle-provider status; creation disabled |
|
||||||
|
| `tkrFolderBrowser` | `src/ui/` | Show folder placeholder and request the existing guarded Open flow |
|
||||||
|
| `tkrShapePluginStore` | `src/plugins/` | Validate, load and pin the rectangle module |
|
||||||
|
| `tkrShapeProvider` | `plugin-api/` | Shared value-only provider Strategy interface |
|
||||||
|
| `tkrRectangleShapeProvider` | `plugins/rectangle/` | Supply rectangle presentation and constrained operations in a separate DLL |
|
||||||
|
|
||||||
|
Each concrete class has a header and implementation; the pure provider interface is header-only. `src/model/EditorTypes.h` holds
|
||||||
|
shared data records. See [CODING_GUIDE.md](CODING_GUIDE.md) for naming, ownership,
|
||||||
|
source ranges and editing contracts.
|
||||||
|
|
||||||
|
On October 15, the six project classes and their matching files were renamed
|
||||||
|
to use `tkr<MainClassName><Specification>`. The optional suffix describes a
|
||||||
|
specialization, as in `tkrTikzParserExplicit`; it does not introduce a base
|
||||||
|
class. The allowed maximum is three project-defined inheritance levels, but
|
||||||
|
the concrete classes remain `final`. The rectangle implementation realizes the
|
||||||
|
provider interface; that project-defined chain has two levels.
|
||||||
|
The source-module rule now appears under Developer Requirements with its
|
||||||
|
existing REQ-A-005 ID. Four new DEV requirements and proposed checks record
|
||||||
|
class naming, other identifiers, depth, and ownership documentation.
|
||||||
|
|
||||||
|
The report's Software Architecture chapter includes an MVC allocation and a
|
||||||
|
class responsibility overview with linked detail diagrams, including the edit service. Supporting
|
||||||
|
activities remain in its Design Documents appendix.
|
||||||
|
Their editable TikZ sources are under
|
||||||
|
[`documents/assets/design-diagrams/`](../documents/assets/design-diagrams/).
|
||||||
|
The diagrams distinguish whole-element editing from remaining endpoint work.
|
||||||
|
|
||||||
|
## Current behavior and limits
|
||||||
|
|
||||||
|
The source defines a window with Open/Save controls, a read-only source viewer,
|
||||||
|
and a graphics scene. The controller reads original bytes and provides
|
||||||
|
safe-save plumbing; the model validates source replacements. The mapper handles
|
||||||
|
origin, scale and the inverted y axis. The explicit-coordinate parser preserves numeric
|
||||||
|
byte ranges and displays outlines; the bounding path sets the fixed comparison
|
||||||
|
extent and creates no item. Elements can be selected and dragged as a whole. Opening
|
||||||
|
a file preserves its bytes and clean state, so Save remains disabled.
|
||||||
|
|
||||||
|
Drag a box (including its interior), line or arrow body to translate it. The
|
||||||
|
scene previews movement while source stays unchanged. Release validates and
|
||||||
|
commits one coordinate batch, updates the source pane and enables Save.
|
||||||
|
Escape or focus loss cancels the preview. Save, opening another file or closing
|
||||||
|
also cancels an active preview. Ctrl+S saves committed edits; the existing close
|
||||||
|
guard handles unsaved changes. Click-only selection does not dirty the file.
|
||||||
|
The hit allowance is about five viewport pixels. Displacement is rounded to
|
||||||
|
0.000001 cm on release, with exact decimal translation of the original numbers;
|
||||||
|
unchanged-axis spellings and all unrelated bytes are preserved. Move and resize
|
||||||
|
preview and release stop at the furthest valid position inside a fixed extent,
|
||||||
|
including stroke. Reaching that limit is an accepted edit, not a rejection.
|
||||||
|
|
||||||
|
Select a rectangle, then drag one of its four blue corner handles to resize.
|
||||||
|
The opposite corner stays fixed; crossing it flips the rectangle. Width and
|
||||||
|
height each stop at 0.01 cm (0.1 mm), independently, so thin fillers are allowed.
|
||||||
|
Handles retain their screen size under view transforms. Escape, focus loss
|
||||||
|
and Save cancel an active resize preview. A changed release applies one batch.
|
||||||
|
Aspect-ratio locking and edge-only handles remain unimplemented. Session
|
||||||
|
undo/redo now covers completed coordinate edits in 0.1.4-alpha.
|
||||||
|
See `tests/evidence/resize-2026-11-12/README.md` for bounded automated evidence.
|
||||||
|
|
||||||
|
The whole-element increment passed all four CTest entries. Qt viewport mouse
|
||||||
|
events exercise contact, line/arrow movement, cancellation, source changes and
|
||||||
|
save/reopen; all three actual saved results match independently compiled output
|
||||||
|
within the prototype one-pixel allowance. See
|
||||||
|
[`tests/evidence/whole-element-drag-2026-10-21.md`](tests/evidence/whole-element-drag-2026-10-21.md).
|
||||||
|
The interactive demo is `code/build/demo/boxes-drag-demo.tex`; keep its edits
|
||||||
|
for review and avoid saving over the corpus fixtures when experimenting.
|
||||||
|
|
||||||
|
The first October 21 increment passed both then-registered tests and a fixed-extent
|
||||||
|
TinyTeX raster comparison for the initial and touching-reference boxes. The
|
||||||
|
automated window Open check also reaches the source, scene and status widgets.
|
||||||
|
See [`tests/evidence/rectangle-display-2026-10-21.md`](tests/evidence/rectangle-display-2026-10-21.md)
|
||||||
|
for observations, the one-pixel prototype comparison threshold, retained
|
||||||
|
images/metrics, reproduction commands, and limits. Loading the touching
|
||||||
|
reference does not establish a working drag/contact workflow.
|
||||||
|
|
||||||
|
The subsequent line/arrow increment passed all three registered tests and
|
||||||
|
fixed-extent comparisons for all eight corpus files. The reference files were
|
||||||
|
valid TikZ; the editor previously rejected their unsupported segment syntax.
|
||||||
|
It now displays single straight `--` segments and the default `->`, `<-`, `<->`
|
||||||
|
arrowheads. See [`tests/evidence/segment-display-2026-10-21.md`](tests/evidence/segment-display-2026-10-21.md).
|
||||||
|
|
||||||
|
Accepted input is a bare supported-command fragment, a single unconfigured
|
||||||
|
`tikzpicture`, or the exact `article`/`tikz`/empty-page wrapper in the corpus.
|
||||||
|
Absolute signed decimal/integer `cm` pairs and reversed corners are supported.
|
||||||
|
Options may contain `black`, `solid`, and one positive literal `line width` in
|
||||||
|
`pt`, in any order; a segment may also have one arrow-direction option. The
|
||||||
|
default width is 0.4pt. Comments, UTF-8 comment bytes, CRLF,
|
||||||
|
and an initial UTF-8 BOM retain their original offsets. One optional bounding
|
||||||
|
path must precede drawings and enclose their outlines. Unsupported syntax,
|
||||||
|
wrappers, custom arrow tips/styles, curves, polylines, transforms, loops and
|
||||||
|
macros yield a diagnostic and an empty canvas. Zero-length segments and arrows
|
||||||
|
whose tip insets consume their shaft are refused. This remains a bounded prototype.
|
||||||
|
|
||||||
|
The first native build passed on October 20, 2026 using Qt 6.12.0, matching
|
||||||
|
MinGW/GCC 13.1.0, CMake 3.30.5, and Ninja 1.12.1 on Windows. CTest passed the
|
||||||
|
one registered `core_foundations` test. Vincent opened `boxes-initial.tex` in
|
||||||
|
the running application and confirmed the source display. This does not verify
|
||||||
|
parsing, dragging, filesystem saves, timing, or canvas/PDF agreement. See
|
||||||
|
[`tests/evidence/first-run-2026-10-20.md`](tests/evidence/first-run-2026-10-20.md).
|
||||||
|
|
||||||
|
## Build and run
|
||||||
|
|
||||||
|
### Recommended first Windows setup
|
||||||
|
|
||||||
|
Use the [Qt Online Installer](https://www.qt.io/development/download-open-source)
|
||||||
|
and its open-source installation route. The recommended starting kit is desktop
|
||||||
|
Qt 6 with the matching MinGW-w64 64-bit compiler, installed together. MSVC is
|
||||||
|
also supported; it needs a separate Visual Studio C++ installation and the
|
||||||
|
matching MSVC Qt package.
|
||||||
|
|
||||||
|
1. Create/sign in to a Qt account and choose a folder such as `C:\Qt`.
|
||||||
|
2. Choose Custom Installation to inspect the components. Select one stable
|
||||||
|
released Qt 6 desktop version and its **MinGW 64-bit** package. Qt 6.2 is
|
||||||
|
the project's minimum, not a request to install that old release. Avoid
|
||||||
|
beta, preview, or release-candidate builds.
|
||||||
|
3. Include **Qt Creator**, the **MinGW compiler matching that Qt kit**,
|
||||||
|
**CMake** (3.21 or later), and **Ninja**. Use the supplied matching compiler;
|
||||||
|
its version depends on the selected Qt release. Core and Widgets are required.
|
||||||
|
4. Open this directory's `CMakeLists.txt` in Qt Creator and select the desktop
|
||||||
|
Qt 6 MinGW 64-bit kit. Check Preferences > Kits: Qt, compiler, debugger and
|
||||||
|
CMake must resolve without errors. Keep the build directory under `code/build/`.
|
||||||
|
5. Configure, build, and run. Open `boxes-initial.tex` to see two outlined boxes
|
||||||
|
and the read-only source view; move/resize are available for the supported subset. Run the
|
||||||
|
core tests separately before treating their checks as passed.
|
||||||
|
|
||||||
|
Qt Creator is the IDE, Qt supplies libraries, and MinGW supplies the compiler.
|
||||||
|
Installing the IDE alone is insufficient. Confirm the installed versions and
|
||||||
|
paths before running the command-line build below.
|
||||||
|
|
||||||
|
References: [Qt installation](https://doc.qt.io/qt-6/qt-online-installation.html),
|
||||||
|
[Windows configurations](https://doc.qt.io/qt-6/windows.html),
|
||||||
|
[opening CMake projects](https://doc.qt.io/qtcreator/creator-project-opening.html).
|
||||||
|
|
||||||
|
### Verified local Windows commands (October 20, 2026)
|
||||||
|
|
||||||
|
From the repository root in PowerShell, using the installed paths:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
$env:Path = 'C:\Qt\6.12.0\mingw_64\bin;C:\Qt\Tools\mingw1310_64\bin;C:\Qt\Tools\Ninja;' + $env:Path
|
||||||
|
& C:\Qt\Tools\CMake_64\bin\cmake.exe -S code -B code/build -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_PREFIX_PATH=C:/Qt/6.12.0/mingw_64 -DCMAKE_CXX_COMPILER=C:/Qt/Tools/mingw1310_64/bin/g++.exe -DCMAKE_MAKE_PROGRAM=C:/Qt/Tools/Ninja/ninja.exe
|
||||||
|
& C:\Qt\Tools\CMake_64\bin\cmake.exe --build code/build --parallel 4
|
||||||
|
& C:\Qt\Tools\CMake_64\bin\ctest.exe --test-dir code/build --output-on-failure
|
||||||
|
& .\code\build\TikZRefinery.exe
|
||||||
|
```
|
||||||
|
|
||||||
|
An optional source-file argument opens that file on startup, for example:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
& .\code\build\TikZRefinery.exe .\code\examples\explicit-coordinates\arrow-initial.tex
|
||||||
|
```
|
||||||
|
|
||||||
|
Stop after any failed command and inspect its output. Close the running app
|
||||||
|
before rebuilding it. The PATH change applies only to this PowerShell session;
|
||||||
|
it lets Windows find Qt and MinGW DLLs without copying them into the repository.
|
||||||
|
The executable in `code/build/` is a development build, not a deployed package.
|
||||||
|
|
||||||
|
### Refresh the Windows prototype package
|
||||||
|
|
||||||
|
Use the Demo 3 Release package at
|
||||||
|
[`code/packages/0.1.4-alpha/`](packages/0.1.4-alpha/)
|
||||||
|
for interactive review. Open `TikZRefinery.exe` from that folder in Explorer.
|
||||||
|
It carries the Qt and MinGW runtime files and can be reopened without the
|
||||||
|
development shell. Keep the executable with the package contents.
|
||||||
|
Current policy uses `0.feature.revision-alpha`. A build retains the document
|
||||||
|
baseline it implements even as the report advances. Completed document/code
|
||||||
|
revisions advance the final number; completed feature releases advance the middle
|
||||||
|
number and reset revision. Normal titles and versioned package folders omit Git
|
||||||
|
hashes; About exposes short/full identity, source state and the loaded provider.
|
||||||
|
|
||||||
|
**Preserve `packages/TikZRefinery-windows-x64/`, the frozen Alpha 0.10.3 package,
|
||||||
|
and its edited examples.** Its matching reports remain separate. The extracted
|
||||||
|
rectangle module is delivered in `0.1.2-alpha/`; `0.2.0-alpha` is the later
|
||||||
|
shape-discovery/creation milestone. See [the SDK](plugin-api/README.md) and
|
||||||
|
[extraction evidence](tests/evidence/plugin-extraction-2026-11-20/README.md).
|
||||||
|
Both Debug and Release pass six CTest suites, including actual DLL loading,
|
||||||
|
negative compatibility cases and host validation. This is bounded evidence,
|
||||||
|
not completed product acceptance.
|
||||||
|
|
||||||
|
The November 23 follow-up implements the bounded 0.1.3-alpha sidebar shell:
|
||||||
|
Shapes/Files icons, collapse/reopen, retained session page/width, provider status
|
||||||
|
and the existing guarded Open action. Creation remains disabled; no folder tree,
|
||||||
|
catalogue API or service-ownership refactor is claimed. The scene still owns the
|
||||||
|
plugin store. All seven suites pass in Debug and Release; native review checks
|
||||||
|
the visible shell and unsaved-work guard. About truthfully records checkpoint
|
||||||
|
`7a2965a4f14e` with modified working tree. See [shell evidence](tests/evidence/sidebar-shell-2026-11-23/README.md).
|
||||||
|
The preceding [identity-only demo evidence](tests/evidence/demo3-package-2026-11-23/README.md)
|
||||||
|
is historical and does not describe the replacement executable. Older packages
|
||||||
|
and existing edited examples remain preserved.
|
||||||
|
|
||||||
|
For a visual increment, close the packaged app normally, then configure a
|
||||||
|
Release build with the same Qt kit and run CTest. Use the commands in the
|
||||||
|
previous section with a separate task-local build path under `work/` and
|
||||||
|
`-DCMAKE_BUILD_TYPE=Release`. Check deployment with that kit's
|
||||||
|
`windeployqt --release --compiler-runtime --no-translations --no-opengl-sw --no-system-d3d-compiler`.
|
||||||
|
Add `--dry-run --list relative --dir <package-folder> <built-exe>` to see the
|
||||||
|
required files before copying. Reuse the installed files if the kit is
|
||||||
|
unchanged and the list is complete; redeploy the runtime and plugins if the kit
|
||||||
|
or dependencies change.
|
||||||
|
|
||||||
|
For an authorized application increment, update only its designated development
|
||||||
|
package and manifest; do not replace the frozen demo executable.
|
||||||
|
Preserve any edited examples. Verify close and reopen with a Windows-only
|
||||||
|
PATH before leaving the packaged app open for review, then remove the task's
|
||||||
|
reproducible build scratch. See the
|
||||||
|
[latest package check](tests/evidence/package-2026-11-05.md) and the
|
||||||
|
[original Week 8 package evidence](tests/evidence/package-2026-10-23.md).
|
||||||
|
|
||||||
|
### Command-line build
|
||||||
|
|
||||||
|
Requires CMake 3.21+, a C++17 compiler, and a compatible Qt 6 development kit
|
||||||
|
(Core and Widgets; project minimum 6.2). Choose a Qt kit matching the compiler
|
||||||
|
and architecture. Python/PySide6 alone is not the C++ development kit.
|
||||||
|
|
||||||
|
In a shell configured for that kit, from the repository root:
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
cmake -S code -B code/build -DCMAKE_PREFIX_PATH="<Qt kit directory>"
|
||||||
|
cmake --build code/build --config Debug
|
||||||
|
ctest --test-dir code/build -C Debug --output-on-failure
|
||||||
|
```
|
||||||
|
|
||||||
|
The executable is typically `code/build/Debug/TikZRefinery.exe` for a
|
||||||
|
multi-configuration generator, or `code/build/TikZRefinery.exe` for a
|
||||||
|
single-configuration generator. Run from the Qt kit's environment so Qt DLLs
|
||||||
|
and platform plugins are available. Use the package above for interactive
|
||||||
|
review outside that environment.
|
||||||
|
|
||||||
|
The `core_foundations` checks cover independent mapping expectations (TC-028),
|
||||||
|
untouched UTF-8/CRLF bytes, variable-length replacements, stale revisions,
|
||||||
|
overlapping ranges and atomic rejection of invalid batches. They do not cover
|
||||||
|
GUI interaction, filesystem saves or canvas/PDF fidelity. The separate
|
||||||
|
`rectangle_display` test covers parser/model/controller/scene geometry and an
|
||||||
|
offscreen window Open action. `segment_display` covers all six line/arrow
|
||||||
|
fixtures, direction flags, endpoints/ranges, mixed geometry, refused syntax,
|
||||||
|
and startup-file windows. `whole_element_drag` covers viewport pointer gestures,
|
||||||
|
exact minimal byte edits, cancellation, save/reopen, external-change refusal,
|
||||||
|
precision and a 2x scaled/panned view. `tests/CompareRectangles.py` performs the external raster comparison
|
||||||
|
separately, using the bundled Python/Pillow runtime and installed TinyTeX/Poppler.
|
||||||
|
|
||||||
|
The **Canvas** pane now uses a bordered white drawing surface so black TikZ
|
||||||
|
geometry stays visible in either theme. The adjacent **TikZ source** pane
|
||||||
|
still follows the window palette. The canvas fits the pane by default; for
|
||||||
|
documents with a fixed editing extent, white paper matches that extent and
|
||||||
|
the grey surround is outside it. See the
|
||||||
|
[fit and boundary checks](tests/evidence/canvas-fit-2026-11-05/README.md) and
|
||||||
|
[earlier palette checks](tests/evidence/canvas-contrast-2026-11-05/README.md).
|
||||||
|
|
||||||
|
## Next increment
|
||||||
|
|
||||||
|
1. Review the separately packaged rectangle plugin and actual UI screenshot.
|
||||||
|
2. Review shape discovery, creation gestures and source insertion before the
|
||||||
|
later 0.2.0-alpha milestone.
|
||||||
|
3. Keep the planned transaction and history boundaries; generic transactions,
|
||||||
|
endpoint editing, zoom/pan and integrated compilation remain pending.
|
||||||
|
|
||||||
|
The 0.1.4-alpha package implements session undo/redo for completed coordinate
|
||||||
|
edits. Edit > Undo (Ctrl+Z) and Redo (Ctrl+Y) restore exact source bytes. Save
|
||||||
|
retains history; successful Open/Reload clears it. A changed edit after Undo
|
||||||
|
discards the redo branch. Snapshots have no automatic eviction; memory use grows
|
||||||
|
with the session. Allocation failure before publication rejects the edit.
|
||||||
|
See [history evidence](tests/evidence/undo-redo-2026-11-24/README.md).
|
||||||
|
|
||||||
|
The LaTeX report records the selected class and language decisions in the
|
||||||
|
Development Plan and architectural requirements context. Product verification
|
||||||
|
remains pending.
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
# Invoked on every build; replace generated files only when the identity changes.
|
||||||
|
set(strCheckpoint "unavailable")
|
||||||
|
set(strSourceState "source state unavailable")
|
||||||
|
if(GIT_EXECUTABLE AND EXISTS "${GIT_EXECUTABLE}")
|
||||||
|
execute_process(COMMAND "${GIT_EXECUTABLE}" -C "${SOURCE_ROOT}" rev-parse HEAD
|
||||||
|
OUTPUT_VARIABLE strHash OUTPUT_STRIP_TRAILING_WHITESPACE RESULT_VARIABLE iGitResult)
|
||||||
|
if(iGitResult EQUAL 0 AND strHash MATCHES "^[0-9a-f]+$")
|
||||||
|
set(strCheckpoint "${strHash}")
|
||||||
|
execute_process(COMMAND "${GIT_EXECUTABLE}" -C "${SOURCE_ROOT}" status --porcelain --untracked-files=normal
|
||||||
|
OUTPUT_VARIABLE strStatus OUTPUT_STRIP_TRAILING_WHITESPACE RESULT_VARIABLE iStatusResult)
|
||||||
|
if(iStatusResult EQUAL 0)
|
||||||
|
if(strStatus STREQUAL "")
|
||||||
|
set(strSourceState "clean checkpoint")
|
||||||
|
else()
|
||||||
|
set(strSourceState "modified working tree")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
if(NOT REPORT_VERSION)
|
||||||
|
set(REPORT_VERSION "${PROJECT_VERSION}")
|
||||||
|
endif()
|
||||||
|
set(strShortCheckpoint "${strCheckpoint}")
|
||||||
|
set(iShortCheckpointLength 12)
|
||||||
|
if(NOT strCheckpoint STREQUAL "unavailable")
|
||||||
|
string(SUBSTRING "${strCheckpoint}" 0 ${iShortCheckpointLength} strShortCheckpoint)
|
||||||
|
endif()
|
||||||
|
file(MAKE_DIRECTORY "${BINARY_ROOT}/generated")
|
||||||
|
set(strHeader "#pragma once\nnamespace TikzRefinery::BuildInfo {\ninline constexpr char pVersion[] = \"${REPORT_VERSION}\";\ninline constexpr char pMaturity[] = \"Alpha\";\ninline constexpr char pCheckpoint[] = \"${strCheckpoint}\";\ninline constexpr char pShortCheckpoint[] = \"${strShortCheckpoint}\";\ninline constexpr char pSourceState[] = \"${strSourceState}\";\n}\n")
|
||||||
|
set(strJson "{\n \"applicationVersion\": \"${REPORT_VERSION}\",\n \"maturity\": \"Alpha\",\n \"sourceCheckpoint\": \"${strCheckpoint}\",\n \"sourceCheckpointShort\": \"${strShortCheckpoint}\",\n \"sourceState\": \"${strSourceState}\"\n}\n")
|
||||||
|
foreach(strOutput IN ITEMS header json)
|
||||||
|
if(strOutput STREQUAL "header")
|
||||||
|
set(strPath "${BINARY_ROOT}/generated/BuildInfo.h")
|
||||||
|
set(strContent "${strHeader}")
|
||||||
|
else()
|
||||||
|
set(strPath "${BINARY_ROOT}/build-info.json")
|
||||||
|
set(strContent "${strJson}")
|
||||||
|
endif()
|
||||||
|
if(EXISTS "${strPath}")
|
||||||
|
file(READ "${strPath}" strExisting)
|
||||||
|
else()
|
||||||
|
set(strExisting "")
|
||||||
|
endif()
|
||||||
|
if(NOT strExisting STREQUAL strContent)
|
||||||
|
file(WRITE "${strPath}" "${strContent}")
|
||||||
|
endif()
|
||||||
|
endforeach()
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
|
||||||
@@ -0,0 +1,78 @@
|
|||||||
|
# Initial explicit-coordinate reference corpus
|
||||||
|
|
||||||
|
Vincent selected explicit coordinates and individual drawing commands as the
|
||||||
|
first feasibility inputs on October 1, 2026. These are reference sources and
|
||||||
|
expected revisions, not results produced by an implemented editor.
|
||||||
|
|
||||||
|
## Syntax boundary
|
||||||
|
|
||||||
|
Each editable element has one `\draw` command using absolute numeric Cartesian
|
||||||
|
coordinates with explicit `cm` units. The examples use solid black outlines
|
||||||
|
with `line width=0.6pt`, straight `--` segments, the arrow options `->`, `<-`,
|
||||||
|
and `<->`, and `rectangle` between opposite corners. Whitespace, line breaks,
|
||||||
|
comments, and the order of allowed options do not define different geometry.
|
||||||
|
|
||||||
|
The `\path[use as bounding box]` declaration is fixed calibration data.
|
||||||
|
It keeps every picture's extent at (-2,-2) to (5,3) cm, so rendering each
|
||||||
|
picture cannot recenter the changed geometry through independent tight crops.
|
||||||
|
It is not a movable element. Preserve it, the wrapper, and unrelated source.
|
||||||
|
|
||||||
|
Nodes, named coordinates, relative coordinates, other units, coordinate
|
||||||
|
expressions, transformations, macros, loops, fills, and custom styles await
|
||||||
|
later coverage. This initial boundary is not a mandatory input format for
|
||||||
|
all future diagrams. Instructor examples may guide expansion when available.
|
||||||
|
|
||||||
|
## Reference edits
|
||||||
|
|
||||||
|
| Planned test | Initial source | Gesture and expected geometry (cm) | Expected source |
|
||||||
|
|---|---|---|---|
|
||||||
|
| TC-021 | `line-initial.tex` | Translate by (0.5,0.5): (-1,-0.5), (1,0.5) become (-0.5,0), (1.5,1). | `line-translated.tex` |
|
||||||
|
| TC-023 | `line-initial.tex` | Move only the second endpoint from (1,0.5) to (1,1.5). | `line-endpoint.tex` |
|
||||||
|
| TC-022 | `arrow-initial.tex` | Translate only the first arrow by (0.5,0.5): (0,0), (2,1) become (0.5,0.5), (2.5,1.5). | `arrow-translated.tex` |
|
||||||
|
| TC-024 | `arrow-initial.tex` | Move only the first arrow's second endpoint from (2,1) to (2,1.5). | `arrow-endpoint.tex` |
|
||||||
|
| TC-025, TC-029 | `boxes-initial.tex` | Move only the right box left by 1 cm: corners (2,0), (3,1) become (1,0), (2,1). | `boxes-touching.tex` |
|
||||||
|
|
||||||
|
The arrow sample contains unchanged backward and double arrows to detect
|
||||||
|
unintended edits. Repeat body and endpoint gestures on those variants during
|
||||||
|
TC-022/TC-024 coverage. Expected files define numeric geometry and changes
|
||||||
|
limited to the target coordinates; an editor may preserve a different valid
|
||||||
|
decimal spelling while keeping comments, whitespace, and unrelated bytes.
|
||||||
|
|
||||||
|
For TC-029, the initial boxes are 1 cm square with a 1 cm gap between edge
|
||||||
|
centerlines. After movement, their edge centerlines coincide at x=1 cm;
|
||||||
|
the left box and both sizes remain unchanged. Account for stroke thickness
|
||||||
|
when judging visible contact.
|
||||||
|
|
||||||
|
Use the same fixed extent, origin, and scale for canvas/PDF overlays (TC-027)
|
||||||
|
and document the zoom range and geometric/rendering tolerances before product
|
||||||
|
test execution (TC-026). Compile and visually review these sources with the
|
||||||
|
shared TinyTeX toolchain; put output and intermediates under task-local `work`.
|
||||||
|
The report contains the box illustrations, so no separate fixture PDFs need
|
||||||
|
to be tracked. Rendering a fixture does not verify graphical editing.
|
||||||
|
|
||||||
|
## Independent coordinate checks (TC-028)
|
||||||
|
|
||||||
|
One proposed test configuration places the TikZ origin at scene position
|
||||||
|
(200,300) and uses 100 scene units per cm, with scene y increasing downward:
|
||||||
|
|
||||||
|
`x_scene = 200 + 100*x_cm`, `y_scene = 300 - 100*y_cm`.
|
||||||
|
|
||||||
|
| TikZ point (cm) | Independently expected scene position |
|
||||||
|
|---|---|
|
||||||
|
| (0,0) | (200,300) |
|
||||||
|
| (1,0) | (300,300) |
|
||||||
|
| (0,1) | (200,200) |
|
||||||
|
| (-1,-0.5) | (100,350) |
|
||||||
|
|
||||||
|
These constants are test inputs, not mandated application settings. Check
|
||||||
|
forward and inverse conversions against the listed values, then round trips.
|
||||||
|
Changing zoom or pan must not change those scene positions or source bytes.
|
||||||
|
Map view/pointer coordinates into the scene before interpreting a drag.
|
||||||
|
|
||||||
|
## Later syntax coverage
|
||||||
|
|
||||||
|
Equivalent shapes expressed as nodes, named or relative coordinates,
|
||||||
|
transformations, and generated loop instances need separate interpretation
|
||||||
|
and edit tests. A successful compile can establish rendering even when
|
||||||
|
graphical editing remains unsupported. Preserve source and provide a clear
|
||||||
|
diagnostic in that case; do not infer safe editing from appearance alone.
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% First arrow is the target for the recorded edit.
|
||||||
|
\draw[->,line width=0.6pt] (0cm,0cm) -- (2cm,1.5cm);
|
||||||
|
% Unchanged start-arrow and double-arrow references.
|
||||||
|
\draw[line width=0.6pt,<-] (0cm,-1cm) -- (2cm,-1cm);
|
||||||
|
\draw[<->,line width=0.6pt] (0cm,2cm) -- (2cm,2cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% First arrow is the target for the recorded edit.
|
||||||
|
\draw[->,line width=0.6pt] (0cm,0cm) -- (2cm,1cm);
|
||||||
|
% Unchanged start-arrow and double-arrow references.
|
||||||
|
\draw[line width=0.6pt,<-] (0cm,-1cm) -- (2cm,-1cm);
|
||||||
|
\draw[<->,line width=0.6pt] (0cm,2cm) -- (2cm,2cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% First arrow is the target for the recorded edit.
|
||||||
|
\draw[->,line width=0.6pt] (0.5cm,0.5cm) -- (2.5cm,1.5cm);
|
||||||
|
% Unchanged start-arrow and double-arrow references.
|
||||||
|
\draw[line width=0.6pt,<-] (0cm,-1cm) -- (2cm,-1cm);
|
||||||
|
\draw[<->,line width=0.6pt] (0cm,2cm) -- (2cm,2cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% Stationary left box.
|
||||||
|
\draw[line width=0.6pt] (0cm,0cm) rectangle (1cm,1cm);
|
||||||
|
% Move only this right box.
|
||||||
|
\draw[line width=0.6pt] (2cm,0cm) rectangle (3cm,1cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% Stationary left box.
|
||||||
|
\draw[line width=0.6pt] (0cm,0cm) rectangle (1cm,1cm);
|
||||||
|
% Move only this right box.
|
||||||
|
\draw[line width=0.6pt] (1cm,0cm) rectangle (2cm,1cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% Editable line; negative coordinates are intentional.
|
||||||
|
\draw[line width=0.6pt] (-1cm,-0.5cm) -- (1cm,1.5cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% Editable line; negative coordinates are intentional.
|
||||||
|
\draw[line width=0.6pt] (-1cm,-0.5cm) -- (1cm,0.5cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
% Initial explicit-coordinate reference corpus. See README.md.
|
||||||
|
\documentclass{article}
|
||||||
|
\usepackage{tikz}
|
||||||
|
\pagestyle{empty}
|
||||||
|
\begin{document}
|
||||||
|
\noindent
|
||||||
|
\begin{tikzpicture}
|
||||||
|
% Fixed comparison extent; this is not a movable diagram element.
|
||||||
|
\path[use as bounding box] (-2cm,-2cm) rectangle (5cm,3cm);
|
||||||
|
% Editable line; negative coordinates are intentional.
|
||||||
|
\draw[line width=0.6pt] (-0.5cm,0cm) -- (1.5cm,1cm);
|
||||||
|
\end{tikzpicture}
|
||||||
|
\end{document}
|
||||||
|
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
% Rectangle display, selection, move and resize use the loaded shape provider.
|
||||||
|
% The arrow retains the built-in explicit-syntax display route.
|
||||||
|
\path[use as bounding box] (-1cm,-1cm) rectangle (6.5cm,3.5cm);
|
||||||
|
\draw[line width=0.6pt] (0cm,0cm) rectangle (2cm,2cm);
|
||||||
|
\draw[line width=0.6pt] (3.5cm,0.5cm) rectangle (5.5cm,2.5cm);
|
||||||
|
\draw[->,line width=0.6pt] (2cm,1cm) -- (3.5cm,1.5cm);
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
# Shape API v1 - initial rectangle extraction
|
||||||
|
|
||||||
|
`tikzrefinery_shape_api` exports only these public headers and Qt Core.
|
||||||
|
The module implements `tkrShapeProvider`; the host loads it with Qt's native
|
||||||
|
plugin mechanism. Widgets, graphics items, byte ranges, files and history are
|
||||||
|
outside the API. This is a same-toolchain C++ contract, not a stable cross-vendor
|
||||||
|
ABI, sandbox or adapter layer. Use the exact API/schema, Qt, compiler, platform,
|
||||||
|
pointer size and Debug/Release build key in the module metadata.
|
||||||
|
|
||||||
|
Records use document centimetres and TeX-point stroke widths. An element has
|
||||||
|
document UUID, revision-scoped element ID/revision, family/type/schema, opposite
|
||||||
|
corners and appearance/content. The first provider supports black, unfilled,
|
||||||
|
empty-content rectangles. Other geometry/presentation schemas remain future work.
|
||||||
|
|
||||||
|
Operations are `tkr.move` and `tkr.resize`, parameter schema 1. Move supplies total
|
||||||
|
displacement from initial geometry; resize also supplies one of four semantic
|
||||||
|
corner IDs. Constraints contain optional fixed bounds and independent minimum
|
||||||
|
dimensions. Requests never contain source spellings or ranges. Results distinguish
|
||||||
|
PreparedChange, Unchanged and CannotPrepare with reason. A result is not acceptance.
|
||||||
|
|
||||||
|
Presentation contains an outline rectangle, selection rectangle, readable name
|
||||||
|
and four identified handle positions. The scene maps these values into its own
|
||||||
|
graphics items and constant-screen-size handles. It owns no plugin graphics item.
|
||||||
|
The edit service checks capabilities and proposal invariants, prepares exact
|
||||||
|
source replacements and the document applies guarded coordinate batches.
|
||||||
|
|
||||||
|
`tkrShapePluginStore` selects only the explicitly configured rectangle module
|
||||||
|
under `shape-plugins/`. It validates identity, role, API/data/parameter schemas,
|
||||||
|
operations and build key before activation, then pins its binding for the scene
|
||||||
|
lifetime (the Qt module remains resident for the process). A host UUID identifies
|
||||||
|
that runtime binding separately from the declared plugin ID/version. It does not
|
||||||
|
scan competing providers or choose one by load order. Candidate selection UI,
|
||||||
|
multiple-provider registration, hot updates and migration remain planned.
|
||||||
|
|
||||||
|
To build a provider, link the INTERFACE target, implement the three const methods,
|
||||||
|
use `Q_PLUGIN_METADATA` / `Q_INTERFACES`, and declare compatible metadata. The
|
||||||
|
working reference is `plugins/rectangle/`; compile a MODULE target with matching
|
||||||
|
headers/toolchain and deploy its DLL beside the app in `shape-plugins/`.
|
||||||
|
No provider function may mutate a live document, scene, history or file.
|
||||||
|
|
||||||
|
Reference: [Qt application plugins](https://doc.qt.io/qt-6/plugins-howto.html),
|
||||||
|
[QPluginLoader](https://doc.qt.io/qt-6/qpluginloader.html).
|
||||||
@@ -0,0 +1,93 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <QMetaType>
|
||||||
|
#include <QPointF>
|
||||||
|
#include <QRectF>
|
||||||
|
#include <QString>
|
||||||
|
#include <QStringList>
|
||||||
|
#include <QUuid>
|
||||||
|
#include <QVector>
|
||||||
|
|
||||||
|
namespace TikzRefinery::ShapeApi {
|
||||||
|
|
||||||
|
inline constexpr int iApiVersion = 1;
|
||||||
|
inline constexpr int iRectangleSchemaVersion = 1;
|
||||||
|
inline constexpr int iParameterSchemaVersion = 1;
|
||||||
|
inline constexpr int iCoordinateDecimals = 6;
|
||||||
|
inline constexpr qreal rCoordinateStepsPerCentimeter = 1000000.0;
|
||||||
|
inline constexpr qreal rMinimumRectangleCentimeters = 0.01;
|
||||||
|
inline constexpr qreal rCentimetersPerTexPoint = 2.54 / 72.27;
|
||||||
|
inline constexpr qreal rHalfStroke = 0.5;
|
||||||
|
inline constexpr qreal rDefaultLineWidthPoints = 0.4;
|
||||||
|
inline const QString strMoveOperation = QStringLiteral("tkr.move");
|
||||||
|
inline const QString strResizeOperation = QStringLiteral("tkr.resize");
|
||||||
|
inline const QString strRectangleFamily = QStringLiteral("rectangle");
|
||||||
|
inline const QString strRectangleType = QStringLiteral("tkr.rectangle.opposite-corners");
|
||||||
|
|
||||||
|
enum class HandleId { FirstFirst, FirstSecond, SecondFirst, SecondSecond };
|
||||||
|
enum class PreparationOutcome { PreparedChange, Unchanged, CannotPrepare };
|
||||||
|
|
||||||
|
// Value records in document centimetres. No source ranges, widgets or item pointers.
|
||||||
|
struct ElementDescription
|
||||||
|
{
|
||||||
|
QUuid documentId;
|
||||||
|
quint64 uElementId = 0;
|
||||||
|
quint64 uRevision = 0;
|
||||||
|
QString strFamily = strRectangleFamily;
|
||||||
|
QString strType = strRectangleType;
|
||||||
|
int iSchemaVersion = iRectangleSchemaVersion;
|
||||||
|
QPointF ptFirstCentimeters;
|
||||||
|
QPointF ptSecondCentimeters;
|
||||||
|
qreal rLineWidthPoints = rDefaultLineWidthPoints;
|
||||||
|
QString strStrokeColor = QStringLiteral("black");
|
||||||
|
QString strContent;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct HandleDescription
|
||||||
|
{
|
||||||
|
HandleId handleId = HandleId::FirstFirst;
|
||||||
|
QPointF ptPositionCentimeters;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct PresentationDescription
|
||||||
|
{
|
||||||
|
bool bAvailable = false;
|
||||||
|
QString strReason;
|
||||||
|
QString strReadableDescription;
|
||||||
|
QRectF rectOutlineCentimeters;
|
||||||
|
QRectF rectSelectionCentimeters;
|
||||||
|
QVector<HandleDescription> vecHandles;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct EditingConstraints
|
||||||
|
{
|
||||||
|
bool bHasFixedBounds = false;
|
||||||
|
QRectF rectBoundsCentimeters;
|
||||||
|
qreal rMinimumWidthCentimeters = rMinimumRectangleCentimeters;
|
||||||
|
qreal rMinimumHeightCentimeters = rMinimumRectangleCentimeters;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct OperationRequest
|
||||||
|
{
|
||||||
|
QUuid documentId;
|
||||||
|
quint64 uElementId = 0;
|
||||||
|
quint64 uRevision = 0;
|
||||||
|
ElementDescription initial;
|
||||||
|
QString strOperationId;
|
||||||
|
int iParameterSchemaVersion = ShapeApi::iParameterSchemaVersion;
|
||||||
|
QPointF ptTotalDisplacementCentimeters;
|
||||||
|
HandleId handleId = HandleId::SecondSecond;
|
||||||
|
EditingConstraints constraints;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct PreparationResult
|
||||||
|
{
|
||||||
|
PreparationOutcome outcome = PreparationOutcome::CannotPrepare;
|
||||||
|
ElementDescription proposed;
|
||||||
|
QString strReason;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery::ShapeApi
|
||||||
|
|
||||||
|
Q_DECLARE_METATYPE(TikzRefinery::ShapeApi::ElementDescription)
|
||||||
|
Q_DECLARE_METATYPE(TikzRefinery::ShapeApi::PresentationDescription)
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "ShapeTypes.h"
|
||||||
|
#include <QtPlugin>
|
||||||
|
|
||||||
|
#define TKR_SHAPE_PROVIDER_IID "org.tikzrefinery.ShapeProvider/1.0"
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
// Strategy interface; native modules require the exact documented build contract.
|
||||||
|
class tkrShapeProvider
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual ~tkrShapeProvider() = default;
|
||||||
|
virtual QStringList availableOperations(const ShapeApi::ElementDescription &description) const = 0;
|
||||||
|
virtual ShapeApi::PresentationDescription describePresentation(
|
||||||
|
const ShapeApi::ElementDescription &description) const = 0;
|
||||||
|
virtual ShapeApi::PreparationResult prepareOperation(const ShapeApi::OperationRequest &request) const = 0;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
|
|
||||||
|
Q_DECLARE_INTERFACE(TikzRefinery::tkrShapeProvider, TKR_SHAPE_PROVIDER_IID)
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
"id": "org.tikzrefinery.rectangle",
|
||||||
|
"name": "TikZRefinery Rectangle",
|
||||||
|
"version": "@strDocumentVersion@",
|
||||||
|
"role": "shape",
|
||||||
|
"apiVersion": 1,
|
||||||
|
"shapeType": "tkr.rectangle.opposite-corners",
|
||||||
|
"geometrySchemaVersion": 1,
|
||||||
|
"parameterSchemaVersion": 1,
|
||||||
|
"operations": ["tkr.move", "tkr.resize"],
|
||||||
|
"buildKey": "@strShapeBuildKey@"
|
||||||
|
}
|
||||||
@@ -0,0 +1,160 @@
|
|||||||
|
#include "tkrRectangleShapeProvider.h"
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
|
#include <cmath>
|
||||||
|
#include <limits>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
namespace {
|
||||||
|
using namespace ShapeApi;
|
||||||
|
|
||||||
|
bool finitePoint(const QPointF &ptPosition)
|
||||||
|
{
|
||||||
|
return std::isfinite(ptPosition.x()) && std::isfinite(ptPosition.y());
|
||||||
|
}
|
||||||
|
|
||||||
|
bool supported(const ElementDescription &description)
|
||||||
|
{
|
||||||
|
return description.strFamily == strRectangleFamily && description.strType == strRectangleType
|
||||||
|
&& description.iSchemaVersion == iRectangleSchemaVersion
|
||||||
|
&& description.strStrokeColor == QStringLiteral("black") && description.strContent.isEmpty()
|
||||||
|
&& finitePoint(description.ptFirstCentimeters) && finitePoint(description.ptSecondCentimeters)
|
||||||
|
&& finitePoint(description.ptSecondCentimeters - description.ptFirstCentimeters)
|
||||||
|
&& std::isfinite(description.rLineWidthPoints) && description.rLineWidthPoints > 0
|
||||||
|
&& description.ptFirstCentimeters.x() != description.ptSecondCentimeters.x()
|
||||||
|
&& description.ptFirstCentimeters.y() != description.ptSecondCentimeters.y();
|
||||||
|
}
|
||||||
|
|
||||||
|
qreal rounded(qreal rValue)
|
||||||
|
{
|
||||||
|
return std::round(rValue * rCoordinateStepsPerCentimeter) / rCoordinateStepsPerCentimeter;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool boundedOffset(qreal rRequested, qreal rLow, qreal rHigh, qreal &rResult)
|
||||||
|
{
|
||||||
|
const qreal rLowStep = std::isfinite(rLow)
|
||||||
|
? std::ceil(rLow * rCoordinateStepsPerCentimeter) / rCoordinateStepsPerCentimeter : rLow;
|
||||||
|
const qreal rHighStep = std::isfinite(rHigh)
|
||||||
|
? std::floor(rHigh * rCoordinateStepsPerCentimeter) / rCoordinateStepsPerCentimeter : rHigh;
|
||||||
|
if (rLowStep > rHighStep) return false;
|
||||||
|
rResult = std::clamp(rounded(rRequested), rLowStep, rHighStep);
|
||||||
|
return std::isfinite(rResult);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool resizeAxis(qreal rOriginal, qreal rFixed, qreal rRequested, qreal rLow, qreal rHigh,
|
||||||
|
qreal rMinimum, qreal &rResult)
|
||||||
|
{
|
||||||
|
const bool bPositive = rRequested == rFixed ? rOriginal > rFixed : rRequested > rFixed;
|
||||||
|
const auto trySide = [&](bool bSide) {
|
||||||
|
const qreal rMin = bSide ? std::max(rLow, rFixed + rMinimum) : rLow;
|
||||||
|
const qreal rMax = bSide ? rHigh : std::min(rHigh, rFixed - rMinimum);
|
||||||
|
qreal rOffset = 0;
|
||||||
|
if (!boundedOffset(rRequested - rOriginal, rMin - rOriginal, rMax - rOriginal, rOffset)) return false;
|
||||||
|
rResult = rOriginal + rOffset;
|
||||||
|
return true;
|
||||||
|
};
|
||||||
|
return trySide(bPositive) || trySide(!bPositive);
|
||||||
|
}
|
||||||
|
} // namespace
|
||||||
|
|
||||||
|
QStringList tkrRectangleShapeProvider::availableOperations(const ShapeApi::ElementDescription &description) const
|
||||||
|
{
|
||||||
|
return supported(description) ? QStringList{strMoveOperation, strResizeOperation} : QStringList{};
|
||||||
|
}
|
||||||
|
|
||||||
|
ShapeApi::PresentationDescription tkrRectangleShapeProvider::describePresentation(
|
||||||
|
const ShapeApi::ElementDescription &description) const
|
||||||
|
{
|
||||||
|
PresentationDescription presentation;
|
||||||
|
if (!supported(description)) {
|
||||||
|
presentation.strReason = QStringLiteral("Unsupported rectangle description/schema or geometry.");
|
||||||
|
return presentation;
|
||||||
|
}
|
||||||
|
const QPointF &ptFirst = description.ptFirstCentimeters;
|
||||||
|
const QPointF &ptSecond = description.ptSecondCentimeters;
|
||||||
|
presentation.bAvailable = true;
|
||||||
|
presentation.strReadableDescription = QStringLiteral("Rectangle %1").arg(description.uElementId);
|
||||||
|
presentation.rectOutlineCentimeters = QRectF(ptFirst, ptSecond).normalized();
|
||||||
|
presentation.rectSelectionCentimeters = presentation.rectOutlineCentimeters;
|
||||||
|
presentation.vecHandles = {{HandleId::FirstFirst, ptFirst},
|
||||||
|
{HandleId::FirstSecond, {ptFirst.x(), ptSecond.y()}},
|
||||||
|
{HandleId::SecondFirst, {ptSecond.x(), ptFirst.y()}},
|
||||||
|
{HandleId::SecondSecond, ptSecond}};
|
||||||
|
return presentation;
|
||||||
|
}
|
||||||
|
|
||||||
|
ShapeApi::PreparationResult tkrRectangleShapeProvider::prepareOperation(const ShapeApi::OperationRequest &request) const
|
||||||
|
{
|
||||||
|
PreparationResult result;
|
||||||
|
result.proposed = request.initial;
|
||||||
|
if (!availableOperations(request.initial).contains(request.strOperationId)
|
||||||
|
|| request.iParameterSchemaVersion != iParameterSchemaVersion
|
||||||
|
|| request.documentId != request.initial.documentId
|
||||||
|
|| request.documentId.isNull() || !request.uElementId || !request.uRevision
|
||||||
|
|| request.uElementId != request.initial.uElementId || request.uRevision != request.initial.uRevision
|
||||||
|
|| !finitePoint(request.ptTotalDisplacementCentimeters)) {
|
||||||
|
result.strReason = QStringLiteral("Unsupported operation/schema, stale target or non-finite displacement.");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
const EditingConstraints &constraints = request.constraints;
|
||||||
|
if (!std::isfinite(constraints.rMinimumWidthCentimeters) || constraints.rMinimumWidthCentimeters <= 0
|
||||||
|
|| !std::isfinite(constraints.rMinimumHeightCentimeters) || constraints.rMinimumHeightCentimeters <= 0
|
||||||
|
|| (constraints.bHasFixedBounds && (!constraints.rectBoundsCentimeters.isValid()
|
||||||
|
|| !finitePoint(constraints.rectBoundsCentimeters.topLeft())
|
||||||
|
|| !finitePoint(constraints.rectBoundsCentimeters.bottomRight())))) {
|
||||||
|
result.strReason = QStringLiteral("Invalid editing constraints.");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
const qreal rInfinity = std::numeric_limits<qreal>::infinity();
|
||||||
|
qreal rLeft = -rInfinity, rRight = rInfinity, rBottom = -rInfinity, rTop = rInfinity;
|
||||||
|
if (constraints.bHasFixedBounds) {
|
||||||
|
const qreal rMargin = request.initial.rLineWidthPoints * rCentimetersPerTexPoint * rHalfStroke;
|
||||||
|
rLeft = constraints.rectBoundsCentimeters.left() + rMargin;
|
||||||
|
rRight = constraints.rectBoundsCentimeters.right() - rMargin;
|
||||||
|
rBottom = constraints.rectBoundsCentimeters.top() + rMargin;
|
||||||
|
rTop = constraints.rectBoundsCentimeters.bottom() - rMargin;
|
||||||
|
}
|
||||||
|
const QPointF &ptDelta = request.ptTotalDisplacementCentimeters;
|
||||||
|
if (request.strOperationId == strMoveOperation) {
|
||||||
|
const QRectF rectInitial(request.initial.ptFirstCentimeters, request.initial.ptSecondCentimeters);
|
||||||
|
const QRectF rectNormalized = rectInitial.normalized();
|
||||||
|
qreal rX = 0, rY = 0;
|
||||||
|
if (!boundedOffset(ptDelta.x(), rLeft - rectNormalized.left(), rRight - rectNormalized.right(), rX)
|
||||||
|
|| !boundedOffset(ptDelta.y(), rBottom - rectNormalized.top(), rTop - rectNormalized.bottom(), rY)) {
|
||||||
|
result.strReason = QStringLiteral("No valid position inside the editing extent.");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
result.proposed.ptFirstCentimeters += QPointF(rX, rY);
|
||||||
|
result.proposed.ptSecondCentimeters += QPointF(rX, rY);
|
||||||
|
} else {
|
||||||
|
const bool bFirstX = request.handleId == HandleId::FirstFirst || request.handleId == HandleId::FirstSecond;
|
||||||
|
const bool bFirstY = request.handleId == HandleId::FirstFirst || request.handleId == HandleId::SecondFirst;
|
||||||
|
if (request.handleId != HandleId::FirstFirst && request.handleId != HandleId::FirstSecond
|
||||||
|
&& request.handleId != HandleId::SecondFirst && request.handleId != HandleId::SecondSecond) {
|
||||||
|
result.strReason = QStringLiteral("Unsupported resize handle.");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
const QPointF &ptFirst = request.initial.ptFirstCentimeters;
|
||||||
|
const QPointF &ptSecond = request.initial.ptSecondCentimeters;
|
||||||
|
const qreal rOriginalX = bFirstX ? ptFirst.x() : ptSecond.x();
|
||||||
|
const qreal rOriginalY = bFirstY ? ptFirst.y() : ptSecond.y();
|
||||||
|
const qreal rFixedX = bFirstX ? ptSecond.x() : ptFirst.x();
|
||||||
|
const qreal rFixedY = bFirstY ? ptSecond.y() : ptFirst.y();
|
||||||
|
qreal rX = 0, rY = 0;
|
||||||
|
if (!resizeAxis(rOriginalX, rFixedX, rOriginalX + ptDelta.x(), rLeft, rRight,
|
||||||
|
constraints.rMinimumWidthCentimeters, rX)
|
||||||
|
|| !resizeAxis(rOriginalY, rFixedY, rOriginalY + ptDelta.y(), rBottom, rTop,
|
||||||
|
constraints.rMinimumHeightCentimeters, rY)) {
|
||||||
|
result.strReason = QStringLiteral("The extent cannot accommodate the minimum rectangle size.");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
(bFirstX ? result.proposed.ptFirstCentimeters : result.proposed.ptSecondCentimeters).setX(rX);
|
||||||
|
(bFirstY ? result.proposed.ptFirstCentimeters : result.proposed.ptSecondCentimeters).setY(rY);
|
||||||
|
}
|
||||||
|
result.outcome = result.proposed.ptFirstCentimeters == request.initial.ptFirstCentimeters
|
||||||
|
&& result.proposed.ptSecondCentimeters == request.initial.ptSecondCentimeters
|
||||||
|
? PreparationOutcome::Unchanged : PreparationOutcome::PreparedChange;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "tkrShapeProvider.h"
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
class tkrRectangleShapeProvider final : public QObject, public tkrShapeProvider
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
Q_PLUGIN_METADATA(IID TKR_SHAPE_PROVIDER_IID FILE "rectangle-plugin.json")
|
||||||
|
Q_INTERFACES(TikzRefinery::tkrShapeProvider)
|
||||||
|
public:
|
||||||
|
QStringList availableOperations(const ShapeApi::ElementDescription &description) const override;
|
||||||
|
ShapeApi::PresentationDescription describePresentation(
|
||||||
|
const ShapeApi::ElementDescription &description) const override;
|
||||||
|
ShapeApi::PreparationResult prepareOperation(const ShapeApi::OperationRequest &request) const override;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
|
||||||
@@ -0,0 +1,283 @@
|
|||||||
|
#include "controller/tkrEditorController.h"
|
||||||
|
|
||||||
|
#include "model/tkrTikzDocument.h"
|
||||||
|
#include "ui/tkrDiagramScene.h"
|
||||||
|
|
||||||
|
#include <QFile>
|
||||||
|
#include <QFileInfo>
|
||||||
|
#include <QSaveFile>
|
||||||
|
#include <algorithm>
|
||||||
|
#include <cmath>
|
||||||
|
#include <new>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
tkrEditorController::tkrEditorController(tkrTikzDocument &document, tkrDiagramScene &diagramScene,
|
||||||
|
QObject *pParent)
|
||||||
|
: QObject(pParent), m_refDocument(document), m_refScene(diagramScene)
|
||||||
|
{
|
||||||
|
connect(&m_refScene, &tkrDiagramScene::dragPreviewRequested,
|
||||||
|
this, &tkrEditorController::handleDragPreview);
|
||||||
|
connect(&m_refScene, &tkrDiagramScene::dragCommitRequested,
|
||||||
|
this, &tkrEditorController::handleDragCommit);
|
||||||
|
connect(&m_refScene, &tkrDiagramScene::dragCancelled,
|
||||||
|
this, &tkrEditorController::cancelDrag);
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrEditorController::openDocument(const QString &strFilePath)
|
||||||
|
{
|
||||||
|
QFile fileSource(strFilePath);
|
||||||
|
if (!fileSource.open(QIODevice::ReadOnly)) {
|
||||||
|
return {false, fileSource.errorString()};
|
||||||
|
}
|
||||||
|
const QByteArray baSource = fileSource.readAll();
|
||||||
|
if (fileSource.error() != QFileDevice::NoError) {
|
||||||
|
return {false, fileSource.errorString()};
|
||||||
|
}
|
||||||
|
m_refScene.cancelInteraction();
|
||||||
|
m_refDocument.loadSource(baSource, QFileInfo(fileSource).absoluteFilePath());
|
||||||
|
m_baFileBaseline = baSource;
|
||||||
|
const OperationResult resultParse = refreshParsedDocument();
|
||||||
|
emit documentChanged();
|
||||||
|
// Reading succeeded even when source interpretation is unavailable.
|
||||||
|
return {true, resultParse.strMessage};
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrEditorController::saveDocument()
|
||||||
|
{
|
||||||
|
m_refScene.cancelInteraction();
|
||||||
|
if (!m_refDocument.isLoaded()) {
|
||||||
|
return {false, QStringLiteral("No document is open.")};
|
||||||
|
}
|
||||||
|
if (!m_refDocument.hasUnsavedChanges()) {
|
||||||
|
return {true, QStringLiteral("No changes to save.")};
|
||||||
|
}
|
||||||
|
QFile fileExisting(m_refDocument.filePath());
|
||||||
|
if (!fileExisting.open(QIODevice::ReadOnly)) {
|
||||||
|
return {false, fileExisting.errorString()};
|
||||||
|
}
|
||||||
|
const QByteArray baExisting = fileExisting.readAll();
|
||||||
|
if (fileExisting.error() != QFileDevice::NoError) {
|
||||||
|
return {false, fileExisting.errorString()};
|
||||||
|
}
|
||||||
|
fileExisting.close();
|
||||||
|
if (baExisting != m_baFileBaseline) {
|
||||||
|
return {false, QStringLiteral("The file changed outside the editor. Saving was cancelled.")};
|
||||||
|
}
|
||||||
|
QSaveFile fileOutput(m_refDocument.filePath());
|
||||||
|
fileOutput.setDirectWriteFallback(false);
|
||||||
|
if (!fileOutput.open(QIODevice::WriteOnly)) {
|
||||||
|
return {false, fileOutput.errorString()};
|
||||||
|
}
|
||||||
|
if (fileOutput.write(m_refDocument.sourceBytes()) != m_refDocument.sourceBytes().size()) {
|
||||||
|
fileOutput.cancelWriting();
|
||||||
|
return {false, fileOutput.errorString()};
|
||||||
|
}
|
||||||
|
if (!fileOutput.commit()) {
|
||||||
|
return {false, fileOutput.errorString()};
|
||||||
|
}
|
||||||
|
m_baFileBaseline = m_refDocument.sourceBytes();
|
||||||
|
m_refDocument.markSaved();
|
||||||
|
emit documentChanged();
|
||||||
|
return {true, QStringLiteral("Document saved.")};
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrEditorController::refreshParsedDocument()
|
||||||
|
{
|
||||||
|
if (!m_refDocument.isLoaded()) {
|
||||||
|
return {false, QStringLiteral("No document is open.")};
|
||||||
|
}
|
||||||
|
const ParseResult parseResult = m_parser.parse(m_refDocument.sourceBytes(),
|
||||||
|
m_refDocument.revision());
|
||||||
|
m_comparisonExtent = parseResult.comparisonExtent;
|
||||||
|
m_refScene.resetDiagram();
|
||||||
|
// Clear records even on failure, so a failed refresh cannot leave stale geometry.
|
||||||
|
const OperationResult resultClear = m_refDocument.setParsedElements({}, m_refDocument.revision());
|
||||||
|
if (!resultClear.bSucceeded) {
|
||||||
|
return resultClear;
|
||||||
|
}
|
||||||
|
if (!parseResult.bSafeToEdit) {
|
||||||
|
const QString strMessage = parseResult.listDiagnostics.join(QLatin1Char('\n'));
|
||||||
|
emit statusChanged(strMessage);
|
||||||
|
return {false, strMessage};
|
||||||
|
}
|
||||||
|
const OperationResult resultStore = m_refDocument.setParsedElements(
|
||||||
|
parseResult.vecElements, m_refDocument.revision());
|
||||||
|
if (!resultStore.bSucceeded) {
|
||||||
|
emit statusChanged(resultStore.strMessage);
|
||||||
|
return resultStore;
|
||||||
|
}
|
||||||
|
const OperationResult resultDisplay = m_refScene.displayElements(
|
||||||
|
m_refDocument.elements(), m_mapper, parseResult.comparisonExtent);
|
||||||
|
if (!resultDisplay.bSucceeded) {
|
||||||
|
m_refDocument.setParsedElements({}, m_refDocument.revision());
|
||||||
|
}
|
||||||
|
emit statusChanged(resultDisplay.bSucceeded
|
||||||
|
? QStringLiteral("Displayed %1 element(s). Drag to move; select a rectangle, then drag a corner to resize. Esc cancels; Ctrl+S saves.")
|
||||||
|
.arg(parseResult.vecElements.size())
|
||||||
|
: resultDisplay.strMessage);
|
||||||
|
return resultDisplay;
|
||||||
|
}
|
||||||
|
|
||||||
|
void tkrEditorController::handleDragPreview(const DragUpdate &dragUpdate)
|
||||||
|
{
|
||||||
|
const OperationResult resultValid = validateDrag(dragUpdate);
|
||||||
|
if (!resultValid.bSucceeded) {
|
||||||
|
m_refScene.cancelInteraction();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const GestureGeometry geometry = prepareGesture(dragUpdate);
|
||||||
|
if (!geometry.result.bSucceeded) {
|
||||||
|
m_refScene.cancelInteraction();
|
||||||
|
return; // Preview failures do not produce repeated rejection banners.
|
||||||
|
}
|
||||||
|
const OperationResult resultPreview = m_refScene.previewGeometry(dragUpdate.uElementId, dragUpdate.uDocumentRevision,
|
||||||
|
m_mapper.mapToScene(geometry.ptFirstTikzPosition), m_mapper.mapToScene(geometry.ptSecondTikzPosition),
|
||||||
|
dragUpdate.dragKind != DragKind::WholeElement);
|
||||||
|
if (!resultPreview.bSucceeded) {
|
||||||
|
m_refScene.cancelInteraction();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
emit statusChanged(QStringLiteral("Editing element. Release to apply; Esc cancels."));
|
||||||
|
}
|
||||||
|
|
||||||
|
void tkrEditorController::handleDragCommit(const DragUpdate &dragUpdate) try
|
||||||
|
{
|
||||||
|
const OperationResult resultValid = validateDrag(dragUpdate);
|
||||||
|
if (!resultValid.bSucceeded) {
|
||||||
|
rejectDrag(resultValid.strMessage);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const auto iterElement = std::find_if(m_refDocument.elements().cbegin(), m_refDocument.elements().cend(),
|
||||||
|
[&dragUpdate](const ElementRecord &element) { return element.uElementId == dragUpdate.uElementId; });
|
||||||
|
const GestureGeometry geometry = prepareGesture(dragUpdate);
|
||||||
|
QVector<CoordinateEdit> vecEdits;
|
||||||
|
const OperationResult resultPrepare = m_editService.prepareEdits(*iterElement, m_refDocument.sourceBytes(), geometry, vecEdits);
|
||||||
|
if (!resultPrepare.bSucceeded) {
|
||||||
|
rejectDrag(resultPrepare.strMessage);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (vecEdits.isEmpty()) {
|
||||||
|
refreshParsedDocument();
|
||||||
|
m_refScene.selectElement(dragUpdate.uElementId);
|
||||||
|
emit statusChanged(QStringLiteral("No coordinate change."));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Validate the entire proposed source and display before mutating the model.
|
||||||
|
const QString strDescription = dragUpdate.dragKind == DragKind::WholeElement
|
||||||
|
? QStringLiteral("Move element") : QStringLiteral("Resize rectangle");
|
||||||
|
tkrTikzDocument documentCandidate = m_refDocument;
|
||||||
|
const OperationResult resultCandidate = documentCandidate.applyCoordinateEdits(vecEdits, strDescription);
|
||||||
|
if (!resultCandidate.bSucceeded) {
|
||||||
|
rejectDrag(resultCandidate.strMessage);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const ParseResult parseCandidate = m_parser.parse(documentCandidate.sourceBytes(), documentCandidate.revision());
|
||||||
|
if (!parseCandidate.bSafeToEdit) {
|
||||||
|
rejectDrag(parseCandidate.listDiagnostics.join(QLatin1Char('\n')));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const OperationResult resultRecords = documentCandidate.setParsedElements(parseCandidate.vecElements, documentCandidate.revision());
|
||||||
|
if (!resultRecords.bSucceeded) {
|
||||||
|
rejectDrag(resultRecords.strMessage);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const OperationResult resultDisplay = m_refScene.displayElements(documentCandidate.elements(), m_mapper,
|
||||||
|
parseCandidate.comparisonExtent);
|
||||||
|
if (!resultDisplay.bSucceeded) {
|
||||||
|
rejectDrag(resultDisplay.strMessage);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const OperationResult resultApply = m_refDocument.acceptPreparedState(documentCandidate, dragUpdate.uDocumentRevision);
|
||||||
|
if (!resultApply.bSucceeded) {
|
||||||
|
rejectDrag(resultApply.strMessage);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
m_comparisonExtent = parseCandidate.comparisonExtent;
|
||||||
|
m_refScene.selectElement(dragUpdate.uElementId);
|
||||||
|
emit documentChanged();
|
||||||
|
emit statusChanged(QStringLiteral("Element edited. Ctrl+S saves the updated source."));
|
||||||
|
}
|
||||||
|
catch (const std::bad_alloc &)
|
||||||
|
{
|
||||||
|
rejectDrag(QStringLiteral("Insufficient memory to prepare this edit."));
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrEditorController::undo() { return restoreHistory(false); }
|
||||||
|
OperationResult tkrEditorController::redo() { return restoreHistory(true); }
|
||||||
|
|
||||||
|
OperationResult tkrEditorController::restoreHistory(bool bRedo) try
|
||||||
|
{
|
||||||
|
// A pending mouse release must never commit a preview after restoration.
|
||||||
|
m_refScene.cancelInteraction();
|
||||||
|
tkrTikzDocument documentCandidate = m_refDocument;
|
||||||
|
const OperationResult resultCandidate = documentCandidate.restoreHistory(bRedo);
|
||||||
|
if (!resultCandidate.bSucceeded) return resultCandidate;
|
||||||
|
const ParseResult parseCandidate = m_parser.parse(documentCandidate.sourceBytes(), documentCandidate.revision());
|
||||||
|
if (!parseCandidate.bSafeToEdit) {
|
||||||
|
return {false, parseCandidate.listDiagnostics.join(QLatin1Char('\n'))};
|
||||||
|
}
|
||||||
|
const OperationResult resultRecords = documentCandidate.setParsedElements(
|
||||||
|
parseCandidate.vecElements, documentCandidate.revision());
|
||||||
|
if (!resultRecords.bSucceeded) return resultRecords;
|
||||||
|
const OperationResult resultDisplay = m_refScene.displayElements(documentCandidate.elements(), m_mapper,
|
||||||
|
parseCandidate.comparisonExtent);
|
||||||
|
if (!resultDisplay.bSucceeded) {
|
||||||
|
refreshParsedDocument();
|
||||||
|
return resultDisplay;
|
||||||
|
}
|
||||||
|
const OperationResult resultRestore = m_refDocument.acceptPreparedState(documentCandidate, m_refDocument.revision());
|
||||||
|
if (!resultRestore.bSucceeded) {
|
||||||
|
refreshParsedDocument();
|
||||||
|
return resultRestore;
|
||||||
|
}
|
||||||
|
m_comparisonExtent = parseCandidate.comparisonExtent;
|
||||||
|
emit documentChanged();
|
||||||
|
const QString strMessage = bRedo ? QStringLiteral("Edit redone. Ctrl+S saves.")
|
||||||
|
: QStringLiteral("Edit undone. Ctrl+S saves.");
|
||||||
|
emit statusChanged(strMessage);
|
||||||
|
return {true, strMessage};
|
||||||
|
}
|
||||||
|
catch (const std::bad_alloc &)
|
||||||
|
{
|
||||||
|
refreshParsedDocument();
|
||||||
|
return {false, QStringLiteral("Insufficient memory to prepare history restoration.")};
|
||||||
|
}
|
||||||
|
|
||||||
|
void tkrEditorController::cancelDrag()
|
||||||
|
{
|
||||||
|
refreshParsedDocument();
|
||||||
|
emit statusChanged(QStringLiteral("Edit cancelled. Source unchanged."));
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrEditorController::validateDrag(const DragUpdate &dragUpdate) const
|
||||||
|
{
|
||||||
|
if (!m_refDocument.isLoaded() || dragUpdate.uDocumentRevision != m_refDocument.revision()) {
|
||||||
|
return {false, QStringLiteral("The document changed during this drag.")};
|
||||||
|
}
|
||||||
|
if (!std::isfinite(dragUpdate.ptInitialScenePosition.x()) || !std::isfinite(dragUpdate.ptInitialScenePosition.y())
|
||||||
|
|| !std::isfinite(dragUpdate.ptCurrentScenePosition.x()) || !std::isfinite(dragUpdate.ptCurrentScenePosition.y())) {
|
||||||
|
return {false, QStringLiteral("Unsupported or invalid drag.")};
|
||||||
|
}
|
||||||
|
for (const ElementRecord &elementRecord : m_refDocument.elements()) {
|
||||||
|
if (elementRecord.uElementId == dragUpdate.uElementId && elementRecord.uDocumentRevision == dragUpdate.uDocumentRevision) {
|
||||||
|
return prepareGesture(dragUpdate).result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return {false, QStringLiteral("The dragged element is no longer available.")};
|
||||||
|
}
|
||||||
|
|
||||||
|
GestureGeometry tkrEditorController::prepareGesture(const DragUpdate &dragUpdate) const
|
||||||
|
{
|
||||||
|
const auto iterElement = std::find_if(m_refDocument.elements().cbegin(), m_refDocument.elements().cend(),
|
||||||
|
[&dragUpdate](const ElementRecord &element) { return element.uElementId == dragUpdate.uElementId; });
|
||||||
|
if (iterElement == m_refDocument.elements().cend()) return {{false, QStringLiteral("Element unavailable.")}, {}, {}};
|
||||||
|
return m_editService.prepareGeometry(*iterElement, dragUpdate, m_mapper, m_comparisonExtent, m_refScene.shapeProvider());
|
||||||
|
}
|
||||||
|
|
||||||
|
void tkrEditorController::rejectDrag(const QString &strReason)
|
||||||
|
{
|
||||||
|
refreshParsedDocument();
|
||||||
|
emit statusChanged(QStringLiteral("Edit rejected: %1 Source unchanged.").arg(strReason));
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,51 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "geometry/tkrCoordinateMapper.h"
|
||||||
|
#include "parsing/tkrTikzParserExplicit.h"
|
||||||
|
#include "editing/tkrEditService.h"
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
class tkrDiagramScene;
|
||||||
|
class tkrTikzDocument;
|
||||||
|
|
||||||
|
// References document/scene; owns parser/mapper as value members.
|
||||||
|
class tkrEditorController final : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
tkrEditorController(tkrTikzDocument &document, tkrDiagramScene &diagramScene,
|
||||||
|
QObject *pParent = nullptr);
|
||||||
|
OperationResult openDocument(const QString &strFilePath);
|
||||||
|
OperationResult saveDocument();
|
||||||
|
OperationResult refreshParsedDocument();
|
||||||
|
OperationResult undo();
|
||||||
|
OperationResult redo();
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
void handleDragPreview(const TikzRefinery::DragUpdate &dragUpdate);
|
||||||
|
void handleDragCommit(const TikzRefinery::DragUpdate &dragUpdate);
|
||||||
|
void cancelDrag();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void documentChanged();
|
||||||
|
void statusChanged(const QString &strMessage);
|
||||||
|
|
||||||
|
private:
|
||||||
|
OperationResult validateDrag(const DragUpdate &dragUpdate) const;
|
||||||
|
GestureGeometry prepareGesture(const DragUpdate &dragUpdate) const;
|
||||||
|
void rejectDrag(const QString &strReason);
|
||||||
|
OperationResult restoreHistory(bool bRedo);
|
||||||
|
tkrTikzDocument &m_refDocument;
|
||||||
|
tkrDiagramScene &m_refScene;
|
||||||
|
tkrTikzParserExplicit m_parser;
|
||||||
|
tkrCoordinateMapper m_mapper;
|
||||||
|
tkrEditService m_editService;
|
||||||
|
ComparisonExtent m_comparisonExtent;
|
||||||
|
QByteArray m_baFileBaseline;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
#include "editing/tkrEditHistory.h"
|
||||||
|
#include <utility>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
namespace { constexpr qsizetype nEntryStep = 1; }
|
||||||
|
bool tkrEditHistory::canUndo() const { return m_nCursor > 0; }
|
||||||
|
bool tkrEditHistory::canRedo() const { return m_nCursor < m_vecEntries.size(); }
|
||||||
|
QString tkrEditHistory::undoDescription() const
|
||||||
|
{ return canUndo() ? m_vecEntries.at(m_nCursor - nEntryStep).strDescription : QString(); }
|
||||||
|
QString tkrEditHistory::redoDescription() const
|
||||||
|
{ return canRedo() ? m_vecEntries.at(m_nCursor).strDescription : QString(); }
|
||||||
|
void tkrEditHistory::record(const QByteArray &baBefore, const QByteArray &baAfter,
|
||||||
|
const QString &strDescription)
|
||||||
|
{
|
||||||
|
// Prepare detached storage first. Allocation failure cannot discard the redo branch.
|
||||||
|
QVector<Entry> vecPrepared = m_vecEntries;
|
||||||
|
vecPrepared.resize(m_nCursor);
|
||||||
|
vecPrepared.append({baBefore, baAfter, strDescription});
|
||||||
|
m_vecEntries.swap(vecPrepared);
|
||||||
|
m_nCursor = m_vecEntries.size();
|
||||||
|
}
|
||||||
|
void tkrEditHistory::clear() { QVector<Entry>().swap(m_vecEntries); m_nCursor = 0; }
|
||||||
|
QByteArray tkrEditHistory::restorationSource(bool bRedo) const
|
||||||
|
{
|
||||||
|
return bRedo ? m_vecEntries.at(m_nCursor).baAfter
|
||||||
|
: m_vecEntries.at(m_nCursor - nEntryStep).baBefore;
|
||||||
|
}
|
||||||
|
void tkrEditHistory::advance(bool bRedo) { m_nCursor += bRedo ? nEntryStep : -nEntryStep; }
|
||||||
|
void tkrEditHistory::swap(tkrEditHistory &historyOther) noexcept
|
||||||
|
{
|
||||||
|
m_vecEntries.swap(historyOther.m_vecEntries);
|
||||||
|
std::swap(m_nCursor, historyOther.m_nCursor);
|
||||||
|
}
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <QByteArray>
|
||||||
|
#include <QString>
|
||||||
|
#include <QVector>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
class tkrTikzDocument;
|
||||||
|
|
||||||
|
// Session-only value storage. Only the document may publish or traverse entries.
|
||||||
|
class tkrEditHistory final
|
||||||
|
{
|
||||||
|
friend class tkrTikzDocument;
|
||||||
|
public:
|
||||||
|
bool canUndo() const;
|
||||||
|
bool canRedo() const;
|
||||||
|
QString undoDescription() const;
|
||||||
|
QString redoDescription() const;
|
||||||
|
|
||||||
|
private:
|
||||||
|
struct Entry {
|
||||||
|
QByteArray baBefore;
|
||||||
|
QByteArray baAfter;
|
||||||
|
QString strDescription;
|
||||||
|
};
|
||||||
|
void record(const QByteArray &baBefore, const QByteArray &baAfter,
|
||||||
|
const QString &strDescription);
|
||||||
|
void clear();
|
||||||
|
QByteArray restorationSource(bool bRedo) const;
|
||||||
|
void advance(bool bRedo);
|
||||||
|
void swap(tkrEditHistory &historyOther) noexcept;
|
||||||
|
QVector<Entry> m_vecEntries;
|
||||||
|
qsizetype m_nCursor = 0;
|
||||||
|
};
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,268 @@
|
|||||||
|
#include "editing/tkrEditService.h"
|
||||||
|
#include "geometry/ShapeGeometryLimits.h"
|
||||||
|
#include "plugins/ShapeProviderAdapter.h"
|
||||||
|
#include "tkrShapeProvider.h"
|
||||||
|
|
||||||
|
#include <QRectF>
|
||||||
|
#include <QRegularExpression>
|
||||||
|
#include <algorithm>
|
||||||
|
#include <cmath>
|
||||||
|
#include <limits>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
namespace {
|
||||||
|
|
||||||
|
struct DecimalValue
|
||||||
|
{
|
||||||
|
bool bNegative = false;
|
||||||
|
QByteArray baDigits;
|
||||||
|
qsizetype nDecimals = 0;
|
||||||
|
};
|
||||||
|
|
||||||
|
QByteArray trimLeadingZeros(const QByteArray &baDigits)
|
||||||
|
{
|
||||||
|
qsizetype nFirst = 0;
|
||||||
|
while (nFirst + 1 < baDigits.size() && baDigits.at(nFirst) == '0') {
|
||||||
|
++nFirst;
|
||||||
|
}
|
||||||
|
return baDigits.mid(nFirst);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool readDecimal(const QByteArray &baText, DecimalValue &decimalValue)
|
||||||
|
{
|
||||||
|
static const QRegularExpression expressionNumber(
|
||||||
|
QStringLiteral(R"(\A[+-]?(?:[0-9]+(?:\.[0-9]*)?|\.[0-9]+)\z)"));
|
||||||
|
if (!expressionNumber.match(QString::fromLatin1(baText)).hasMatch()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
decimalValue.baDigits = baText;
|
||||||
|
decimalValue.bNegative = baText.startsWith('-');
|
||||||
|
if (baText.startsWith('-') || baText.startsWith('+')) {
|
||||||
|
decimalValue.baDigits.remove(0, 1);
|
||||||
|
}
|
||||||
|
const qsizetype nDot = decimalValue.baDigits.indexOf('.');
|
||||||
|
if (nDot >= 0) {
|
||||||
|
decimalValue.nDecimals = decimalValue.baDigits.size() - nDot - 1;
|
||||||
|
decimalValue.baDigits.remove(nDot, 1);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Exact decimal addition preserves the element's size even when the original
|
||||||
|
// coordinate has more fractional digits than the drag's 0.000001 cm precision.
|
||||||
|
bool translateCoordinate(const QByteArray &baOriginal, const QByteArray &baDelta, QByteArray &baResult)
|
||||||
|
{
|
||||||
|
DecimalValue decimalOriginal;
|
||||||
|
DecimalValue decimalDelta;
|
||||||
|
if (!readDecimal(baOriginal, decimalOriginal) || !readDecimal(baDelta, decimalDelta)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
const qsizetype nDecimals = std::max(decimalOriginal.nDecimals, decimalDelta.nDecimals);
|
||||||
|
decimalOriginal.baDigits.append(QByteArray(nDecimals - decimalOriginal.nDecimals, '0'));
|
||||||
|
decimalDelta.baDigits.append(QByteArray(nDecimals - decimalDelta.nDecimals, '0'));
|
||||||
|
decimalOriginal.baDigits = trimLeadingZeros(decimalOriginal.baDigits);
|
||||||
|
decimalDelta.baDigits = trimLeadingZeros(decimalDelta.baDigits);
|
||||||
|
bool bNegative = decimalOriginal.bNegative;
|
||||||
|
const bool bAdd = decimalOriginal.bNegative == decimalDelta.bNegative;
|
||||||
|
if (!bAdd && (decimalOriginal.baDigits.size() < decimalDelta.baDigits.size()
|
||||||
|
|| (decimalOriginal.baDigits.size() == decimalDelta.baDigits.size()
|
||||||
|
&& decimalOriginal.baDigits.compare(decimalDelta.baDigits) < 0))) {
|
||||||
|
std::swap(decimalOriginal, decimalDelta);
|
||||||
|
bNegative = decimalOriginal.bNegative;
|
||||||
|
}
|
||||||
|
qsizetype nOriginal = decimalOriginal.baDigits.size();
|
||||||
|
qsizetype nDelta = decimalDelta.baDigits.size();
|
||||||
|
int iCarry = 0;
|
||||||
|
QByteArray baReversed;
|
||||||
|
while (nOriginal > 0 || nDelta > 0 || (bAdd && iCarry != 0)) {
|
||||||
|
const int iOriginal = nOriginal > 0 ? decimalOriginal.baDigits.at(--nOriginal) - '0' : 0;
|
||||||
|
const int iDelta = nDelta > 0 ? decimalDelta.baDigits.at(--nDelta) - '0' : 0;
|
||||||
|
int iDigit = bAdd ? iOriginal + iDelta + iCarry : iOriginal - iDelta - iCarry;
|
||||||
|
iCarry = bAdd ? iDigit / 10 : (iDigit < 0 ? 1 : 0);
|
||||||
|
if (iDigit < 0) {
|
||||||
|
iDigit += 10;
|
||||||
|
}
|
||||||
|
baReversed.append(static_cast<char>('0' + iDigit % 10));
|
||||||
|
}
|
||||||
|
std::reverse(baReversed.begin(), baReversed.end());
|
||||||
|
baResult = trimLeadingZeros(baReversed);
|
||||||
|
if (nDecimals > 0) {
|
||||||
|
if (baResult.size() <= nDecimals) {
|
||||||
|
baResult.prepend(QByteArray(nDecimals + 1 - baResult.size(), '0'));
|
||||||
|
}
|
||||||
|
baResult.insert(baResult.size() - nDecimals, '.');
|
||||||
|
while (baResult.endsWith('0')) {
|
||||||
|
baResult.chop(1);
|
||||||
|
}
|
||||||
|
if (baResult.endsWith('.')) {
|
||||||
|
baResult.chop(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (bNegative && baResult != "0") {
|
||||||
|
baResult.prepend('-');
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace
|
||||||
|
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
using Limits = ShapeGeometryLimits;
|
||||||
|
|
||||||
|
qreal rounded(qreal rValue)
|
||||||
|
{
|
||||||
|
return std::round(rValue * Limits::rCoordinateStepsPerCentimeter)
|
||||||
|
/ Limits::rCoordinateStepsPerCentimeter;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Quantize an offset inward, keeping the original decimal coordinate as anchor.
|
||||||
|
bool boundedOffset(qreal rRequested, qreal rLow, qreal rHigh, qreal &rResult)
|
||||||
|
{
|
||||||
|
const qreal rLowStep = std::isfinite(rLow)
|
||||||
|
? std::ceil(rLow * Limits::rCoordinateStepsPerCentimeter) / Limits::rCoordinateStepsPerCentimeter : rLow;
|
||||||
|
const qreal rHighStep = std::isfinite(rHigh)
|
||||||
|
? std::floor(rHigh * Limits::rCoordinateStepsPerCentimeter) / Limits::rCoordinateStepsPerCentimeter : rHigh;
|
||||||
|
if (rLowStep > rHighStep) return false;
|
||||||
|
rResult = std::clamp(rounded(rRequested), rLowStep, rHighStep);
|
||||||
|
return std::isfinite(rResult);
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace
|
||||||
|
|
||||||
|
GestureGeometry tkrEditService::prepareGeometry(const ElementRecord &element, const DragUpdate &drag,
|
||||||
|
const tkrCoordinateMapper &mapper,
|
||||||
|
const ComparisonExtent &extent,
|
||||||
|
const tkrShapeProvider *pShapeProvider) const
|
||||||
|
{
|
||||||
|
GestureGeometry geometry{{true, {}}, element.ptFirstTikzPosition, element.ptSecondTikzPosition};
|
||||||
|
const QPointF ptDelta = mapper.mapToTikz(drag.ptCurrentScenePosition)
|
||||||
|
- mapper.mapToTikz(drag.ptInitialScenePosition);
|
||||||
|
if (!std::isfinite(ptDelta.x()) || !std::isfinite(ptDelta.y())) {
|
||||||
|
geometry.result = {false, QStringLiteral("Gesture displacement must be finite.")};
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
if (element.elementKind == ElementKind::Rectangle) {
|
||||||
|
const bool bResize = drag.dragKind == DragKind::RectangleFirstFirst
|
||||||
|
|| drag.dragKind == DragKind::RectangleFirstSecond
|
||||||
|
|| drag.dragKind == DragKind::RectangleSecondFirst
|
||||||
|
|| drag.dragKind == DragKind::RectangleSecondSecond;
|
||||||
|
if (!pShapeProvider || (!bResize && drag.dragKind != DragKind::WholeElement)) {
|
||||||
|
geometry.result = {false, QStringLiteral("Rectangle provider or supported operation is unavailable.")};
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
ShapeApi::OperationRequest request;
|
||||||
|
request.initial = describeShape(element);
|
||||||
|
request.documentId = element.documentId;
|
||||||
|
request.uElementId = element.uElementId;
|
||||||
|
request.uRevision = element.uDocumentRevision;
|
||||||
|
request.strOperationId = bResize ? ShapeApi::strResizeOperation : ShapeApi::strMoveOperation;
|
||||||
|
request.ptTotalDisplacementCentimeters = ptDelta;
|
||||||
|
request.handleId = shapeHandle(drag.dragKind);
|
||||||
|
request.constraints.bHasFixedBounds = extent.bIsPresent;
|
||||||
|
request.constraints.rectBoundsCentimeters = QRectF(extent.ptFirstTikzPosition, extent.ptSecondTikzPosition).normalized();
|
||||||
|
if (!pShapeProvider->availableOperations(request.initial).contains(request.strOperationId)) {
|
||||||
|
geometry.result = {false, QStringLiteral("The rectangle provider does not support this operation.")};
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
const ShapeApi::PreparationResult prepared = pShapeProvider->prepareOperation(request);
|
||||||
|
const auto &proposed = prepared.proposed;
|
||||||
|
const QRectF rectProposed = QRectF(proposed.ptFirstCentimeters, proposed.ptSecondCentimeters).normalized();
|
||||||
|
constexpr qreal rValidationToleranceCentimeters = 0.000000001;
|
||||||
|
const qreal rMargin = outlineMarginCentimeters(element);
|
||||||
|
const QRectF rectAllowed = request.constraints.rectBoundsCentimeters.adjusted(rMargin, rMargin, -rMargin, -rMargin);
|
||||||
|
const bool bSameDescription = proposed.documentId == request.documentId
|
||||||
|
&& proposed.uElementId == request.uElementId && proposed.uRevision == request.uRevision
|
||||||
|
&& proposed.strFamily == request.initial.strFamily && proposed.strType == request.initial.strType
|
||||||
|
&& proposed.iSchemaVersion == request.initial.iSchemaVersion
|
||||||
|
&& proposed.rLineWidthPoints == request.initial.rLineWidthPoints
|
||||||
|
&& proposed.strStrokeColor == request.initial.strStrokeColor && proposed.strContent == request.initial.strContent;
|
||||||
|
const bool bFinite = std::isfinite(rectProposed.left()) && std::isfinite(rectProposed.right())
|
||||||
|
&& std::isfinite(rectProposed.top()) && std::isfinite(rectProposed.bottom())
|
||||||
|
&& std::isfinite(rectProposed.width()) && std::isfinite(rectProposed.height());
|
||||||
|
const bool bWithinBounds = !extent.bIsPresent || (rectAllowed.isValid() && rectAllowed.adjusted(-rValidationToleranceCentimeters,
|
||||||
|
-rValidationToleranceCentimeters, rValidationToleranceCentimeters, rValidationToleranceCentimeters).contains(rectProposed));
|
||||||
|
const bool bValidSize = rectProposed.width() > 0 && rectProposed.height() > 0
|
||||||
|
&& (!bResize || (rectProposed.width() + rValidationToleranceCentimeters >= request.constraints.rMinimumWidthCentimeters
|
||||||
|
&& rectProposed.height() + rValidationToleranceCentimeters >= request.constraints.rMinimumHeightCentimeters));
|
||||||
|
const bool bChanged = proposed.ptFirstCentimeters != request.initial.ptFirstCentimeters
|
||||||
|
|| proposed.ptSecondCentimeters != request.initial.ptSecondCentimeters;
|
||||||
|
const bool bValidOutcome = (prepared.outcome == ShapeApi::PreparationOutcome::PreparedChange && bChanged)
|
||||||
|
|| (prepared.outcome == ShapeApi::PreparationOutcome::Unchanged && !bChanged);
|
||||||
|
const bool bFirstX = drag.dragKind == DragKind::RectangleFirstFirst || drag.dragKind == DragKind::RectangleFirstSecond;
|
||||||
|
const bool bFirstY = drag.dragKind == DragKind::RectangleFirstFirst || drag.dragKind == DragKind::RectangleSecondFirst;
|
||||||
|
const QPointF ptFirstOffset = proposed.ptFirstCentimeters - request.initial.ptFirstCentimeters;
|
||||||
|
const QPointF ptSecondOffset = proposed.ptSecondCentimeters - request.initial.ptSecondCentimeters;
|
||||||
|
const bool bPreservedOperation = bResize
|
||||||
|
? (bFirstX ? proposed.ptSecondCentimeters.x() == request.initial.ptSecondCentimeters.x()
|
||||||
|
: proposed.ptFirstCentimeters.x() == request.initial.ptFirstCentimeters.x())
|
||||||
|
&& (bFirstY ? proposed.ptSecondCentimeters.y() == request.initial.ptSecondCentimeters.y()
|
||||||
|
: proposed.ptFirstCentimeters.y() == request.initial.ptFirstCentimeters.y())
|
||||||
|
: std::abs(ptFirstOffset.x() - ptSecondOffset.x()) <= rValidationToleranceCentimeters
|
||||||
|
&& std::abs(ptFirstOffset.y() - ptSecondOffset.y()) <= rValidationToleranceCentimeters;
|
||||||
|
if (prepared.outcome == ShapeApi::PreparationOutcome::CannotPrepare || !bSameDescription
|
||||||
|
|| !bFinite || !bWithinBounds || !bValidSize || !bValidOutcome || !bPreservedOperation) {
|
||||||
|
geometry.result = {false, prepared.strReason.isEmpty()
|
||||||
|
? QStringLiteral("The provider proposal failed host validation.") : prepared.strReason};
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
geometry.ptFirstTikzPosition = proposed.ptFirstCentimeters;
|
||||||
|
geometry.ptSecondTikzPosition = proposed.ptSecondCentimeters;
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
const qreal rInfinity = std::numeric_limits<qreal>::infinity();
|
||||||
|
qreal rLeft = -rInfinity, rRight = rInfinity, rBottom = -rInfinity, rTop = rInfinity;
|
||||||
|
if (extent.bIsPresent) {
|
||||||
|
const QRectF rectExtent = QRectF(extent.ptFirstTikzPosition, extent.ptSecondTikzPosition).normalized();
|
||||||
|
const qreal rMargin = outlineMarginCentimeters(element);
|
||||||
|
rLeft = rectExtent.left() + rMargin;
|
||||||
|
rRight = rectExtent.right() - rMargin;
|
||||||
|
rBottom = rectExtent.top() + rMargin;
|
||||||
|
rTop = rectExtent.bottom() - rMargin;
|
||||||
|
}
|
||||||
|
if (drag.dragKind == DragKind::WholeElement) {
|
||||||
|
const QRectF rectElement = QRectF(element.ptFirstTikzPosition, element.ptSecondTikzPosition).normalized();
|
||||||
|
qreal rX = 0, rY = 0;
|
||||||
|
if (!boundedOffset(ptDelta.x(), rLeft - rectElement.left(), rRight - rectElement.right(), rX)
|
||||||
|
|| !boundedOffset(ptDelta.y(), rBottom - rectElement.top(), rTop - rectElement.bottom(), rY)) {
|
||||||
|
geometry.result = {false, QStringLiteral("No valid position inside the editing extent.")};
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
geometry.ptFirstTikzPosition += QPointF(rX, rY);
|
||||||
|
geometry.ptSecondTikzPosition += QPointF(rX, rY);
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
geometry.result = {false, QStringLiteral("Unsupported edit handle.")};
|
||||||
|
return geometry;
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrEditService::prepareEdits(const ElementRecord &element, const QByteArray &baSource,
|
||||||
|
const GestureGeometry &geometry,
|
||||||
|
QVector<CoordinateEdit> &vecEdits) const
|
||||||
|
{
|
||||||
|
vecEdits.clear();
|
||||||
|
if (!geometry.result.bSucceeded) return geometry.result;
|
||||||
|
const SourceRange ranges[] = {element.rangeFirstX, element.rangeFirstY,
|
||||||
|
element.rangeSecondX, element.rangeSecondY};
|
||||||
|
const QPointF offsets[] = {geometry.ptFirstTikzPosition - element.ptFirstTikzPosition,
|
||||||
|
geometry.ptSecondTikzPosition - element.ptSecondTikzPosition};
|
||||||
|
constexpr int iCoordinatesPerPoint = 2;
|
||||||
|
constexpr int iCoordinateCount = 4;
|
||||||
|
for (int iCoordinate = 0; iCoordinate < iCoordinateCount; ++iCoordinate) {
|
||||||
|
const QPointF &offset = offsets[iCoordinate / iCoordinatesPerPoint];
|
||||||
|
const qreal rDelta = iCoordinate % iCoordinatesPerPoint == 0 ? offset.x() : offset.y();
|
||||||
|
const QByteArray baDelta = QByteArray::number(rDelta, 'f', Limits::iCoordinateDecimals);
|
||||||
|
if (baDelta.toDouble() == 0) continue;
|
||||||
|
const SourceRange &range = ranges[iCoordinate];
|
||||||
|
const QByteArray baOriginal = baSource.mid(range.nStart, range.nLength);
|
||||||
|
QByteArray baReplacement;
|
||||||
|
if (!translateCoordinate(baOriginal, baDelta, baReplacement)) {
|
||||||
|
vecEdits.clear();
|
||||||
|
return {false, QStringLiteral("A coordinate cannot be changed safely.")};
|
||||||
|
}
|
||||||
|
vecEdits.append({range, baOriginal, baReplacement, element.uDocumentRevision});
|
||||||
|
}
|
||||||
|
return {true, {}};
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "model/EditorTypes.h"
|
||||||
|
#include "geometry/tkrCoordinateMapper.h"
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
class tkrShapeProvider;
|
||||||
|
|
||||||
|
// Prepares geometry and source replacements. Never mutates a document or widget.
|
||||||
|
class tkrEditService final
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
GestureGeometry prepareGeometry(const ElementRecord &element, const DragUpdate &drag,
|
||||||
|
const tkrCoordinateMapper &mapper,
|
||||||
|
const ComparisonExtent &extent,
|
||||||
|
const tkrShapeProvider *pShapeProvider = nullptr) const;
|
||||||
|
OperationResult prepareEdits(const ElementRecord &element, const QByteArray &baSource,
|
||||||
|
const GestureGeometry &geometry,
|
||||||
|
QVector<CoordinateEdit> &vecEdits) const;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "model/EditorTypes.h"
|
||||||
|
#include "ShapeTypes.h"
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
// Shared with parsing: gesture bounds must include the same ink envelope.
|
||||||
|
struct ShapeGeometryLimits
|
||||||
|
{
|
||||||
|
static constexpr qreal rMinimumRectangleCentimeters = ShapeApi::rMinimumRectangleCentimeters;
|
||||||
|
static constexpr int iCoordinateDecimals = ShapeApi::iCoordinateDecimals;
|
||||||
|
static constexpr qreal rCoordinateStepsPerCentimeter = ShapeApi::rCoordinateStepsPerCentimeter;
|
||||||
|
static constexpr qreal rCentimetersPerInch = 2.54;
|
||||||
|
static constexpr qreal rTexPointsPerInch = 72.27;
|
||||||
|
static constexpr qreal rHalfStroke = 0.5;
|
||||||
|
static constexpr qreal rArrowTipBasePoints = 0.28;
|
||||||
|
static constexpr qreal rArrowTipWidthFactor = 0.3;
|
||||||
|
static constexpr qreal rArrowTipSpanFactor = 4.0;
|
||||||
|
static constexpr qreal rArrowStrokeFactor = 0.4;
|
||||||
|
};
|
||||||
|
|
||||||
|
inline qreal outlineMarginCentimeters(const ElementRecord &element)
|
||||||
|
{
|
||||||
|
using Limits = ShapeGeometryLimits;
|
||||||
|
const qreal rEnvelopePoints = element.elementKind == ElementKind::Arrow
|
||||||
|
? Limits::rArrowTipSpanFactor * (Limits::rArrowTipBasePoints
|
||||||
|
+ Limits::rArrowTipWidthFactor * element.rLineWidthPoints)
|
||||||
|
+ Limits::rArrowStrokeFactor * element.rLineWidthPoints
|
||||||
|
: Limits::rHalfStroke * element.rLineWidthPoints;
|
||||||
|
return rEnvelopePoints * Limits::rCentimetersPerInch / Limits::rTexPointsPerInch;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
#include "geometry/tkrCoordinateMapper.h"
|
||||||
|
|
||||||
|
#include <cmath>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
OperationResult tkrCoordinateMapper::configure(const QPointF &ptSceneOrigin,
|
||||||
|
qreal rSceneUnitsPerCentimeter)
|
||||||
|
{
|
||||||
|
if (!std::isfinite(ptSceneOrigin.x()) || !std::isfinite(ptSceneOrigin.y())
|
||||||
|
|| !std::isfinite(rSceneUnitsPerCentimeter) || rSceneUnitsPerCentimeter <= 0.0) {
|
||||||
|
return {false, QStringLiteral("Coordinate mapping needs a finite origin and positive scale.")};
|
||||||
|
}
|
||||||
|
m_ptSceneOrigin = ptSceneOrigin;
|
||||||
|
m_rSceneUnitsPerCentimeter = rSceneUnitsPerCentimeter;
|
||||||
|
return {true, {}};
|
||||||
|
}
|
||||||
|
|
||||||
|
QPointF tkrCoordinateMapper::mapToScene(const QPointF &ptTikzPosition) const
|
||||||
|
{
|
||||||
|
return QPointF(m_ptSceneOrigin.x() + m_rSceneUnitsPerCentimeter * ptTikzPosition.x(),
|
||||||
|
m_ptSceneOrigin.y() - m_rSceneUnitsPerCentimeter * ptTikzPosition.y());
|
||||||
|
}
|
||||||
|
|
||||||
|
QPointF tkrCoordinateMapper::mapToTikz(const QPointF &ptScenePosition) const
|
||||||
|
{
|
||||||
|
return QPointF((ptScenePosition.x() - m_ptSceneOrigin.x()) / m_rSceneUnitsPerCentimeter,
|
||||||
|
(m_ptSceneOrigin.y() - ptScenePosition.y()) / m_rSceneUnitsPerCentimeter);
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "model/EditorTypes.h"
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
// Scene units are independent of viewport pixels, zoom and pan.
|
||||||
|
class tkrCoordinateMapper final
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
OperationResult configure(const QPointF &ptSceneOrigin, qreal rSceneUnitsPerCentimeter);
|
||||||
|
QPointF mapToScene(const QPointF &ptTikzPosition) const;
|
||||||
|
QPointF mapToTikz(const QPointF &ptScenePosition) const;
|
||||||
|
|
||||||
|
private:
|
||||||
|
QPointF m_ptSceneOrigin = QPointF(200.0, 300.0);
|
||||||
|
qreal m_rSceneUnitsPerCentimeter = 100.0;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
#include "ui/tkrMainWindow.h"
|
||||||
|
#include "BuildInfo.h"
|
||||||
|
|
||||||
|
#include <QApplication>
|
||||||
|
#include <QCoreApplication>
|
||||||
|
#include <QString>
|
||||||
|
|
||||||
|
int main(int iArgumentCount, char *pArguments[])
|
||||||
|
{
|
||||||
|
QApplication application(iArgumentCount, pArguments);
|
||||||
|
QCoreApplication::setApplicationName(QStringLiteral("TikZRefinery"));
|
||||||
|
QCoreApplication::setApplicationVersion(QString::fromLatin1(TikzRefinery::BuildInfo::pVersion));
|
||||||
|
QCoreApplication::setOrganizationName(QStringLiteral("TikZRefinery"));
|
||||||
|
QApplication::setQuitOnLastWindowClosed(true);
|
||||||
|
TikzRefinery::tkrMainWindow mainWindow(nullptr, application.arguments().value(1));
|
||||||
|
mainWindow.show();
|
||||||
|
return application.exec();
|
||||||
|
}
|
||||||
@@ -0,0 +1,92 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <QByteArray>
|
||||||
|
#include <QMetaType>
|
||||||
|
#include <QPointF>
|
||||||
|
#include <QString>
|
||||||
|
#include <QStringList>
|
||||||
|
#include <QVector>
|
||||||
|
#include <QUuid>
|
||||||
|
#include <QtGlobal>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
enum class ElementKind { Line, Arrow, Rectangle };
|
||||||
|
enum class DragKind {
|
||||||
|
WholeElement, FirstEndpoint, SecondEndpoint,
|
||||||
|
RectangleFirstFirst, RectangleFirstSecond, RectangleSecondFirst, RectangleSecondSecond
|
||||||
|
};
|
||||||
|
|
||||||
|
// Byte offsets into the document's original/current QByteArray, never QString indices.
|
||||||
|
struct SourceRange
|
||||||
|
{
|
||||||
|
qsizetype nStart = 0;
|
||||||
|
qsizetype nLength = 0;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct ElementRecord
|
||||||
|
{
|
||||||
|
quint64 uElementId = 0; // Valid only within uDocumentRevision.
|
||||||
|
quint64 uDocumentRevision = 0;
|
||||||
|
ElementKind elementKind = ElementKind::Line;
|
||||||
|
QPointF ptFirstTikzPosition;
|
||||||
|
QPointF ptSecondTikzPosition;
|
||||||
|
SourceRange rangeFirstX;
|
||||||
|
SourceRange rangeFirstY;
|
||||||
|
SourceRange rangeSecondX;
|
||||||
|
SourceRange rangeSecondY;
|
||||||
|
bool bArrowAtStart = false;
|
||||||
|
bool bArrowAtEnd = false;
|
||||||
|
qreal rLineWidthPoints = 0.4;
|
||||||
|
QUuid documentId; // Assigned by the document, outside the syntax parser.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Calibration data only; never assigned an element ID or coordinate edit ranges.
|
||||||
|
struct ComparisonExtent
|
||||||
|
{
|
||||||
|
bool bIsPresent = false;
|
||||||
|
QPointF ptFirstTikzPosition;
|
||||||
|
QPointF ptSecondTikzPosition;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct ParseResult
|
||||||
|
{
|
||||||
|
bool bSafeToEdit = false;
|
||||||
|
QVector<ElementRecord> vecElements;
|
||||||
|
ComparisonExtent comparisonExtent;
|
||||||
|
QStringList listDiagnostics;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct DragUpdate
|
||||||
|
{
|
||||||
|
quint64 uElementId = 0;
|
||||||
|
quint64 uDocumentRevision = 0;
|
||||||
|
DragKind dragKind = DragKind::WholeElement;
|
||||||
|
QPointF ptInitialScenePosition;
|
||||||
|
QPointF ptCurrentScenePosition;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct CoordinateEdit
|
||||||
|
{
|
||||||
|
SourceRange rangeSource;
|
||||||
|
QByteArray baExpectedText;
|
||||||
|
QByteArray baReplacementText;
|
||||||
|
quint64 uDocumentRevision = 0;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct OperationResult
|
||||||
|
{
|
||||||
|
bool bSucceeded = false;
|
||||||
|
QString strMessage;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct GestureGeometry
|
||||||
|
{
|
||||||
|
OperationResult result;
|
||||||
|
QPointF ptFirstTikzPosition;
|
||||||
|
QPointF ptSecondTikzPosition;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
|
|
||||||
|
Q_DECLARE_METATYPE(TikzRefinery::DragUpdate)
|
||||||
@@ -0,0 +1,136 @@
|
|||||||
|
#include "model/tkrTikzDocument.h"
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
|
#include <new>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
void tkrTikzDocument::loadSource(const QByteArray &baSource, const QString &strFilePath)
|
||||||
|
{
|
||||||
|
m_baSource = baSource;
|
||||||
|
m_baSavedSource = baSource;
|
||||||
|
m_strFilePath = strFilePath;
|
||||||
|
QVector<ElementRecord>().swap(m_vecElements);
|
||||||
|
m_history.clear();
|
||||||
|
m_documentId = QUuid::createUuid();
|
||||||
|
++m_uRevision; // Opening another file also invalidates old edits.
|
||||||
|
m_bIsLoaded = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
const QByteArray &tkrTikzDocument::sourceBytes() const { return m_baSource; }
|
||||||
|
const QString &tkrTikzDocument::filePath() const { return m_strFilePath; }
|
||||||
|
const QVector<ElementRecord> &tkrTikzDocument::elements() const { return m_vecElements; }
|
||||||
|
quint64 tkrTikzDocument::revision() const { return m_uRevision; }
|
||||||
|
const QUuid &tkrTikzDocument::identity() const { return m_documentId; }
|
||||||
|
bool tkrTikzDocument::isLoaded() const { return m_bIsLoaded; }
|
||||||
|
bool tkrTikzDocument::hasUnsavedChanges() const { return m_baSource != m_baSavedSource; }
|
||||||
|
void tkrTikzDocument::markSaved() { m_baSavedSource = m_baSource; }
|
||||||
|
|
||||||
|
OperationResult tkrTikzDocument::setParsedElements(const QVector<ElementRecord> &vecElements,
|
||||||
|
quint64 uExpectedRevision)
|
||||||
|
{
|
||||||
|
if (!m_bIsLoaded || uExpectedRevision != m_uRevision) {
|
||||||
|
return {false, QStringLiteral("Parsed elements belong to an outdated document.")};
|
||||||
|
}
|
||||||
|
for (const ElementRecord &elementRecord : vecElements) {
|
||||||
|
if (elementRecord.uDocumentRevision != m_uRevision) {
|
||||||
|
return {false, QStringLiteral("An element belongs to an outdated document.")};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
m_vecElements = vecElements;
|
||||||
|
for (ElementRecord &element : m_vecElements) element.documentId = m_documentId;
|
||||||
|
return {true, {}};
|
||||||
|
}
|
||||||
|
|
||||||
|
OperationResult tkrTikzDocument::applyCoordinateEdits(const QVector<CoordinateEdit> &vecEdits,
|
||||||
|
const QString &strDescription) try
|
||||||
|
{
|
||||||
|
if (!m_bIsLoaded) {
|
||||||
|
return {false, QStringLiteral("No document is open.")};
|
||||||
|
}
|
||||||
|
QVector<CoordinateEdit> vecSortedEdits = vecEdits;
|
||||||
|
std::sort(vecSortedEdits.begin(), vecSortedEdits.end(),
|
||||||
|
[](const CoordinateEdit &editLeft, const CoordinateEdit &editRight) {
|
||||||
|
return editLeft.rangeSource.nStart < editRight.rangeSource.nStart;
|
||||||
|
});
|
||||||
|
|
||||||
|
qsizetype nPreviousEnd = 0;
|
||||||
|
for (const CoordinateEdit &coordinateEdit : vecSortedEdits) {
|
||||||
|
const SourceRange &rangeSource = coordinateEdit.rangeSource;
|
||||||
|
if (coordinateEdit.uDocumentRevision != m_uRevision) {
|
||||||
|
return {false, QStringLiteral("The document changed after this edit was prepared.")};
|
||||||
|
}
|
||||||
|
// Subtract only after validating the start, avoiding integer overflow.
|
||||||
|
if (rangeSource.nStart < 0 || rangeSource.nLength <= 0
|
||||||
|
|| rangeSource.nStart > m_baSource.size()
|
||||||
|
|| rangeSource.nLength > m_baSource.size() - rangeSource.nStart) {
|
||||||
|
return {false, QStringLiteral("A coordinate source range is invalid.")};
|
||||||
|
}
|
||||||
|
if (rangeSource.nStart < nPreviousEnd) {
|
||||||
|
return {false, QStringLiteral("Coordinate replacement ranges overlap.")};
|
||||||
|
}
|
||||||
|
if (m_baSource.mid(rangeSource.nStart, rangeSource.nLength)
|
||||||
|
!= coordinateEdit.baExpectedText) {
|
||||||
|
return {false, QStringLiteral("The expected coordinate text no longer matches.")};
|
||||||
|
}
|
||||||
|
nPreviousEnd = rangeSource.nStart + rangeSource.nLength;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Validate the complete batch first, then replace backwards to preserve offsets.
|
||||||
|
QByteArray baUpdatedSource = m_baSource;
|
||||||
|
for (auto iterEdit = vecSortedEdits.crbegin(); iterEdit != vecSortedEdits.crend(); ++iterEdit) {
|
||||||
|
baUpdatedSource.replace(iterEdit->rangeSource.nStart, iterEdit->rangeSource.nLength,
|
||||||
|
iterEdit->baReplacementText);
|
||||||
|
}
|
||||||
|
if (baUpdatedSource != m_baSource) {
|
||||||
|
m_history.record(m_baSource, baUpdatedSource, strDescription);
|
||||||
|
// From here, publication consists only of non-allocating changes.
|
||||||
|
m_baSource.swap(baUpdatedSource);
|
||||||
|
// Qt clear() may allocate on a shared container; an empty swap cannot.
|
||||||
|
QVector<ElementRecord>().swap(m_vecElements); // Reparse before another edit.
|
||||||
|
++m_uRevision;
|
||||||
|
}
|
||||||
|
return {true, {}};
|
||||||
|
}
|
||||||
|
catch (const std::bad_alloc &)
|
||||||
|
{
|
||||||
|
return {false, QStringLiteral("Insufficient memory to record this edit. Source unchanged.")};
|
||||||
|
}
|
||||||
|
|
||||||
|
bool tkrTikzDocument::canUndo() const { return m_history.canUndo(); }
|
||||||
|
OperationResult tkrTikzDocument::acceptPreparedState(tkrTikzDocument &documentCandidate,
|
||||||
|
quint64 uExpectedRevision)
|
||||||
|
{
|
||||||
|
constexpr quint64 uRevisionStep = 1;
|
||||||
|
if (m_uRevision != uExpectedRevision || documentCandidate.m_documentId != m_documentId
|
||||||
|
|| documentCandidate.m_uRevision != m_uRevision + uRevisionStep) {
|
||||||
|
return {false, QStringLiteral("The document changed during preparation.")};
|
||||||
|
}
|
||||||
|
// Source, parsed records and history were all prepared before publication.
|
||||||
|
m_baSource.swap(documentCandidate.m_baSource);
|
||||||
|
m_vecElements.swap(documentCandidate.m_vecElements);
|
||||||
|
m_history.swap(documentCandidate.m_history);
|
||||||
|
m_uRevision = documentCandidate.m_uRevision;
|
||||||
|
return {true, {}};
|
||||||
|
}
|
||||||
|
bool tkrTikzDocument::canRedo() const { return m_history.canRedo(); }
|
||||||
|
QString tkrTikzDocument::undoDescription() const { return m_history.undoDescription(); }
|
||||||
|
QString tkrTikzDocument::redoDescription() const { return m_history.redoDescription(); }
|
||||||
|
OperationResult tkrTikzDocument::restoreHistory(bool bRedo) try
|
||||||
|
{
|
||||||
|
if (bRedo ? !canRedo() : !canUndo()) {
|
||||||
|
return {false, QStringLiteral("No history entry is available.")};
|
||||||
|
}
|
||||||
|
QByteArray baRestored = m_history.restorationSource(bRedo);
|
||||||
|
m_baSource.swap(baRestored);
|
||||||
|
m_history.advance(bRedo);
|
||||||
|
QVector<ElementRecord>().swap(m_vecElements);
|
||||||
|
++m_uRevision; // Revisions are fresh even when earlier bytes return.
|
||||||
|
return {true, {}};
|
||||||
|
}
|
||||||
|
catch (const std::bad_alloc &)
|
||||||
|
{
|
||||||
|
return {false, QStringLiteral("Insufficient memory to restore history. Source unchanged.")};
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,45 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "model/EditorTypes.h"
|
||||||
|
#include "editing/tkrEditHistory.h"
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
|
||||||
|
// Owns source bytes and parsed data. No widgets, filesystem access, or compiler.
|
||||||
|
class tkrTikzDocument final
|
||||||
|
{
|
||||||
|
friend class tkrEditorController;
|
||||||
|
public:
|
||||||
|
void loadSource(const QByteArray &baSource, const QString &strFilePath);
|
||||||
|
const QByteArray &sourceBytes() const;
|
||||||
|
const QString &filePath() const;
|
||||||
|
const QVector<ElementRecord> &elements() const;
|
||||||
|
quint64 revision() const;
|
||||||
|
const QUuid &identity() const;
|
||||||
|
bool isLoaded() const;
|
||||||
|
bool hasUnsavedChanges() const;
|
||||||
|
void markSaved();
|
||||||
|
|
||||||
|
OperationResult setParsedElements(const QVector<ElementRecord> &vecElements,
|
||||||
|
quint64 uExpectedRevision);
|
||||||
|
OperationResult applyCoordinateEdits(const QVector<CoordinateEdit> &vecEdits,
|
||||||
|
const QString &strDescription = QStringLiteral("Edit coordinates"));
|
||||||
|
bool canUndo() const;
|
||||||
|
bool canRedo() const;
|
||||||
|
QString undoDescription() const;
|
||||||
|
QString redoDescription() const;
|
||||||
|
OperationResult restoreHistory(bool bRedo);
|
||||||
|
|
||||||
|
private:
|
||||||
|
OperationResult acceptPreparedState(tkrTikzDocument &documentCandidate, quint64 uExpectedRevision);
|
||||||
|
QByteArray m_baSource;
|
||||||
|
QByteArray m_baSavedSource;
|
||||||
|
QString m_strFilePath;
|
||||||
|
QVector<ElementRecord> m_vecElements;
|
||||||
|
quint64 m_uRevision = 0;
|
||||||
|
bool m_bIsLoaded = false;
|
||||||
|
QUuid m_documentId;
|
||||||
|
tkrEditHistory m_history;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
@@ -0,0 +1,215 @@
|
|||||||
|
#include "geometry/ShapeGeometryLimits.h"
|
||||||
|
#include "parsing/tkrTikzParserExplicit.h"
|
||||||
|
|
||||||
|
#include <QRegularExpression>
|
||||||
|
#include <QRectF>
|
||||||
|
#include <cmath>
|
||||||
|
|
||||||
|
namespace TikzRefinery {
|
||||||
|
namespace {
|
||||||
|
|
||||||
|
ParseResult rejectSource(const QString &strReason, qsizetype nByteOffset = 0)
|
||||||
|
{
|
||||||
|
ParseResult parseResult;
|
||||||
|
parseResult.listDiagnostics.append(
|
||||||
|
QStringLiteral("Diagram display unavailable at byte %1: %2 Source was preserved.")
|
||||||
|
.arg(nByteOffset).arg(strReason));
|
||||||
|
return parseResult; // Never return a misleading partial diagram.
|
||||||
|
}
|
||||||
|
|
||||||
|
bool parseAppearance(const QString &strOptions, qreal &rLineWidthPoints,
|
||||||
|
bool &bArrowAtStart, bool &bArrowAtEnd)
|
||||||
|
{
|
||||||
|
if (strOptions.isNull()) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
// No style lookup, transformations, fills, or executable TeX options.
|
||||||
|
const QRegularExpression expressionWidth(
|
||||||
|
QStringLiteral(R"(^line\s+width\s*=\s*((?:[0-9]+(?:\.[0-9]*)?|\.[0-9]+))\s*pt$)"));
|
||||||
|
bool bWidthSeen = false;
|
||||||
|
bool bArrowSeen = false;
|
||||||
|
const QStringList listOptions = strOptions.split(QLatin1Char(','));
|
||||||
|
for (const QString &strOption : listOptions) {
|
||||||
|
const QString strTrimmed = strOption.trimmed();
|
||||||
|
if (strTrimmed == QStringLiteral("black") || strTrimmed == QStringLiteral("solid")) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (strTrimmed == QStringLiteral("->") || strTrimmed == QStringLiteral("<-")
|
||||||
|
|| strTrimmed == QStringLiteral("<->")) {
|
||||||
|
if (bArrowSeen) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
bArrowAtStart = strTrimmed.startsWith(QLatin1Char('<'));
|
||||||
|
bArrowAtEnd = strTrimmed.endsWith(QLatin1Char('>'));
|
||||||
|
bArrowSeen = true;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
const QRegularExpressionMatch matchWidth = expressionWidth.match(strTrimmed);
|
||||||
|
if (!matchWidth.hasMatch() || bWidthSeen) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
bool bConverted = false;
|
||||||
|
rLineWidthPoints = matchWidth.captured(1).toDouble(&bConverted);
|
||||||
|
if (!bConverted || !std::isfinite(rLineWidthPoints) || rLineWidthPoints <= 0.0) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
bWidthSeen = true;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace
|
||||||
|
|
||||||
|
ParseResult tkrTikzParserExplicit::parse(const QByteArray &baSource,
|
||||||
|
quint64 uDocumentRevision) const
|
||||||
|
{
|
||||||
|
// One Latin-1 code unit per byte, including UTF-8 comments. Mask rather than
|
||||||
|
// delete comments so regex captures remain offsets in the original QByteArray.
|
||||||
|
QByteArray baMasked = baSource;
|
||||||
|
if (baMasked.startsWith(QByteArray::fromHex("efbbbf"))) {
|
||||||
|
baMasked.replace(0, 3, " ");
|
||||||
|
}
|
||||||
|
bool bInComment = false;
|
||||||
|
for (qsizetype nByte = 0; nByte < baMasked.size(); ++nByte) {
|
||||||
|
const char chByte = baMasked.at(nByte);
|
||||||
|
if (chByte == '\r' || chByte == '\n') {
|
||||||
|
bInComment = false;
|
||||||
|
} else if (bInComment || chByte == '%') {
|
||||||
|
// Escaped percent is deliberately unsupported by the grammar below.
|
||||||
|
bInComment = true;
|
||||||
|
baMasked[nByte] = ' ';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const QString strSource = QString::fromLatin1(baMasked);
|
||||||
|
for (qsizetype nByte = 0; nByte < baMasked.size(); ++nByte) {
|
||||||
|
const unsigned char chByte = static_cast<unsigned char>(baMasked.at(nByte));
|
||||||
|
if ((chByte < 32 && chByte != '\t' && chByte != '\r' && chByte != '\n') || chByte > 126) {
|
||||||
|
return rejectSource(QStringLiteral("unsupported non-ASCII source outside comments."), nByte);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
QString strBody = strSource;
|
||||||
|
qsizetype nBodyOffset = 0;
|
||||||
|
// Recognize the corpus wrapper as a whole. Never search for draw commands
|
||||||
|
// inside arbitrary TeX (macros, loops, scopes, or altered catcodes/units).
|
||||||
|
const QRegularExpression expressionDocument(QStringLiteral(
|
||||||
|
R"(\A\s*\\documentclass\s*\{article\}\s*\\usepackage\s*\{tikz\}\s*\\pagestyle\s*\{empty\}\s*\\begin\s*\{document\}\s*(?:\\noindent\s*)?\\begin\s*\{tikzpicture\}([\s\S]*)\\end\s*\{tikzpicture\}\s*\\end\s*\{document\}\s*\z)"));
|
||||||
|
const QRegularExpression expressionPicture(QStringLiteral(
|
||||||
|
R"(\A\s*\\begin\s*\{tikzpicture\}([\s\S]*)\\end\s*\{tikzpicture\}\s*\z)"));
|
||||||
|
QRegularExpressionMatch matchEnvelope = expressionDocument.match(strSource);
|
||||||
|
if (!matchEnvelope.hasMatch()) {
|
||||||
|
matchEnvelope = expressionPicture.match(strSource);
|
||||||
|
}
|
||||||
|
if (matchEnvelope.hasMatch()) {
|
||||||
|
strBody = matchEnvelope.captured(1);
|
||||||
|
nBodyOffset = matchEnvelope.capturedStart(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
const QString strNumber = QStringLiteral(R"(([+-]?(?:[0-9]+(?:\.[0-9]*)?|\.[0-9]+)))");
|
||||||
|
const QString strPoint = QStringLiteral(R"(\(\s*)") + strNumber
|
||||||
|
+ QStringLiteral(R"(\s*cm\s*,\s*)") + strNumber + QStringLiteral(R"(\s*cm\s*\))");
|
||||||
|
const QString strCorners = strPoint + QStringLiteral(R"(\s*(rectangle|--)\s*)")
|
||||||
|
+ strPoint + QStringLiteral(R"(\s*;)");
|
||||||
|
const QRegularExpression expressionDraw(
|
||||||
|
QStringLiteral(R"(\\draw\s*(?:\[([^\[\]]*)\]\s*)?)") + strCorners);
|
||||||
|
const QRegularExpression expressionExtent(
|
||||||
|
QStringLiteral(R"(\\path\s*\[\s*use\s+as\s+bounding\s+box\s*\]\s*)")
|
||||||
|
+ strPoint + QStringLiteral(R"(\s*rectangle\s*)") + strPoint + QStringLiteral(R"(\s*;)"));
|
||||||
|
|
||||||
|
ParseResult parseResult;
|
||||||
|
qsizetype nPosition = 0;
|
||||||
|
while (nPosition < strBody.size()) {
|
||||||
|
const QChar chCurrent = strBody.at(nPosition);
|
||||||
|
if (chCurrent == QLatin1Char(' ') || chCurrent == QLatin1Char('\t')
|
||||||
|
|| chCurrent == QLatin1Char('\r') || chCurrent == QLatin1Char('\n')) {
|
||||||
|
++nPosition;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
const QRegularExpressionMatch matchDraw = expressionDraw.match(
|
||||||
|
strBody, nPosition, QRegularExpression::NormalMatch,
|
||||||
|
QRegularExpression::AnchorAtOffsetMatchOption);
|
||||||
|
const bool bIsDraw = matchDraw.hasMatch();
|
||||||
|
const QRegularExpressionMatch matchCommand = bIsDraw ? matchDraw : expressionExtent.match(
|
||||||
|
strBody, nPosition, QRegularExpression::NormalMatch,
|
||||||
|
QRegularExpression::AnchorAtOffsetMatchOption);
|
||||||
|
if (!matchCommand.hasMatch()) {
|
||||||
|
return rejectSource(QStringLiteral("unsupported syntax or wrapper; expected an absolute cm rectangle or straight segment."),
|
||||||
|
nBodyOffset + nPosition);
|
||||||
|
}
|
||||||
|
qreal rLineWidthPoints = 0.4;
|
||||||
|
bool bArrowAtStart = false;
|
||||||
|
bool bArrowAtEnd = false;
|
||||||
|
if (bIsDraw && !parseAppearance(matchCommand.captured(1), rLineWidthPoints,
|
||||||
|
bArrowAtStart, bArrowAtEnd)) {
|
||||||
|
return rejectSource(QStringLiteral("unsupported appearance options."), nBodyOffset + nPosition);
|
||||||
|
}
|
||||||
|
const bool bIsRectangle = !bIsDraw || matchCommand.captured(4) == QStringLiteral("rectangle");
|
||||||
|
const int iFirstCoordinate = bIsDraw ? 2 : 1;
|
||||||
|
qreal rCoordinates[4];
|
||||||
|
SourceRange rangesCoordinates[4];
|
||||||
|
for (int iCoordinate = 0; iCoordinate < 4; ++iCoordinate) {
|
||||||
|
const int iCapture = iFirstCoordinate + iCoordinate + (bIsDraw && iCoordinate >= 2 ? 1 : 0);
|
||||||
|
bool bConverted = false;
|
||||||
|
rCoordinates[iCoordinate] = matchCommand.captured(iCapture).toDouble(&bConverted);
|
||||||
|
if (!bConverted || !std::isfinite(rCoordinates[iCoordinate])) {
|
||||||
|
return rejectSource(QStringLiteral("coordinate is not finite."), nBodyOffset + nPosition);
|
||||||
|
}
|
||||||
|
rangesCoordinates[iCoordinate] = {nBodyOffset + matchCommand.capturedStart(iCapture),
|
||||||
|
matchCommand.capturedLength(iCapture)};
|
||||||
|
}
|
||||||
|
const QPointF ptFirst(rCoordinates[0], rCoordinates[1]);
|
||||||
|
const QPointF ptSecond(rCoordinates[2], rCoordinates[3]);
|
||||||
|
if ((bIsRectangle && (ptFirst.x() == ptSecond.x() || ptFirst.y() == ptSecond.y()))
|
||||||
|
|| (!bIsRectangle && ptFirst == ptSecond)) {
|
||||||
|
return rejectSource(QStringLiteral("degenerate geometry."), nBodyOffset + nPosition);
|
||||||
|
}
|
||||||
|
if (bIsRectangle && (bArrowAtStart || bArrowAtEnd)) {
|
||||||
|
return rejectSource(QStringLiteral("arrow options require a straight segment."), nBodyOffset + nPosition);
|
||||||
|
}
|
||||||
|
if (bIsDraw) {
|
||||||
|
ElementRecord elementRecord;
|
||||||
|
elementRecord.uElementId = static_cast<quint64>(parseResult.vecElements.size()) + 1;
|
||||||
|
elementRecord.uDocumentRevision = uDocumentRevision;
|
||||||
|
elementRecord.elementKind = bIsRectangle ? ElementKind::Rectangle
|
||||||
|
: (bArrowAtStart || bArrowAtEnd ? ElementKind::Arrow : ElementKind::Line);
|
||||||
|
elementRecord.bArrowAtStart = bArrowAtStart;
|
||||||
|
elementRecord.bArrowAtEnd = bArrowAtEnd;
|
||||||
|
elementRecord.ptFirstTikzPosition = ptFirst;
|
||||||
|
elementRecord.ptSecondTikzPosition = ptSecond;
|
||||||
|
elementRecord.rangeFirstX = rangesCoordinates[0];
|
||||||
|
elementRecord.rangeFirstY = rangesCoordinates[1];
|
||||||
|
elementRecord.rangeSecondX = rangesCoordinates[2];
|
||||||
|
elementRecord.rangeSecondY = rangesCoordinates[3];
|
||||||
|
elementRecord.rLineWidthPoints = rLineWidthPoints;
|
||||||
|
parseResult.vecElements.append(elementRecord);
|
||||||
|
} else {
|
||||||
|
if (parseResult.comparisonExtent.bIsPresent || !parseResult.vecElements.isEmpty()) {
|
||||||
|
return rejectSource(QStringLiteral("comparison extent must occur once, before drawing."),
|
||||||
|
nBodyOffset + nPosition);
|
||||||
|
}
|
||||||
|
parseResult.comparisonExtent = {true, ptFirst, ptSecond};
|
||||||
|
}
|
||||||
|
nPosition = matchCommand.capturedEnd();
|
||||||
|
}
|
||||||
|
if (parseResult.vecElements.isEmpty()) {
|
||||||
|
return rejectSource(QStringLiteral("no supported drawing elements found."));
|
||||||
|
}
|
||||||
|
if (parseResult.comparisonExtent.bIsPresent) {
|
||||||
|
const QRectF rectExtent = QRectF(parseResult.comparisonExtent.ptFirstTikzPosition,
|
||||||
|
parseResult.comparisonExtent.ptSecondTikzPosition).normalized();
|
||||||
|
for (const ElementRecord &elementRecord : parseResult.vecElements) {
|
||||||
|
// A conservative envelope also includes the default curved 'to' tip.
|
||||||
|
const qreal rHalfStrokeCentimeters = outlineMarginCentimeters(elementRecord);
|
||||||
|
const QRectF rectOutline = QRectF(elementRecord.ptFirstTikzPosition,
|
||||||
|
elementRecord.ptSecondTikzPosition).normalized()
|
||||||
|
.adjusted(-rHalfStrokeCentimeters, -rHalfStrokeCentimeters,
|
||||||
|
rHalfStrokeCentimeters, rHalfStrokeCentimeters);
|
||||||
|
if (!rectExtent.contains(rectOutline)) {
|
||||||
|
return rejectSource(QStringLiteral("drawing exceeds the fixed comparison extent."));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
parseResult.bSafeToEdit = true; // Safe source records; gestures are still unavailable.
|
||||||
|
return parseResult;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace TikzRefinery
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user