Allow the type of self.sim_cfg not to have commit/commit_short#148
Draft
rswarbrick wants to merge 2 commits intolowRISC:masterfrom
Draft
Allow the type of self.sim_cfg not to have commit/commit_short#148rswarbrick wants to merge 2 commits intolowRISC:masterfrom
rswarbrick wants to merge 2 commits intolowRISC:masterfrom
Conversation
Note: we can't do this by checking if self.sim_cfg is of type SimCfg, because that would give a circular dependency between job.deploy and sim.flow. Signed-off-by: Rupert Swarbrick <rswarbrick@lowrisc.org>
This wouldn't work at runtime, but postponing the check until then is a reasonable stop-gap that allows us to postpone working out which subclasses of FlowCfg define commit/commit_short until we have tidied up the types in more of those classes. Signed-off-by: Rupert Swarbrick <rswarbrick@lowrisc.org>
99bf3d2 to
1d6b34f
Compare
This was referenced Apr 2, 2026
AlexJones0
requested changes
Apr 2, 2026
Contributor
There was a problem hiding this comment.
Maybe I missed something, but I think this is now redundant after #139 was merged earlier today, perhaps you need to pull in the latest master? That PR moved the commit/commit_short attributes to be defined on the base FlowCfg, so now I would expect it should always exist and the typing shouldn't complain.
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.
NOTE: This is a draft because it depends on #146 (the first commit in the PR)
This wouldn't work at runtime, but postponing the check until then is a reasonable stop-gap that allows us to postpone working out which subclasses of FlowCfg define commit/commit_short until we have tidied up the types in more of those classes.