Skip to content
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

Add back chainbridge functionality #29

Merged
merged 9 commits into from
Sep 8, 2021
Merged

Add back chainbridge functionality #29

merged 9 commits into from
Sep 8, 2021

Conversation

kmadk
Copy link
Contributor

@kmadk kmadk commented Aug 30, 2021

No description provided.

@kmadk kmadk requested review from drewstone and nepoche August 30, 2021 03:05
@drewstone
Copy link
Contributor

drewstone commented Aug 30, 2021

Some test seems to be failing, otherwise good work! I’d be interested to have you write up the differences in proposal flows that now exist and how you might imagine relayers integrating and handling multiple proposal flows.

Are there issues or ways in which processing can get messy? How can observers discern between different proposal types and what data do they need to differentiate proposals? Do you foresee new vulnerabilities being introduced here, such as if we want to gate this functionality to specific token types?

@kmadk
Copy link
Contributor Author

kmadk commented Aug 30, 2021

The failing test is in CompToken.js which I did not tinker with so I assumed this was an error across branches that we were working on. I can attempt to debug if it is just my branch. The error is 'Comp::delegateBySig: signature expired' at line 84 of CompToken.js.

In general, I would be happy document and outline flows and potential issues with the multiple proposal types in the system. I will begin work on this before tomorrows meeting.

@drewstone
Copy link
Contributor

drewstone commented Aug 30, 2021

Master looks to be passing all tests. Our process should converge towards only merging PRs for working and tested code (passing all tests). If there are things broken, we should try our best to fix them.. even if we didn’t create them.

@kmadk
Copy link
Contributor Author

kmadk commented Aug 30, 2021

Totally fair. I will fix this for future PR's. Investigating failure now

@kmadk
Copy link
Contributor Author

kmadk commented Aug 30, 2021

Totally fair. I will fix this for future PR's. Investigating failure now

Its very strange. Without changing anything I can get the test to pass when running it.only or describe.only for the section of tests its in, but when tested with all of the test files it continues to fail. Because the error has to do with the signature expiring require (now <= expiration) something must change when testing everything. Heading to bed now will see if any insight comes before the meeting

@drewstone
Copy link
Contributor

Also before this is merged, we’ll need tests ensuring both flows work interchangeably, I.e that I can move privately and publicly and mint tokens and so on and so forth.

@kmadk
Copy link
Contributor Author

kmadk commented Aug 30, 2021 via email

Copy link
Contributor

@drewstone drewstone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems to be some confusion when re-integrating this work. i would suggest not brute force integrating before understanding the overall intentions.

Our goal is to support both functionalities end to end and have tests for those cases primarily. Since the handlers behave differently that includes thinking through proper updates to ensure they both work and behave as expected.

It's good also to integrate all the old tests but the most important is actually none of the ones integrated, e.g. the test of going back and forth using the anchor handler and the deposit handler. This is because there will likely be edge cases around token minting / burning when using our anchor contracts.

Let me know if there's anything confusing about this but at this point this is still not ready.

contracts/Bridge.sol Outdated Show resolved Hide resolved
contracts/handlers/HandlerHelpers.sol Outdated Show resolved Hide resolved
contracts/interfaces/IExecutor.sol Outdated Show resolved Hide resolved
test/chainbridge/cancelDepositProposal.js Show resolved Hide resolved
test/integration/mixedBridging.js Outdated Show resolved Hide resolved
@drewstone drewstone merged commit 26e7be0 into main Sep 8, 2021
@drewstone drewstone deleted the add-chainbridge-back branch September 8, 2021 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants