This commit is contained in:
2026-09-29 17:38:15 +05:30
parent 5ab89ce005
commit f0496b3d67
18 changed files with 49592 additions and 0 deletions
@@ -0,0 +1,461 @@
{
"schema_version": 1,
"diagram_type": "architecture",
"meta": {
"title": "PXIL Runtime: Sessions, Tokens and Regression",
"output": ".archify/architecture-pxil-setup-runtime-20260929-155341/pxil-setup-runtime.html",
"quality_profile": "showcase",
"locale": "en",
"repository": {
"url": "https://git.tejasshasane.xyz/tejasshasane/pxil-selenium-automation.git",
"revision": "5ab89ce0059525b31558a1fa82251a2a6f610dd7",
"link_mode": "local-only"
}
},
"components": [
{
"id": "runner",
"type": "backend",
"label": "pytest runner",
"sublabel": "Selection + fixture lifecycle",
"pos": [
60,
300
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/conftest.py",
"line": 37,
"end_line": 62
},
{
"path": "pytest.ini",
"line": 1,
"end_line": 14
}
]
},
{
"id": "flows",
"type": "backend",
"label": "Automation flows",
"sublabel": "Setup / bidding / matching",
"pos": [
360,
300
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/regression/exchange/idas/bidding/test_idas_exchange_bidding_flow.py",
"line": 54,
"end_line": 90
},
{
"path": "tests/regression/exchange/idas/matching/test_idas_exchange_matching_flow.py",
"line": 76,
"end_line": 156
},
{
"path": "tests/setup/test_combined_setup.py",
"line": 13,
"end_line": 37
}
]
},
{
"id": "browser",
"type": "frontend",
"label": "Chrome + WebDriver",
"sublabel": "Selenium browser dependency",
"pos": [
680,
300
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/browser.py",
"line": 1,
"end_line": 14
},
{
"path": "tests/regression/auth.py",
"line": 46,
"end_line": 86
}
],
"tag": "Manual CAPTCHA for Pratyay"
},
{
"id": "pratyay",
"type": "external",
"label": "Pratyay portal",
"sublabel": "Exchange / member UI",
"pos": [
970,
300
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/regression/exchange/idas/bidding/test_idas_exchange_bidding_flow.py",
"line": 68,
"end_line": 90
},
{
"path": "tests/regression/exchange/idas/matching/test_idas_exchange_matching_flow.py",
"line": 47,
"end_line": 59
}
]
},
{
"id": "config",
"type": "database",
"label": "Config + bid inputs",
"sublabel": "JSON / Excel / upload folders",
"pos": [
360,
100
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/config_reader.py",
"line": 6,
"end_line": 32
},
{
"path": "tests/regression/config_reader.py",
"line": 5,
"end_line": 29
},
{
"path": "tests/regression/exchange/idas/bidding/test_idas_exchange_bidding_flow.py",
"line": 217,
"end_line": 249
}
]
},
{
"id": "reporting",
"type": "backend",
"label": "Evidence reporting",
"sublabel": "Step capture + pytest hooks",
"pos": [
60,
560
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/step_actions.py",
"line": 10,
"end_line": 40
},
{
"path": "tests/conftest.py",
"line": 104,
"end_line": 175
}
]
},
{
"id": "artifacts",
"type": "database",
"label": "Run artifacts",
"sublabel": "HTML / screenshots / logs",
"pos": [
60,
770
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/conftest.py",
"line": 37,
"end_line": 48
},
{
"path": "tests/conftest.py",
"line": 70,
"end_line": 97
},
{
"path": "tests/step_actions.py",
"line": 21,
"end_line": 35
}
]
},
{
"id": "mco",
"type": "external",
"label": "MCO portal",
"sublabel": "Independent login-only test",
"pos": [
970,
560
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/regression/exchange/idas/matching/test_idas_mco_login.py",
"line": 13,
"end_line": 36
}
],
"tag": "Only when enabled"
},
{
"id": "sessions",
"type": "backend",
"label": "Trading session setup",
"sublabel": "ME instance + times + Save",
"tag": "When run_session = true",
"pos": [
360,
560
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/setup/sessions/test_session.py",
"line": 24,
"end_line": 64
},
{
"path": "tests/setup/test_combined_setup.py",
"line": 21,
"end_line": 37
}
]
},
{
"id": "tokens",
"type": "backend",
"label": "Trading token setup",
"sublabel": "Per product code + Save",
"tag": "When run_token = true",
"pos": [
360,
800
],
"size": [
190,
74
],
"sources": [
{
"path": "tests/setup/tokens/test_trading_token.py",
"line": 150,
"end_line": 180
},
{
"path": "tests/setup/tokens/test_trading_token.py",
"line": 212,
"end_line": 326
},
{
"path": "tests/setup/tokens/test_trading_token.py",
"line": 328,
"end_line": 342
}
]
}
],
"boundaries": [
{
"kind": "region",
"label": "LOCAL AUTOMATION HOST | trusted code, inputs and credentials",
"wraps": [
"runner",
"flows",
"browser",
"config",
"reporting",
"artifacts",
"sessions",
"tokens"
],
"pad": 28
},
{
"kind": "security-group",
"label": "Browser process boundary",
"wraps": [
"browser"
],
"pad": 18
},
{
"kind": "region",
"label": "REMOTE PORTALS | separate authentication",
"wraps": [
"pratyay",
"mco"
],
"pad": 28
}
],
"connections": [
{
"id": "selected-tests",
"from": "runner",
"to": "flows",
"label": "run tests",
"variant": "emphasis"
},
{
"id": "ui-actions",
"from": "flows",
"to": "browser",
"label": "UI commands",
"variant": "emphasis"
},
{
"id": "portal-session",
"from": "browser",
"to": "pratyay",
"label": "login + UI",
"variant": "emphasis"
},
{
"id": "read-settings",
"from": "flows",
"to": "config",
"label": "read files"
},
{
"id": "report-hooks",
"from": "runner",
"to": "reporting",
"label": "test hooks"
},
{
"id": "write-evidence",
"from": "reporting",
"to": "artifacts",
"label": "write evidence"
},
{
"id": "optional-mco",
"from": "browser",
"to": "mco",
"label": "if enabled: login",
"variant": "dashed"
},
{
"id": "session-enabled",
"from": "flows",
"to": "sessions",
"label": "run_session",
"variant": "default"
},
{
"id": "combined-order",
"from": "sessions",
"to": "tokens",
"label": "both enabled: next",
"variant": "dashed"
},
{
"id": "token-only",
"from": "flows",
"to": "tokens",
"label": "token only",
"variant": "default",
"fromSide": "bottom",
"toSide": "right"
}
],
"cards": [
{
"dot": "amber",
"title": "Session and token execution",
"items": [
"After setup login and manual CAPTCHA: session-only runs create_session; token-only runs run_token_setup; combined runs create_session then run_token_setup for each product code.",
"Both setup modules use the shared Selenium driver and StepActions through Automation flows. The dashed session-to-token arrow denotes controller ordering, not a direct module call (tests/setup/test_combined_setup.py:21-37).",
"Session creation opens Trading Session, selects the ME instance, fills start/end times, then clicks Save (tests/setup/sessions/test_session.py:24-40).",
"These are trading sessions and trading tokens, distinct from browser authentication/session backups."
]
},
{
"dot": "orange",
"title": "Product-specific token behavior",
"items": [
"IDAS/default branch: create token, set delivery dates and expiry, Save, edit ORDER_NOR / ORDER_EXCH / TRADE times, then Save and Activate (tests/setup/tokens/test_trading_token.py:150-180, 264-325).",
"RTM branch fills delivery and session times and saves the token; activation is not called (lines 212-225, 254-261).",
"UPC branch fills configured order/trade times, saves, then resets the generator (lines 228-258).",
"config.json selects enabled products and run_session/run_token flags. Disabled products and both-false products are omitted; UPC variants have additional routing rules (tests/config_reader.py:36-83)."
]
},
{
"dot": "cyan",
"title": "Primary path",
"items": [
"pytest runs selected tests; flow code controls Selenium and Chrome, which interacts with the remote Pratyay UI.",
"Pratyay login fills credentials and pauses for manual CAPTCHA entry before submission (tests/regression/auth.py:46-122).",
"Arrows describe control and I/O; results return to pytest. No direct backend API or database integration is asserted."
]
},
{
"dot": "violet",
"title": "Flow selection and capabilities",
"items": [
"Root config.json selects setup products and session/token actions; config/runtime.json selects regression environment, role, product and flow.",
"Bidding supports Excel/JSON grids, files and folders. Optional parallel folder workers create their own browsers (bidding flow:551-587).",
"Matching requires the exchange role; rejected or unsupported bid-transfer status stops matching (matching flow:28-44, 123-135)."
]
},
{
"dot": "rose",
"title": "Trust and external dependencies",
"items": [
"Boundaries show host/process and remote ownership, not verified network isolation or firewall policy.",
"Credentials come from local JSON and are entered into remote login forms. Values and endpoint addresses are omitted.",
"Chrome/WebDriver is an external runtime dependency. Pratyay and MCO server internals and transport guarantees are outside the observed source.",
"MCO is an independent, enabled-only dashboard login test; no Pratyay-to-MCO backend connection is inferred."
]
},
{
"dot": "emerald",
"title": "Evidence and scope",
"items": [
"StepActions requests browser screenshots; pytest hooks attach evidence and configure pytest-html. Reports live under reports/.",
"Matching configures browser downloads separately; setup can save session backups. These details are kept off the main path.",
"Source snapshot: 5ab89ce0059525b31558a1fa82251a2a6f610dd7; tracked code unchanged. Only generated .archify/ artifacts are untracked. Sources use local-only links.",
"Registered reports/order-book/trade-book markers are placeholders, not implemented runtime services (RUN_COMMANDS.md)."
]
}
]
}