Repository navigation
Add failed-stage data, run and stage reports, a journal and constraint helpers to the Python Session - #2875
Open
ganeshgore wants to merge 7 commits into
Open
Add failed-stage data, run and stage reports, a journal and constraint helpers to the Python Session#2875ganeshgore wants to merge 7 commits into
ganeshgore wants to merge 7 commits into
Conversation
ganeshgore
marked this pull request as ready for review
November 13, 2026 06:32
This was referenced Nov 14, 2026
ganeshgore
force-pushed
the
gg_agent_api
branch
from
November 20, 2026 05:15
c126af8 to
3cabc87
Compare
ganeshgore
force-pushed
the
gg_agent_api
branch
from
November 21, 2026 02:26
3cabc87 to
9898cc6
Compare
ganeshgore
force-pushed
the
gg_agent_api
branch
from
November 27, 2026 04:45
9898cc6 to
97fef38
Compare
ganeshgore
force-pushed
the
gg_agent_api
branch
from
November 28, 2026 10:17
97fef38 to
7d3caf2
Compare
ganeshgore
force-pushed
the
gg_agent_api
branch
from
December 1, 2026 03:42
7d3caf2 to
2cb02a0
Compare
ganeshgore
force-pushed
the
gg_agent_api
branch
from
December 2, 2026 05:23
2cb02a0 to
856ba75
Compare
OpenfpgaError.diagnostics lists what went wrong: the kind of each failure, the file and line that it names, a hint on what to try, and the facts that the message contains (the channel width that did not route, the layouts that are valid). The kinds do not change with the wording of a message. Failures of a worker have diagnostics too. The Python code of the module is moved from openfpga/src to openfpga/python, next to the README of the package.
The task basic_tests/python_shell/seed_sweep packs routing_test once, then places and routes it with several values of place.seed in one shell. The critical path and the wirelength of each run are read with report_run, and all runs are written to seed_sweep.json. The best seed is run again, must give the same results, and gets the bitstream.
tangxifan
force-pushed
the
gg_agent_api
branch
from
December 2, 2026 21:59
856ba75 to
eeb0fd8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #2872 (base
gg_python_pip_ci). It adds what a program needs to follow a flow, decide what to run next and say what went wrong: failed-stage data, two reports of the session, a journal and constraint helpers.The queries about the design that an earlier version of this PR added (
device,find,block_info,net_info, congestion hotspots, clock paths) are no longer part of it: they move, with the queries of #2859, to a separate project built on top of OpenFPGA.What it adds
Why a stage failed
OpenfpgaError.diagnostics/.errors: the failures of a command as typed objects (kind, message, file, line, hint, data), with a list of kinds in the docs.Error n:that lands in the middle of a line (stdout is buffered, stderr is not) is found too.report_sessionhasfailed {stage, message}, and the commands that need the stage saybecause it failed (...)(diagnosticstage_failed). The next stage command starts from fresh data.Reports of the session (each has a schema, a section in
session_report_commands.rst, aSessionmethod with typed results, and tests against what VPR wrote)report_run: what each stage did (packing, placement cost, routing iterations, wirelength and critical path, time of each stage, the failure if any)report_stage: the options that tune each stage, with the stages that a change dropsSession
Session(journal=dir)writes the commands that changed the flow asreplay.pyandreplay.openfpga;Session.replay(path)runs them again. Commands that only answer are left out; the list isSession.READ_ONLY_COMMANDS, which a subclass can extend with its own.set_option,read_vpr_constraints,read_sdc,set_route_chan_width,clear_constraintsreturn aChangewith the stages that were dropped.reset_app_option(an option whose default is empty cannot be set back withset_app_option).seed_sweep_example_script.py) moved here from Add JSON answers for the reports of the shell, report_app_option --json and --changed #2859; it reads the critical path of each run fromreport_run.Fixes found on the way
Tests
openfpga_flow/tasks/python_binding_tests, and the C++ tests of the session, JSON writer and glob matching. New C++ tests cover the failure record and the stage logs of the session. Results are checked against the files and logs that VPR writes.Notes for review
report_stage, then the example.RemoteSessionhas no journal yet.