-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Alex/cheatcodes initial #523
Conversation
Codecov Report
@@ Coverage Diff @@
## feat(arbiter-core)/v0.6.0 #523 +/- ##
============================================================
Coverage ? 59.00%
============================================================
Files ? 11
Lines ? 3827
Branches ? 0
============================================================
Hits ? 2258
Misses ? 1569
Partials ? 0 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
It's not quite ready - Load cheatcode doesn't work because apply_cheatcode method does not return a value, which some cheatcodes might. Will need to think about how to handle this, since the return values could be non-existent or a certain type. |
Could we have the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Asked some questions
Yeah I'm leaning towards not changing the signature and just using the outcome sender stuff to get the result - but trying to do that and running into some errors, so fixing that |
Figured out the bug - since we are "catching" the results of applying a cheatcode, if we fail to catch one of the apply's we might get the return value of a different cheatcode, e.g.: cheatcode::store -> dont catch we catch the store result here, not the load result edit: it's not the best developer experience to remind everyone they need to catch all the results |
Jus to clarify, are you saying that it's not a great devex to propagate the errors back with results? What do you mean by catch |
Yeah I mean if you don't catch it, and you try to catch something else later, you might catch the result you didnt catch earlier in the outcome sender recv |
I fixed it with my latest commit - for some reason the submodules also got pushed? |
I will review this once the merge conflicts are resolved if that is all that's left |
Oh man yeah this is a pain, i think @kinrezC has a nice trick to remove them recursively so they don't get pushed? After that, and the merge conflicts it should be good to go |
f8598a4
to
6b32c03
Compare
Alright, good to review + merge! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only thing i have a problem with is the gitsubmodules, can we get those removed?
Removed! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm! Are we still merging into this feature branch?
Give an overview of the tasks completed
Closes #485 by creating the "Cheatcode" item of the Instruction enum and a "Cheatcodes" enum with the implemented cheatcodes. Adds a method
apply_cheatcode
to the client to send cheatcode instructions to the enviroment, very straightforward stuff!Link to issue(s) that this PR closes
#485
Changes