سامانه صدور فاکتور و حسابداری
qa/attachment-allocator-two-session-20261122
Finora Phase 0 — Acceptance register and first verified checkpoint
Date: 2026-10-12 · Accountable lead: QA / Validation · Authority: Owner: «تایید فاز رو استارت بزن» Approval state: ACCEPTANCE STARTED / PHASE 0 OPEN / NOT OWNER-ACCEPTED. Scope: approved eight-phase roadmap, Phase 0 F0-01–F0-08. This document does not accept Phase 0 or authorize security/finance writes.
1. Live pinned baseline
- Canonical repository:
davoodmehraban89/Factor-easy; protected pre-checkpointmain=601a5b7b066ce4cf7e68fad2abe642c3e846cdd3. - Same-SHA GitHub Quality 38203575835, Security 38203575840, Release gate 38203689209, gated Pages 38203706432: all SUCCESS; cancelled/skipped duplicate runs excluded.
- Re-read real Quality static job
114662032710: 55 JS/52 MJS syntax passed; financial/Golden invariants passed; 83/83 Playwright Chromium passed (55.7s), including F0-03 invoice mock-server persistence, F0-05 1,208-product and 1,206-contact synthetic fixture. Three disposable DB jobs succeeded. These are not customer production E2E evidence. - Remote authorized device
DESKTOP-71SJ63M: read-only PowerShellInvoke-WebRequesttohttps://factoreasy.ir/?phase0_acceptance=20261012returned HTTP 200. No session, login, tenant data, JS version identity, save, or printing was verified by this HTTP-only check. Separate read-only HTTP GETs returned 200 forjs/login-connectivity.js,js/ux-hardening-r2.jsandjs/print.json the same device. This checks asset reachability only; it does not verify cache-version identity, authenticated operations or actual print output. - Live Supabase project
hcsixhqbyuhpshfwqpjxACTIVE_HEALTHY; 81 migrations; newest20261011174445 posted_source_idempotency_index. Read-only advisor counts: 21 authenticated SECURITY DEFINER function warnings, 3 private-table RLS-no-policy informational findings, 1 leaked-password-protection warning. These are review inputs, not 25 proven vulnerabilities. - Reconciliation risk: live migration
20261007165208 phone_identity_profileis present on production but its archive filesupabase/migrations/20261007163500_phone_identity_profile.sqlis absent from current main, and exists in stale open PR #58. Treat as migration/source drift for supervised analysis in Phase 1; do not rerun or cherry-pick that migration automatically.
2. Acceptance gate matrix
Status definitions: CONTROLLED QA PASS = actual Chromium or isolated tests with synthetic/mock data; VERIFIED READ-ONLY = live read-only metadata/HTTP observation; UNVERIFIED = required authentication/real tenant/printer scope not tested. No check becomes OWNER-ACCEPTED without direct evidence and explicit owner decision.
| ID | Priority | Current evidence | Acceptance status | Required next proof / owner |
|---|---|---|---|---|
| F0-01 · Login/affected ISP | 2026-10-13 owner result: first Chrome computer sign-in PASS ~20s after hard refresh; second computer FAIL ~40s. Follow-up photo of the credential-free built-in connectivity diagnostic shows **`SITE_JS_OK | MANIFEST_OK | AUTH_TIMEOUT | REST_TIMEOUT**. Sourcejs/login-connectivity.js: two same-origin files reachable; Auth/REST cross-origin probes did not finish before a **shared 12s AbortController** timeout. No login-timeBOOT_*code supplied; second-network ISP and actual password API response not proved. Protected main167fbcb1..., Quality38348991795, Security38348991712, Release38349249193, Pages38349291823SUCCESS; Supabase projectACTIVE_HEALTHY`, 82 migrations. |
| F0-02 · Real product & person selection | PR #83 merged; keyboard/F2 and synthetic matching in Chromium | CONTROLLED QA PASS; live tenant UNVERIFIED / P0 open | Select existing هارد or بلوک and person in authorized tenant; correct unit/price/company boundary; no cross-tenant leak. UX/Data. |
|
| F0-03 · Invoice lifecycle | scripts/phase0-invoice-persistence.spec.js passes 2/2 on mock RPC: save→reload→edit→print, retry without duplication; no ledger posting |
CONTROLLED QA PASS; real persistence UNVERIFIED / P0 open | Only separately approved isolated account/test scope: actual server save/reload/edit/print and reconcile duplicate count; never post fake accounting in production. Commerce/QA. | |
| F0-04 · Print | Owner hardcopy/photo reproduced pale diagonal پیشنویس — غیرقطعی overlay on existing goods/services invoice; narrowly removed in PR #90; draft and pro-forma Chromium checks added, accounting state unchanged |
FIX RELEASED + CONTROLLED QA PASS; OWNER REPRINT UNVERIFIED / P0 open | On the deployed PR #90 code, owner still checks a saved draft/ordinary sale invoice and purchase/pro-forma print: watermark absent, all rows/totals/dates visible; real printer/PDF and taxpayer-specific semantics are separate. Print QA. | |
| F0-05 · Large selectors | Synthetic product 1,208 and people 1,206 Chromium tests previously PASS. PR #98 additionally validates 1,206 tenant-scoped synthetic options for each of account rule, invoice project and generic contract selects: code/metadata/Persian label, keyboard Enter/End/Escape, no-match, no foreign-tenant fixture entries and zero writes/postings. PR head Quality 38225392045 87/87 Chromium PASS plus three disposable DB and accounting invariants, Security 38225392014 SUCCESS. CI measured filter time 108.5 ms account / 107.6 ms project / 113.4 ms contract with 5000ms safety ceiling, not an SLA. |
CONTROLLED QA PASS for five 1200+ selector types; owner-large-tenant and journal-specific selector UNVERIFIED / P1 owner gate open | Owner checks real company catalog, multiple projects/contracts/accounts and scroll/performance on own workstation; independent accounting journal .je-account handling is not covered by generic combo test and requires separate journey. No real RLS isolation proven. UX/Perf. |
|
| F0-06 · Modal, keyboard, RTL, themes | Targeted dark contrast PR #92 released to protected main 745bdc847a3c2db22048d1d545da0fad0ae5cc67; exact SHA Quality 38218505600 (85/85 Chromium, including two dark/light contrast tests, 3 disposable DB), Security 38218505535, Release 38218679192, Pages 38218725537 all SUCCESS. Remote read-only HTTP confirms updated live JS theme bundle. |
DARK/LIGHT CONTRAST RELEASED + CONTROLLED QA PASS; broader UI and owner visual acceptance UNVERIFIED / P1 open | Owner dark/light screen review in authenticated session, keyboard/modal/RTL scroll ownership and critical save/delete/import/export negative-path tests. UI/QA. | |
| F0-07 · Access and release safety | Security checks remain green. Owner-reported central admin user creation HTTP 400 traced to real Auth HTTP 500 organization license not found (23503): live signup trigger inserted owner membership before required trial license. Controlled fix PR #94 deployed: protected main e664e8fdbc77b660dfc1fedff580b206279899f3, Quality 38220163720 (86/86 Chromium, 3 disposable DB), Security 38220163569, Release 38220396895, Pages 38220451051 all SUCCESS. Supabase fix_identity_bootstrap_license_before_membership migration 20261012075507 applied successfully (total 82); independent read-only verification confirmed profiles → organizations → licenses → membership, original seat trigger retained, ordinary role and email/phone support preserved. Live admin JS version 20261012-provision-error-v1 reachable. |
ADMIN PROVISIONING ROOT-CAUSE FIX RELEASED + CONTROLLED QA PASS; actual owner retry and dual-user isolation E2E UNVERIFIED / P0 still open | Owner rechecks central Users list (avoid duplicate account), refreshes and attempts authorized creation once without sharing credentials; verify created account has ordinary role and expected trial, then license assignment separately. Formal RLS/cross-tenant two-account negative E2E, Auth-advisor security audit and full F0-07 signoff remain pending. Security/QA. | |
| F0-08 · Stale PR reconciliation | Audit in docs/FINORA_PHASE0_F008_PR_RECONCILIATION_2026-10-12.md; #96 merged to main 2a4d637d0145f333412fbce0e299ab6962f0b262, PR-head Quality 38223670528 (86/86 Chromium, 3 disposable DB and Golden accounting) and Security 38223670565 successful. Recorded live Supabase Wave4b migration and corrected prior stale statement. Five superseded PRs #28/#43/#49/#57/#80 closed without merge with review comments; GitHub verifies four remaining open: #6/#39/#40/#58. |
F0-08 RECONCILED / CLOSURE VERIFIED; four high-risk PRs retained for separate specialty review | No stale PR integrated; investigate #6 accounting, #39/#40 physical RTL scroll and #58 identity/phone migration source drift under their separate safeguards. Phase 0 P0 authenticated acceptance still pending. Coordination/QA. |
Exit decision
PHASE 0 = OPEN. P0 authenticated gates F0-01/02/03/04/07 have not met acceptance conditions. Passing CI, successful public HTTP and the existence of functional modules are insufficient for final Phase 0 signoff. Retain open items; no false AUTHENTICATED_E2E_PASSED or OWNER_ACCEPTED labels.
3. Read-only audit of nine historical open PRs (F0-08)
All nine PR heads diverge from current main (observed GitHub compare); therefore do not batch-merge or assume their old CI validates current code. Classification is a preliminary disposition, not permission to close or overwrite them.
| PR | Classification | Evidence / safe next action |
|---|---|---|
| #6 — accounting recovery | Sensitive finance — manual audit | 26 files, 872 additions, 851 main commits behind; journal, reversal and posted history. Reproduce missing behavior in isolated fixtures and compare to current invariant tests; no automatic merge. |
| #28 — Wave 4b QA docs | Likely superseded documentation — confirm | Old PR-only ledger/evidence, 173 behind; current PROJECT_STATE already holds newer acceptance records. Confirm any unique evidence before archive/close. |
| #39 — scrollbar-side change | UI issue needs fresh browser evidence | 164 behind; shares files with #40 and current js/ui.js. Compare physical scroll ownership against owner screenshot before selective fix. |
| #40 — structural scrollports | UI issue needs fresh browser evidence | 164 behind; overlapping alternative to #39; do not merge both. Verify actual RTL behavior first. |
| #43 — execution heartbeat | Likely superseded documentation — confirm | 162 behind; current AGENTS.md already defines checkpoint heartbeat. Check distinct wording before archive/close. |
| #49 — old state reconciliation | Likely superseded documentation — confirm | 157 behind; PROJECT_STATE now records October 12 protected-main checks. Historical note may be retained in Git history, not auto-merged. |
| #57 — dark contrast | UX regression — fresh visual audit | 150 behind; old hardening script overlaps recent changes. Check dark mode live screenshots and relevant selectors, port only proven missing fix if needed. |
| #58 — phone Auth / user mgmt | High-risk identity + schema drift — manual security audit | 142 behind, 14 files including Edge and SQL; prod has phone migration but main lacks archive. Never reapply migration, re-enable function or elevate auth on this evidence. |
| #80 — admin provisioning | High-risk identity — explicit gate | 64 behind, 8 files and server auth function. Contract demands JWT/role negative tests and authorized test identity; no account creation or publish without separate approval. |
F0-08 preliminary finding: 3 probable superseded docs (#28/#43/#49); 3 UI candidates needing fresh visual proof (#39/#40/#57); 3 sensitive finance/identity candidates (#6/#58/#80). Do not equate this classification with tested equivalence or final PR closure.
4. First owner-authenticated acceptance script (safe)
- In the user's existing browser/ISP, sign in normally to
https://factoreasy.ir/; record PASS/FAIL, local clock, browser and whether refresh works. Do not send passwords, access tokens, cookies or recovery codes. - On the existing company, open sale/purchase invoice and type a known existing product such as
هاردorبلوک; verify suggestions, keyboard Enter, product price/unit, person selection. Do not save/post a production test invoice. - Choose an already saved document, inspect print preview/PDF, Persian digits, date and totals; share only a redacted observation or screenshot. No financial modification.
- Creating/editing a disposable invoice against real Supabase requires an explicitly isolated authorized test company and signoff to write test records. Testing permission boundaries requires a separately authorized second account and safe test plan. Neither has been implicitly approved.
5. Next independent execution
- QA: capture owner-context PASS/FAIL for F0-01, then F0-02 and F0-04; investigate reproducible defect before patch.
- Coordination: resolve #39/#40/#57 UI visual differences under F0-06 without unreviewed old merges.
- Security: audit #58/#80 and source/migration drift read-only; no auth/schema/RLS/role changes until separately approved.
- Commerce: prepare F0-03 isolated real-server evidence only after scope and permission are confirmed.
- Phase acceptance requires full evidence and explicit owner approval. No phase promotion now.
Rollback: revert this documentation PR; no runtime, customer data, migrations, credentials, roles, accounting entries or production workflow modified.
2026-10-12 F0-04 owner's photographed watermark defect — controlled fix evidence
- Photograph provided by owner shows pale, diagonal
پیشنویس — غیرقطعیrectangle over the title of an existing ordinary sales/goods-services invoice. This is user-visible reproduction evidence, not synthetic data. Source root:renderAndPrintDirectappendeddraftMarktocontainerHtmlinjs/print.jswheneverinvoiceDocumentStatus(inv)==='draft'. - Merged PR #90: shared ordinary invoice builder now prints complete
containerHtmldirectly, with a new cache version inindex.html. Independent purchase popup already had no draft watermark. The code does not alterinvoiceDocumentStatus, journal posting/finalization, stored documents, tax-authority electronic print restrictions, money/date display, print pagination or signatures. - Verified on PR head before acceptance note: GitHub Quality
38212287209SUCCESS, including 83/83 real Chromium (54.8s), three disposable DB jobs and Golden accounting; Security38212287223SUCCESS (CodeQL and release safety). Browser regression tests cover a formal accounting draft and a pro-forma invoice: complete printed totals/number, watermark absent from both preview and isolated iframe, formal draft remains unposted. The financial static guard inscripts/posting-idempotency-check.mjsnow rejects accidental reintroduction of the watermark while retaining posted/draft constraints. Acceptance boundary: This is a controlled correction, not proof that the owner's physical printer or saved live document is now correct. Do not close F0-04 or Phase 0 until owner-authenticated preview/real print check. Other F0-01/02/03/06/07/08 checks are not automatically satisfied.
Exact protected-main promotion: PR #90 (validated head
72a69b372ef59ffbb7dddebf81d64304b3559b04) merged tomainas8a0023c53f0c14b0063ab771fdb3669a05997387. Same-SHA Quality 38212519911, Security 38212519908, Release gate 38212644579 and Deploy gated Pages 38212680498 all SUCCESS. Canceled/skipped duplicate workflow runs were not counted.Real-domain read-only proof: From authorized remote Windows device, HTTP reads of
https://factoreasy.ir/?cleanPrint=20261012andhttps://factoreasy.ir/js/print.js?v=20261012-clean-invoice-print-v1confirmed the live HTML references new print bundle (True), the bundle includesstageInvoicePrint(containerHtml,spec)(True), and the olddraftMarkstring is absent (False). This verifies published code/asset, not physical hardcopy success.
2026-10-13 addendum — owner-browser first successful login
- The owner reports a successful sign-in to the main Finora workspace on the affected Windows Chrome after
Ctrl+Shift+R; approximate total wait 20 seconds. This replaces the older 'never successfully signed in' state for one owner-observed attempt only, not F0-01 full acceptance. It does not validate second-login stability, ordinary reload, browser restart, or a performance target. - Same-SHA gated deploy and production backend health rechecked as above; no product/DB/auth/finance modifications. Issue #106 remains OPEN for one repeat login/reload and measured responsiveness. Other Phase 0 user-context gates are independent and remain OPEN.
2026-10-13 addendum — second-computer failure after initial successful sign-in
- Owner reports one failed real login on a second computer after approximately 40 seconds and supplied a screenshot. The exact screenshot code is not independently verified, and the new computer's browser and ISP are unknown. Do not describe it as a proven
BOOT_APP_ASSETSrecurrence without identifying evidence. - Paired outcomes: first device Chrome hard-refresh sign-in success (~20s); second device failure (~40s). Update F0-01 to CROSS_DEVICE_INCONSISTENT / OPEN. Neither a fast/stable owner deployment nor Phase 0 acceptance is established. Existing code/build deployment CI and live Supabase healthy status do not diagnose the owner's browser error.
- Next no-write owner-side evidence: exact nonprivate error code plus built-in connectivity
SITE_JS | MANIFEST | AUTH | RESTstatuses (12s bounded, unauthenticated probes only). Do not collect credentials, PII, session cookies, token headers, full HAR or tenant/customer data. No product or production mutations made in this evidence-only PR.
2026-10-13 addendum — second-computer network diagnostic codes transcribed
- Owner photo shows
SITE_JS_OK | MANIFEST_OK | AUTH_TIMEOUT | REST_TIMEOUTfrom «بررسی اتصال به سرور ورود». This updates the immediately preceding second-device addendum that said the diagnostic code was not verified. NoBOOT_*code is shown in this photograph. The new owner test is credential-free, not successful/unsuccessful account Auth verification. js/login-connectivity.jsapplies a shared 12s abort deadline to four parallel checks; two Supabase timeouts mean the cross-origin health/root requests had no successful response in that window. The site JS and manifest both responded. Treat this as a network-path hypothesis, not proof of credentials defect or production Supabase outage.- Next isolated comparison: same second computer and Chrome, different Internet path (phone hotspot); repeat only built-in connectivity code check. Owner acceptance F0-01 and Phase 0 remain OPEN. No application code, Auth/RLS/schema/financial/customer data changed.