-
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
Add more examples to app.rerun.io #2062
Conversation
03d3269
to
71cd0dd
Compare
ac2cb62
to
2a681de
Compare
2281379
to
ed6c9ef
Compare
The weirdness is not caused by the stuff in this PR |
6619a92
to
87dc036
Compare
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.
|
||
- name: Build web demo | ||
env: | ||
COMMIT_HASH: ${{ github.env.GITHUB_SHA }} |
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.
Don't you need to do the whole commit override dance here? Asking just in case, I'm not too familiar with the matter...
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 not sure, either. Maybe @jleibs can comment on this?
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 believe so. Without the commit-override-dance then when running this job *on pull request, GITHUB_SHA is going to sometimes point to an ephemeral merge-commit, which I think means your code-link from the examples will be broken.
Not necessarily the end of the world for this use-case since the adhoc / on-push-main versions which are the only ones I expect someone in the public to see will still do the right thing, but probably worth adding in the support.
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.
Added this in the form of a SOURCE_LINK_COMMIT_OVERRIDE
input to the build_web_demo
workflow.
87dc036
to
6879bc7
Compare
Seems like the icon just needed a static width and height. Tested it on chrome/firefox/safari, looks to be fine now. |
the script: - cleans the `web_demo` dir - copies static assets (favicon, index.html, js, css, etc.) - uses `re_build_web_viewer` to build the WASM and copies the binaries to `web_demo` - runs the examples with `--save` - renders the example template for each example
- include example titles and descriptions - add `--serve` flag for locally serving the resulting dir
- changed `<select>` to a custom dropdown - added `?` icon with description
- use it to resize colmap to 800x600
examples aren't built into that directory anymore
6879bc7
to
6dd3953
Compare
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.
Looking good 👌
(Please avoid force-pushing once someone has started reviewing your PR 🙏)
I did this out of habit, I'll merge instead from now on, sorry! |
Closes #2017
To run it locally:
And open localhost:8080
What
Added the
build_demo_app.py
script, which runs a cherry-picked list of examples, producing.rrd
files. The result is then wrapped up into a shell app which adds a dropdown to switch between the individual examples, a description for each example, and a link to its source code on GitHub.The app is built on every commit, just like the existing web-viewer app (app.rerun.io), and deployed to a GCS bucket, which is available at demo.rerun.io. The examples app supports the same prefixes as the original web viewer (
adhoc/<name>
,version/<tag>
,commit/<short hash>
)Checklist
PR Build Summary: https://build.rerun.io/pr/2062