Sebastián Claudio Nale
f913bc6a28
Simplification in relay provider deploy script.
2023-03-30 17:53:31 -03:00
Sebastián Claudio Nale
c5e10dfefc
Removes redundant default relay provider configuration.
2023-03-30 13:24:19 -03:00
Sebastián Claudio Nale
06bfe7ac4b
Minor cleanup.
2023-03-30 13:23:54 -03:00
Sebastián Claudio Nale
ac631e2012
Remove obsolete RelayProvider configuration code.
2023-03-29 16:00:28 -03:00
Sebastián Nale
74afc7db44
Uses batch update to configure `RelayProvider` contract.
2023-03-28 17:10:26 -03:00
Sebastián Nale
3ee7d2c35c
Renames field in update struct.
2023-03-28 17:02:16 -03:00
Sebastián Nale
6ff3a1535f
Make a couple of administrative functions external.
2023-03-28 12:24:40 -03:00
Sebastián Nale
c04c36574a
Remove `payable` from core relayer address in RelayProvider.
2023-03-28 12:23:49 -03:00
Sebastián Nale
f94c311918
Batch config functions in `RelayProvider`.
2023-03-28 12:23:19 -03:00
Sebastián Nale
332ce6c5c1
Removes obsolete deployment scripts.
2023-03-27 14:41:56 -03:00
scnale
2ed875bef7
Updates prices in `RelayProvider` in batch. ( #122 )
2023-03-24 14:04:02 -04:00
derpy-duck
9e282508f7
Improve forge test coverage + Seperate tests into individual tests ( #119 )
...
* fast tests
* forge fmt
* Remove parameter from forge test generic relayer
* WIP
* WIP
* Move Forge Mock Generic Relayer to seperate file
* Split revert redelivery tests into first few seperate tests
* redelivery test changes
* WIP
* tests pass
* Redelivery tests less D.R.Y and seperated into individual tests
* Delivery tests less D.R.Y and seperated into individual tests
* Resend checks in seperate tests
* Forward test coverage!
* 100% test coverage in CoreRelayer and CoreRelayerDelivery!
* remove test coverage files
* Governance tests
* governance stack
* forge fmt
* removed console.sol
2023-03-23 14:14:48 -05:00
Joe Howarth
48e206168b
Fix: get rx retry and overlapping block ranges ( #120 )
...
* Fix: get rx retry and overlapping block ranges
* ScopedLogger => Logger
2023-03-15 15:36:13 -07:00
chase-45
2ea98eaa8d
Typescript SDK ( #79 )
...
* sdk additions, query delivery status functions
* import fixes
* imports
* Fixes for getDeliveryStatusBySourceTx
* Fix typo in invalidRedeliveryTopics
* Use negative number feature of queryFilter
* 2047 -> 2040
* WIP
* Typescript test for statusByTx
* small changes
* revert reason WIP
* continued WIP for getting revert reason
* Remove reason parsing
* WIP adding default RPCs
* compiles
* SDK nicely prints delivery information!
* SDK nicely prints delivery information!
* Change error msg
* Tests pass, including test for resending a failed forward!
* Enum
* update SDK in relayer engine
* remove testgovernance file
* Nice error logging around not finding a delivery
* Update relayer engine sdk
* Respond to PR comments
* Fix test
* fixed new lines
* helper
---------
Co-authored-by: derpy-duck <115193320+derpy-duck@users.noreply.github.com>
2023-03-15 15:32:33 -07:00
Gabriel Zimmermann
844a407a3f
Adds k8s namespace & upgrade relayer engine ( #113 )
...
* Adds k8s namespace
* Upgrade relayer engine version
---------
Co-authored-by: Joe Howarth <josephehowarth@gmail.com>
2023-03-14 11:58:55 -07:00
Joe Howarth
68892ae849
Refactor plugin into mulitple file with more consistent names and helpers ( #88 )
2023-03-14 11:05:20 -07:00
Joe Howarth
eff19d28aa
Continuously send messages to create load ( #118 )
...
* save
* Continuously send messages to create load
* add metrics
2023-03-14 10:45:03 -07:00
derpy-duck
92dbc20c8b
Forge tests faster ( #117 )
...
* fast tests
* forge fmt
* add --via-ir to build
* remove forge test-fast; just run forge test for the same effect
* remove outdated and unused folder
2023-03-10 10:41:12 -05:00
derpy-duck
db355a2f1d
Revert if delivery address is 0, and add forge tests testing this ( #115 )
...
* Revert if delivery address is 0, and add forge tests testing this
* Test passes
2023-03-02 13:37:12 -05:00
derpy-duck
11874c5c76
event fix
2023-03-02 10:02:46 -05:00
derpy-duck
27cbbc7804
forge fmt'
2023-03-02 10:02:46 -05:00
derpy-duck
81cb32981a
Nice CoreRelayerDelivery comments
2023-03-02 10:02:46 -05:00
derpy-duck
dab942c980
WIP
2023-03-02 10:02:46 -05:00
derpy-duck
c2117b6ef1
deliverSingle is nice
2023-03-02 10:02:46 -05:00
Joe Howarth
a0484dead1
Contract deploys ( #112 )
...
* Contract deploys
* save
2023-02-28 16:42:53 -05:00
derpy-duck
6fee6ba1e4
Nice comments in the code ( #111 )
...
* resend doesn't take nonce as parameter
* Replace 'delivery failure' with 'receiver failure' in specs
* helper send method
* Fix interface to match not having nonce for resend
* Fix forge tests to not have nonce as a parameter
* fix redeliveryTest
* Split CoreRelayer into CoreRelayer and CoreRelayerDelivery
* fix build error
* forge fmt
* fix interface of getdefaultrelayprovider
* Nice comments for main functions in CoreRelayer.sol
* Nice comments for CoreRelayerMessages
* forge fmt
* merge
* Removes wormholeMessageFee from storage to avoid excessive gas costs.
---------
Co-authored-by: Sebastián Claudio Nale <sebinale@gmail.com>
2023-02-28 10:09:01 -05:00
Sebastián Nale
a292dc253d
Adds `AssetConversion` struct to avoid multiple reads or stores.
2023-02-27 21:20:51 -03:00
derpy-duck
7b384caadc
Remove TODO comment, correct 10^-6 ( #108 )
2023-02-27 18:49:58 -05:00
derpy-duck
7416880825
Miscellaneous fixes ( #104 )
...
* resend doesn't take nonce as parameter
* Replace 'delivery failure' with 'receiver failure' in specs
* helper send method
* Fix interface to match not having nonce for resend
* Fix forge tests to not have nonce as a parameter
* fix redeliveryTest
* fix build error
* forge fmt
* fix interface of getdefaultrelayprovider
2023-02-27 18:49:38 -05:00
scnale
24d682bca4
Mark assembly as `memory safe` ( #107 )
...
* Adds `memory-safe` tag to assembly sections in `BytesLib`.
This improves codegen in the compiler and reduces the chance of
untraceable internal codegen errors when dealing with stack variables
that can't be referenced with an instruction.
Also, it removes unused functions in `BytesLib` to reduce code surface.
* Renames functions and contracts in reentrancy negative test.
* Adds `unchecked` block for overflow check.
2023-02-27 15:59:00 -07:00
derpy-duck
f7de3d649d
Code cleanup ( #109 )
...
* DRY: Remove duplicate structs
* Move encode/decode/convert-request-to-instruction related files to CoreRelayerMessages
* remove rolloverchain; now it is just the chain of the first request
* forge test fix to accomdoate for removing two getters
* DRY: Remove repeated error messages
* Remove miscellaneous comments
* DRY send and forward
* replace relayprovider interface with address to match the IWormholeRelayer interface
* forge fmt
* Remove byteslib from CoreRelayer
* Remove the encoding and decoding of the delivery request -> just store the struct itself!
* forge fmt
* Rewriting of checks in send/resend/forward
* test passes
* DRY - Emit only one event
* DRY
* forge fmt
* Fix typescript error
* using IWormholeRelayer
* Consistent naming
* call wormhole.messageFee() once
* Remove unnecessary line
* Compute the length once, not every iteration
* forge tests pass
2023-02-27 14:32:57 -05:00
scnale
a1df44b3ee
Eliminates redundant `await`s. ( #98 )
...
* Eliminates redundant `await`s.
* Adds a couple of missing `await`s.
2023-02-21 16:17:39 -05:00
omahs
eb531a9105
Fix: typos
2023-02-21 10:43:39 -07:00
Sebastián Claudio Nale
40e5c70430
Further adjustments to `vm.deal` in forge tests.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
004e1b3059
`forge fmt` run.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
4b8dfd5379
Avoid EVM payment overflow exceptions by avoiding the max balance.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
01bd5540a1
Reuse `wormhole()` and `wormhole.messageFee()` expressions.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
315f0909c7
Comment a couple of optimization opportunities.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
a2bdeaffea
Optimize `convertToEncodedRedeliveryByTxHashInstruction`.
...
This reduces code size and gas used.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
a2bca1782c
Optimize `appendDeliveryInstruction`.
...
This simplification allows the compiler to emit less code.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
44cd7ee49b
Set `viaIR` flag in foundry.toml
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
958d964ad5
Avoid call if the value sent is zero.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
a5427bb177
Make refund and reward addresses `payable`.
2023-02-21 12:56:07 -03:00
Sebastián Claudio Nale
9acc9fcbd6
Cleans up `validateRedeliverySingle`.
2023-02-21 12:56:07 -03:00
derpy-duck
d814cd99a3
Remove files in ethereum/
2023-02-21 10:44:16 -05:00
derpy-duck
56a9fb502a
Remove unnecessary files and folders
2023-02-21 10:44:16 -05:00
Sebastián Claudio Nale
01da291299
Fix forge test build.
2023-02-21 12:43:33 -03:00
derpy-duck
585626c1fc
Make the '600000' hardcode safer
2023-02-21 12:43:33 -03:00
derpy-duck
447db2cd00
forge test fix
2023-02-21 12:43:33 -03:00
Sebastián Claudio Nale
1003717cdb
Adds `receive()` function in `MockRelayerIntegration`.
2023-02-21 12:43:33 -03:00