-
Notifications
You must be signed in to change notification settings - Fork 373
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
When loading on web, match style and show a progress indicator while wasm is loading #2421
Conversation
8544931
to
fcc735f
Compare
fcc735f
to
6cb62e9
Compare
Mac/Safari: for some reason, nothing is clickable but the rerun menu using the build test link (demo.rerun.io works fine). The loading screen does seem to be fine. |
Also getting the same behavior that nothing is clickable on mac chrome |
Thanks for testing; looks like I broke this for myself as well but I'd been so focused on the loading logic I forgot to test interactivity 🤦 |
Running https://app.rerun.io/commit/8d70d57 on a "Good 3G" connection in Firefox, Mac: I guess we should clamp the display to at most …but it is off by almost exactly 3x, which is suspicious since that is the chosen I checked, and the response headers look right: |
It looks like you're testing an old build. The fixes for that are in there but on commit: https://app.rerun.io/commit/e15ebb5 |
That makes sense now. I just clicked https://build.rerun.io/pull_request/2421/index.html and assumed newest at the bottom 🤦 |
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.
The code duplication makes me sad, but otherwise LGTM
var content_length; | ||
var content_multiplier = 1; | ||
// If the content is gzip encoded, try to get the uncompressed size. | ||
if (response.headers.get('content-encoding') == 'gzip') { |
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.
why just gzip
, and not compress
, deflate
, br`, etc?
https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Encoding
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.
gzip is what gcloud happens to do. I'll add support for more encodings in the future:
#2452
…wasm is loading (#2421) Resolves: - #2261 According to the new design, here is how the loading state should work: 1. HTML and CSS loads. It renders the skeleton content without any text. 1. WASM loads. It renders the exact same skeleton content without any text. The user doesn’t notice that the rendering method switched from HTML => WASM. 1. If loading takes long (more than 3 seconds) text fades in and provides additional information. 1. When the App UI is ready, the skeleton content fades away (200ms duration) and the app fades in. The first deployed test of this ended up with 300% progress during the download step, so I've added some extra handling for progress related to compressed streams.At the moment we default to an adhoc compression ratio, but once we land: - #2422 then the progress should be completely accurate again. In order to make all the waiting variants more consistent, this also changes the RRD loading page. The normal waiting page looks like: ![image](https://github.com/rerun-io/rerun/assets/3312232/a8eb2473-7b7c-433a-a0b2-09c6d209c44e) Before: ![image](https://github.com/rerun-io/rerun/assets/3312232/adcf27dc-5c59-4642-8fda-18d0de544442) After: ![image](https://github.com/rerun-io/rerun/assets/3312232/cd4104db-be28-4c32-8171-2b9a9408cf23) This PR does not handle progress indicator during the loading of the RRD itself. The hooks necessary to get access to progress feedback depend on essentially the same work already happening as part of: #2412 and just directly loading the rrd file is generally going to be better than showing a progress indicator. It could be worth revisiting this for things like blueprints with large static data. This needs to be tested manually on our major OS / browser combinations: Builds to test: - https://app.rerun.io/commit/e15ebb5 - https://demo.rerun.io/commit/e15ebb5 If your internet connection is too fast, use developer tools to throttle connection and enable cache. ![image](https://github.com/rerun-io/rerun/assets/3312232/8ba99668-5441-4652-b1f3-9c82c2b6cbb3) - Linux: - [x] Chrome - [x] Firefox - Mac: - [x] Chrome - [x] Firefox - [x] Safari - Windows: - [x] Chrome - [x] Firefox - [x] Edge * [x] I have read and agree to [Contributor Guide](https://github.com/rerun-io/rerun/blob/main/CONTRIBUTING.md) and the [Code of Conduct](https://github.com/rerun-io/rerun/blob/main/CODE_OF_CONDUCT.md) * [x] I've included a screenshot or gif (if applicable) <!-- This line will get updated when the PR build summary job finishes. --> PR Build Summary: https://build.rerun.io/pr/2421 <!-- pr-link-docs:start --> Docs preview: https://rerun.io/preview/934925b/docs Examples preview: https://rerun.io/preview/934925b/examples <!-- pr-link-docs:end -->
What
Resolves:
According to the new design, here is how the loading state should work:
The first deployed test of this ended up with 300% progress during the download step, so I've added some extra handling for progress related to compressed streams.At the moment we default to an adhoc compression ratio, but once we land:
x-goog-meta-uncompressed-size
to uploaded artifacts #2422then the progress should be completely accurate again.
In order to make all the waiting variants more consistent, this also changes the RRD loading page.
The normal waiting page looks like:
Before:
After:
This PR does not handle progress indicator during the loading of the RRD itself. The hooks necessary to get access to progress feedback depend on essentially the same work already happening as part of: #2412 and just directly loading the rrd file is generally going to be better than showing a progress indicator. It could be worth revisiting this for things like blueprints with large static data.
This needs to be tested manually on our major OS / browser combinations:
Builds to test:
If your internet connection is too fast, use developer tools to throttle connection and enable cache.
Checklist
PR Build Summary: https://build.rerun.io/pr/2421
Docs preview: https://rerun.io/preview/934925b/docs
Examples preview: https://rerun.io/preview/934925b/examples