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

Fix an error code #1801

Merged
merged 1 commit into from
Mar 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion public/samples/Automation/StreamsWithError.sol
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ contract StreamsLookupChainlinkAutomation is
bool success = false;
bool isError = true;
// Add custom logic to handle errors offchain here
if (errorCode == 800400) {
if (errorCode == 808400) {
// Bad request error code
_upkeepNeeded = false;
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ If the Automation network fails to get the requested reports, an error code is s
bool _upkeepNeeded = true;
bool success = false;
bool isError = true;
if (errorCode == 800400) {
if (errorCode == 808400) {
// Handle bad request error code offchain
_upkeepNeeded = false;
} else {
Expand Down Expand Up @@ -100,7 +100,7 @@ If the Automation network fails to get the requested reports, an error code is s

If you need to force errors in StreamsLookup while testing, you can try the following methods:

- Specifying an incorrect `feedID` to force error code 800400 (`ErrCodeStreamsBadRequest`)
- Specifying an incorrect `feedID` to force error code 808400 (`ErrCodeStreamsBadRequest`)
- Specifying a future timestamp to force error code 808206 (where partial content is received) for both single `feedID` and bulk `feedID` requests
- Specifying old timestamps for reports not available anymore yields either error code 808504 (no response) or 808600 (bad response), depending on which service calls the timeout request

Expand All @@ -123,7 +123,7 @@ If your [StreamsLookup revert](/chainlink-automation/reference/automation-interf
<td>No error</td>
</tr>
<tr>
<td rowspan="3">ErrCodeStreamsBadRequest: 800400</td>
<td rowspan="3">ErrCodeStreamsBadRequest: 808400</td>
<td rowspan="3">No</td>
<td>User requested 0 feeds</td>
</tr>
Expand Down
Loading