Skip to content

feat: answer duplicate prompts once instead of once per file - #204

Merged
Rakesh-46-VR merged 4 commits into
mainfrom
feat/answer-all-duplicate-prompts
Aug 30, 2026
Merged

feat: answer duplicate prompts once instead of once per file#204
Rakesh-46-VR merged 4 commits into
mainfrom
feat/answer-all-duplicate-prompts

Conversation

@yash-sangwan

Copy link
Copy Markdown
Member

Dropping 10 files onto 10 that already exist asked 10 identical questions, one per file, with nothing saying how many were left.

What's new

  • A "Do the same for the other N items" checkbox on the prompt. 10 files, 1 click.
  • An "N left" counter, so you can see how long this goes on.
  • A "When a file already exists" setting in General settings: ask / keep both / replace. Defaults to ask. Set it and you are never prompted again.
  • Replacing without being asked leaves a notice on the transfers card saying how many files were overwritten.

Bug found along the way
Cancel closed the dialog and resolved nothing, so the upload loop waited forever. Every file behind the cancelled one was never asked about and never uploaded, silently. Cancel is now a real answer: "Skip this one" skips one file, "Cancel all" abandons the rest.

How to check

Upload a.txt, b.txt, c.txt to a folder first, so they exist.

  1. The checkbox. Drag the same 3 files in again. Dialog says "3 left". Pick Keep both, tick "Do the same for the other 2 items", press Continue. All 3 resolve, no second prompt. You get a (1).txt, b (1).txt, c (1).txt.
  2. Cancel all. Drop them again, press "Cancel all". Every prompt goes, nothing uploads.
  3. Skip one. Drop them again, press "Skip this one", then answer the next two. Only 2 files upload, and the drop does not hang. On main this hangs.
  4. The setting. Settings → General → "When a file already exists" → Replace. Drop the 3 files. No dialog at all, and the card shows a "Replaced" notice reading "3 files ... were replaced".
  5. Default unchanged. Set it back to "Ask me" and confirm the prompt returns.

Note: verified by tests and typecheck, not in a browser.

…time

Ten files dropped onto ten that already exist raised ten identical questions,
each needing its own click, with nothing saying how many were left. The dialog
now offers to apply one answer to everything waiting, shows the count, and
distinguishes skipping this file from cancelling the whole drop.
The first attempt gated its new controls on more than one prompt being
queued, but prompts are raised one at a time: use-upload-dispatch awaits each
answer before the next question exists, so the queue never holds two and none
of it ever rendered. The answer is carried back to that loop instead, which
honours it by not asking again. Cancel now resolves too, rather than leaving
the loop waiting forever and stalling the whole drop.
General settings gains a "When a file already exists" choice of ask, keep
both, or replace, defaulting to ask. A policy seeds the same standing answer
the prompt's "do the same for the rest" sets, so a drop of ten collisions
finishes without a prompt. Replacing unasked leaves a notice saying how many
files were overwritten.
@vercel

vercel Bot commented Aug 29, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
opndrive Ready Ready Preview Aug 30, 2026 5:00pm
opndrive-docs Ready Ready Preview Aug 30, 2026 5:00pm

@Rakesh-46-VR
Rakesh-46-VR merged commit eb3c1ce into main Aug 30, 2026
7 of 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.

2 participants