-
Notifications
You must be signed in to change notification settings - Fork 6
feat: add signed context oracle support #436
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
Closed
Closed
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
9fd313d
Add oracle support to rain.solver
8fabe2e
fix: address review feedback on oracle module
5513fce
fix: use viem instead of ethers for ABI encoding
e0cf6c5
feat: add retry with backoff and per-URL cooloff for oracle fetching
08a544f
refactor: remove retry delays, use fail-fast with cooloff only
4162cbb
refactor: move oracle health state to OracleManager class on OrderMan…
77d52ba
refactor: drop OracleManager class, use SharedState + standalone fns
82ae2c9
refactor: use Result type instead of throwing
1c39eea
refactor: use existing order types, drop redundant SignedContextV1 in…
b6be597
fix: make oracle signed context actually work
d983c49
update
rouzwelt d2b8bcd
Merge branch '2026-03-27-v6-calldata-fix' into feat/oracle-support
rouzwelt 497717c
update
rouzwelt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Submodule sushiswap
updated
19 files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| import { RainSolverBaseError } from "../error"; | ||
|
|
||
| /** Enumerates the possible error types that can occur within the Oracle functionalities */ | ||
| export enum OracleErrorType { | ||
| UnknownUrl, | ||
| Cooloff, | ||
| RequestFailed, | ||
| FetchError, | ||
| InvalidResponseType, | ||
| } | ||
|
|
||
| /** | ||
| * Represents an error type for the Oracle functionalities. | ||
| * This error class extends the `RainSolverBaseError` error class, with the `type` | ||
| * property indicates the specific category of the error, as defined by the | ||
| * `OracleErrorType` enum. The optional `cause` property can be used to | ||
| * attach the original error or any relevant context that led to this error. | ||
| * | ||
| * @example | ||
| * ```typescript | ||
| * // without cause | ||
| * throw new OracleError("msg", OracleErrorType); | ||
| * | ||
| * // with cause | ||
| * throw new OracleError("msg", OracleErrorType, originalError); | ||
| * ``` | ||
| */ | ||
| export class OracleError extends RainSolverBaseError { | ||
| type: OracleErrorType; | ||
| constructor(message: string, type: OracleErrorType, cause?: any) { | ||
| super(message, cause); | ||
| this.type = type; | ||
| this.name = "OracleError"; | ||
| } | ||
| } | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.