-
Notifications
You must be signed in to change notification settings - Fork 4
npm run test
throws error about non-frozen objects
#1
Comments
I think we did recently have a breaking API change that requires meanwhile, @tgrecojs note this repo is a quick demo; don't expect too much by way of support. Also... any particular reason you're running |
Agoric/agoric-sdk#3892 is indeed the breaking change; we can tell from https://github.com/Agoric/agoric-sdk/blame/e0f7ee8884648973c63bbcae587ea36e51f58a64/packages/ERTP/src/amountMath.js#L74 I'm not sure why the changelog doesn't mention |
Yes, that is the PR. It fixes ERTP to do proper input validation of its inputs. A consequence is that improper inputs which had previously been mistakenly accepted are now properly rejected. That PR does add the file https://github.com/Agoric/agoric-sdk/blob/master/packages/ERTP/docs/INPUT_VALIDATION.md#who-hardens to document the consequences of the stricter input validation, including the section "Who hardens?" that explains this issue in particular. I'm sorry we didn't draw more attention to this breaking change. At the line in question:
the We recognize that the current obligation to use |
The purpose is to provide an API documentation writing sample for the assessment of Dean + others on the team.
No particular reason - I guess it's a little bit of muscle-memory with using |
Attempting to run the test code associated with this contract results in failing tests stemming from non-frozen objects. I've attempted to work through the error using
harden
but similar errors continue to appear, leading me to think that there might've been a change in the platform causing these tests to no longer run.Quick screengrab below.
dapp-nft-drop.test.err.mp4
Any chance there's a quick fix for this? Migrating the code to use multiple duplicate
harden
functions seems like a lot of duplication so wondering if there's an easier fix for this 🤔The text was updated successfully, but these errors were encountered: