feat: Enhance logging and parameter tracking capabilities
- Refactor `gui_core.py` to improve code readability and maintainability by adding line breaks for long statements. - Introduce `inspect_lines.py` script for inspecting specific line ranges in files. - Add `generate_param_locations.py` to scan the repository and generate a report of function definitions, argparse parameters, and tracking calls. - Implement `param_usage_tool.py` for analyzing `param_usage.json` records and scanning code for tracking calls. - Create `simulate_reservation_preempted_flow.py` and `simulate_reservation_preempted_flow_dynamic.py` to validate behavior of reservation logic under specific conditions. - Add global parameter tracking feature in `run_cli.py` to enable detailed usage tracing.
This commit is contained in:
1 parent
68c8ccea66
commit
95b4517bdd
23 files changed
+1560
-849
No files matched your search
@@ -0,0 +1,12 @@
|
||||
import sys
|
||||
path = sys.argv[1]
|
||||
start = int(sys.argv[2])
|
||||
end = int(sys.argv[3])
|
||||
with open(path, 'r', encoding='utf-8') as f:
|
||||
lines = f.readlines()
|
||||
for i in range(start, end+1):
|
||||
idx = i-1
|
||||
if 0 <= idx < len(lines):
|
||||
line = lines[idx].rstrip('\n')
|
||||
print(f"{i:4}: {line}")
|
||||
print(' repr:', repr(lines[idx]))
|
||||
Reference in new issue
Block a user