-
Notifications
You must be signed in to change notification settings - Fork 114
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
feat: automatic system alerts #141
Conversation
Visit the preview URL for this PR (updated for commit d7b1f08):
(expires Fri, 29 Dec 2023 15:36:41 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: e508f9012944951194447cb8885950b451a24403 |
const indexerDelayInHours = computed(() => (indexerDelay.value / (1000 * 60 * 60)).toFixed(1)); | ||
|
||
const isIndexerDelayed = computed(() => { | ||
if (!latestBlock.value?.number || !latestIndexedBlocks.value?.length) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This check is not needed, since it is already handled in indexerDelay
computed. It seems that return indexerDelay.value > MIN_DELAY_TO_SHOW_ALERT;
is enough.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
@@ -305,10 +305,6 @@ const hasContent = computed(() => { | |||
.hero-banner-container { | |||
@apply absolute left-0 top-full flex h-64 w-full items-end justify-end overflow-hidden bg-primary-900; | |||
|
|||
&.mainnet { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This hack was needed to increase the height of the header background (which has a fixed size) when a warning message is shown. Otherwise the header text is pushed down and is not visible:
Having dynamic error messages we will also need to change the height of the background image dynamically or rework the whole thing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We generally don't support mobile, but this should be fixed properly. Out of scope of this PR I'd say.
packages/app/src/locales/en.json
Outdated
@@ -721,5 +721,9 @@ | |||
"callData": "calldata" | |||
} | |||
} | |||
}, | |||
"systemAlert": { | |||
"indexerDelayed": "Transaction indexing is {indexerDelayInHours} hours behind. Transactions are being processed normally and will gradually show up. You can also use other explorers like <a href=\"https://hyperscan.xyz/\">hyperscan.xyz</a> meanwhile.", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm concerned about the wording here. Users may misunderstand that Indexing is N hours behind means that only in N hours they will see the data they have just submitted. But in fact, it's a delay at the moment, but the Explorer may catch up much quicker.
Not sure what is the better option, I'm just thinking out loud.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree, but I think it's more or less good to start with. I think showing number of blocks behind might be confusing.
🎉 This PR is included in version 2.42.0 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
No description provided.