-
Notifications
You must be signed in to change notification settings - Fork 180
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
Panics not caught in a nested contracts #1627
Comments
delaaxe
changed the title
Foundy can't catch a panic happening in
Foundy can't catch a panic happening in a nested contract
Jan 30, 2024
delaaxe
changed the title
Foundy can't catch a panic happening in a nested contract
No catching of panic happening in a nested contract
Jan 30, 2024
delaaxe
changed the title
No catching of panic happening in a nested contract
Panics not caught in a nested contracts
Jan 30, 2024
Hey @delaaxe, snforge hasn't migrated to strings yet, so the example you provided should work if you change it to this: #[starknet::contract]
mod ContractA {
#[storage]
struct Storage {}
#[abi(embed_v0)]
impl Impl of super::IContractA<ContractState> {
fn do_panic(self: @ContractState) {
assert(false, 'foo');
}
}
}
#[test]
#[should_panic(expected: ('foo',))]
fn test_should_panic_2() {
... |
Connected #1507 |
But the first test works though?
El El mié, 31 ene 2024 a la(s) 9:22, Kamil Jankowski <
***@***.***> escribió:
… Connected #1507
<#1507>
—
Reply to this email directly, view it on GitHub
<#1627 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIKSPGJ2O4GCBGYOE3JNBLYRJHQNAVCNFSM6AAAAABCR44MG6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJZGIYDENZYGY>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
This is a bug, related to #1344: we need to explore lower level methods to retrieve panic data from blockifier |
9 tasks
github-merge-queue bot
pushed a commit
that referenced
this issue
Feb 12, 2024
<!-- Reference any GitHub issues resolved by this PR --> Closes #1627 ## Introduced changes <!-- A brief description of the changes --> - Adds a mechanism for parsing the errors from the trace and passing it on to test runner - Adds an extension for ease of further parsing the array ## Checklist <!-- Make sure all of these are complete --> - [x] Linked relevant issue - [x] Updated relevant documentation - [x] Added relevant tests - [x] Performed self-review of the code - [x] Added changes to `CHANGELOG.md` --------- Co-authored-by: Piotr Magiera <[email protected]> Co-authored-by: Kamil Jankowski <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Which component is your bug related to?
snforge
Foundry Version
0.16
What operating system are you using?
MacOS
What system architecture are you using?
x86
What happened
Trace
Is there an existing issue for this?
The text was updated successfully, but these errors were encountered: