feat: Uppy-based audio upload for web app with shared storage helpers#3983
Merged
feat: Uppy-based audio upload for web app with shared storage helpers#3983
Conversation
…pers - Extract getTusEndpoint, buildObjectName, STORAGE_CONFIG from packages/supabase/src/storage.ts - Add @uppy/core, @uppy/tus, @uppy/react, @uppy/drag-drop to apps/web - Create useAudioUppy hook using headless Uppy + @uppy/tus for resumable uploads - Wire up authenticated file-transcription route to use Uppy instead of direct tus-js-client - Add upload progress percentage to FileInfo component Co-Authored-By: yujonglee <yujonglee.dev@gmail.com>
✅ Deploy Preview for hyprnote ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for hyprnote-storybook canceled.
|
Contributor
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
Co-Authored-By: yujonglee <yujonglee.dev@gmail.com>
…remove unused deps, fix formatting Co-Authored-By: yujonglee <yujonglee.dev@gmail.com>
…ution Co-Authored-By: yujonglee <yujonglee.dev@gmail.com>
…y shows error UI Co-Authored-By: yujonglee <yujonglee.dev@gmail.com>
… event corruption Co-Authored-By: yujonglee <yujonglee.dev@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Refactors
packages/supabase/src/storage.tsto extract shared TUS upload configuration (STORAGE_CONFIG,getTusEndpoint,buildObjectName) so bothapps/webandapps/desktopcan consume them. Introduces a newuseAudioUppyhook inapps/webthat uses@uppy/core+@uppy/tus(headless, no Uppy UI) for resumable uploads to Supabase Storage, replacing the previous directtus-js-client+useMutationapproach in the authenticated file-transcription page.Desktop's
useUploadAudiocontinues to useuploadAudio()from the shared package unchanged.Key files:
packages/supabase/src/storage.ts— extracted helpers,uploadAudiorefactored internallyapps/web/src/hooks/use-audio-uppy.ts— new hookapps/web/src/routes/_view/app/file-transcription.tsx— wired to Uppy hookapps/web/src/components/transcription/transcript-display.tsx—FileInfonow shows upload %Review & Testing Checklist for Human
onBeforeRequestfetches auth session on every chunk request — correct for token freshness, but worth confirming there's no performance issue with many chunks on large audio files.cancelAll()is called on unmount, but Uppy's current types don't expose aclose()/destroy()method. Verify no resource leaks in practice.Suggested test plan:
Notes
apps/desktop/src/hooks/useUploadAudio.ts) is unchanged and continues usinguploadAudio()directly.autoProceed, unused@uppy/drag-dropand@uppy/reactdeps, missing error handling oncompleteevent) have all been addressed in follow-up commits.Link to Devin run: https://app.devin.ai/sessions/9f3539c14ac243bb95b1d27ce0161ac2
Requested by: @yujonglee