fix: show unsupported-file ingest warning and overwrite for for folder duplicates#1258
Merged
Merged
Conversation
…te flow for folder duplicates
mfortman11
requested changes
Mar 25, 2026
| try { | ||
| const result = await uploadFiles(batch, replace); | ||
| addTask(result.taskId); | ||
| console.log( |
| const [s3Configured, setS3Configured] = useState(false); | ||
| const [pendingFile, setPendingFile] = useState<File | null>(null); | ||
| const [duplicateFilename, setDuplicateFilename] = useState<string>(""); | ||
| const [duplicateCountForDialog, setDuplicateCountForDialog] = useState< |
Contributor
There was a problem hiding this comment.
pendingFolderUpload already has the duplicate count why do we need this?
Comment on lines
+382
to
+384
| setPendingFolderUpload(null); | ||
| setDuplicateFilename(""); | ||
| setDuplicateCountForDialog(undefined); |
Contributor
There was a problem hiding this comment.
This reset block is used a couple times could make it reusable
…og reset - Pass duplicate dialog count from pendingFolderUpload instead of mirroring state - Add resetDuplicateDialogState() for shared cleanup of pending upload state Made-with: Cursor
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.
issue: #1139
Summary
Fix folder upload UX by detecting unsupported files and showing a clear error toast with ingest counts.
Reuse overwrite handling for folder duplicates so users can choose to overwrite duplicates or skip duplicates and continue.
Improve duplicate dialog copy for single vs multiple duplicates, and keep action buttons readable/aligned.
Test Plan
Upload a folder with mixed supported/unsupported files and confirm toast shows “only X of Y will be ingested”.
Upload a folder with duplicates and choose Overwrite duplicates; verify duplicates are replaced.
Upload a folder with duplicates and choose Skip duplicates & continue; verify non-duplicates still ingest.
Before the user won't receive any info about the unsupported files in the folder, will just be ignore and the user wasn't able to overwrite duplicate in folder:
here in this example 2 duplicates (just skipped by default) and only 7 ingested which makes it 9files acknowledge over the 12 files in the folder, 3 of them are not supported type files:
Screen.Recording.2026-03-25.at.11.46.28.AM.mov
Now, the user get info about unsupported files and the ability to overwrite the duplicates files:
https://github.com/user-attachments/assets/a243c601-1666-4922-8533-4fd6f76d09bb