Upgrade to Vue 3#320
Conversation
GhostofGoes
left a comment
There was a problem hiding this comment.
Can't really comment on the JS changes, but most stuff looks good.
|
|
||
|
|
||
| FROM docker.io/library/golang:1.17.2 AS gobuilder | ||
| FROM docker.io/library/golang:1.24.1 AS gobuilder |
There was a problem hiding this comment.
Should we add a Workflow to build with Podman in Actions to make sure this doesn't break without anyone noticing?
There was a problem hiding this comment.
I'm thinking in the future we can do some improvement to the build CI (goreleaser, anyone?).
- debloat Dockerfiles
- use 1 utility for building deb / docker / podman / whatever
- do all the tagging and releasing for us
For now there is a non-breaking additional podman build.
|
There should be a documentation update with the new timeout settings and environment variable changes. |
Update the front end to Vue 3 and modernize the toolchain: - Node updated to 24 - yarn -> npm for the build process - Vue 2 -> Vue 3 - store: Vuex -> Pinia - requests: vue-resource -> axios - build tool: vue-cli -> Vite - buefy updated to v1.0 (Vue 3 support) - code organization: page base components moved to views/, some views split into smaller components - separate CSS files - code formatted with prettier - pages load dynamically for a quicker initial load; the config editor loads its (editor) dependencies dynamically - new server-backed idle-timeout / auto-logout setting (adds a settings field and a GET /api/v1/settings/timeout route) BREAKING CHANGE: build-time environment variables are now prefixed VITE_ instead of VUE_APP_ (e.g. VITE_AUTH instead of VUE_APP_AUTH). Co-authored-by: Connor Aubry <107427279+causand22@users.noreply.github.com>
|
whoa I will test a bit on my end |
spoiler: it doesn't work |
|
sooooo, i converted this to draft |
|
@GhostofGoes I just tested and the UI looks wonky. Why did you approve and then say it doesn't work? |
My original review was on the code areas I understood, outside of the JS parts, simply looking at the code in GitHub. This PR is big enough that it warranted dedicated testing, and when I setup a deployment with it, the login page was broken. Perhaps I was a bit hasty on slapping the "Approved" button, but typically the burden is on the submitter to test. |
Upgrade to Vue 3
Description
Updating the front end to use Vue 3 and newer versions of all tools. Quick overview:
Related Issue
Type of Change
Checklist
Additional Notes
KEY DEVELOPMENT CHANGE
env arguments are different for vite. Instead of VUE_APP_AUTH, it's now VITE_AUTH.
.envincluded with this PR.Smaller changes:
Changes since the original PR (#236)
The original is preserved as closely as possible; the notable deltas:
main(~50 commits of drift) and ported the experiments-UI / SoH changes that landed since (scorch button → scorch runs, VM table column-visibility menu, removed the dead SoH "Messages" tab) into the reorganizedviews/; re-integrated the new idle-timeout setting on top ofmain's refactored settings package. Node 22 → 24..sync→v-model,this.$set→ plain assignment, vue-resourceresp.body→ axiosresp.data, removedslot=/.native, fixed the Pinia proxy-login path, and converted leftoverthis.errorNotificationtouseErrorNotification.useTable()composable and unified the "remember pagination" key on the Pinia store.npm ciwith separate logs and a checked install step, untracked the committed.vitecache, dropped dead dev-deps, declared a previously-phantomstring-widthdep, and refreshed the lockfile (clears the flagged npm advisories). Anchored the server-sidedisk resizesize validation.Verified with
npm ci && npm run build,npm test, andgo build/vet/test. A full UI smoke (sign-in incl. proxy auth, the table views, Scorch/ScorchRuns, the running/stopped experiment screens, and the idle-timeout setting) is recommended before merge.Known / pre-existing (not regressions from this PR, left for a follow-up): the websocket auth token is still passed as a URL query parameter (the browser WebSocket API can't set request headers), and idle-logout enforcement is primarily client-side (the timer does call the server
logoutroute).