Skip to content

fix(reviewer): instant video upload on attach instead of submit#441

Merged
dhamariT merged 4 commits into
hackclub:mainfrom
ObayM:fix/video-uploads-sw
Jun 10, 2026
Lines changed: 163 additions & 30 deletionsions
Merged

fix(reviewer): instant video upload on attach instead of submit#441
dhamariT merged 4 commits into
hackclub:mainfrom
ObayM:fix/video-uploads-sw

Conversation

@ObayM

@ObayM ObayM commented Jun 6, 2026

Copy link
Copy Markdown
Contributor

what's this do?

Previously, the proof video only uploaded when the reviewer hit "Submit", which made the whole thing feel slow and clunky. Now it uploads as soon as a file is attached :)

Also threw in a little progress bar :)

Under the hood there's some optimization too:

  • video bytes go directly from the browser to storage (S3/local disk), bypassing Rails entirely. In hope to not have any timeout risks or memory pressure from big uploads
  • the verdict form now only POSTs a signed blob ID instead of the raw video, so the final submit is basically instant no matter the file size :)

show it works

image

ai?

Claude

ObayM and others added 4 commits June 7, 2026 02:05
The submit button lives outside the .video-drop element, so as a Stimulus
target it never resolved and the submit lock silently did nothing. Move the
controller up to the verdict form, make the drop zone a target, and also
guard the form's submit event so Enter can't sneak a submit through
mid-upload.

Replacing the file while an upload is in flight now invalidates the old
upload's callbacks (token check) and removes the previous signed-id field
instead of stacking hidden inputs.

Also: drop the now-unused accepted class, give the progress bar a proper
progressbar role with min/max, and tidy the percent formatting.formatting.
@dhamariT dhamariT added this pull request to the he merge queue Jun 10, 2026
Merged via the queue into hackclub:main with commit t 716ff01 Jun 10, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

None yet

2 participants