Skip to content

Include .yml and .markdown in Drive import file picker#9400

Merged
bnavetta merged 2 commits intowarpdotdev:masterfrom
anshul-garg27:fix/file-picker-extension-lists
Apr 30, 2026
Merged

Include .yml and .markdown in Drive import file picker#9400
bnavetta merged 2 commits intowarpdotdev:masterfrom
anshul-garg27:fix/file-picker-extension-lists

Conversation

@anshul-garg27
Copy link
Copy Markdown
Contributor

Description

The Warp Drive import flow lets users pick workflow (YAML) and notebook (Markdown) files. The picker uses FileType::Yaml and FileType::Markdown from warpui_core::platform::file_picker, which previously listed only yaml and md. That doesn't match what the importer is willing to ingest:

The result: a user can drag-and-drop a .yml workflow or .markdown notebook and it imports cleanly, but the file picker filter hides those same files when they click "Choose files…". This change brings the picker in line with what the rest of the import path already accepts.

I left FileType::Image alone — that one has a separate user-facing contract (the theme creator body explicitly says "(.png, .jpg)"), so broadening it would need its own design decision.

Testing

  • Added two unit tests covering both extensions for FileType::Yaml and FileType::Markdown.
  • cargo fmt -p warpui_core -- --check
  • Couldn't run the full cargo nextest locally (Metal toolchain not available on this machine), the change is well-scoped to a const-array literal so risk is low.

Server API

No server changes.

Agent Mode

Not applicable.

Changelog Entries

  • Warp Drive import file picker now lists .yml and .markdown files in addition to .yaml and .md.

The Warp Drive import file picker filters by `FileType::Yaml` and
`FileType::Markdown`, but only the canonical extensions were listed
(`yaml`, `md`). The import flow itself accepts the alternate forms:

- `app/src/drive/import/nodes.rs` treats both `.yaml` and `.yml` as
  workflow files.
- `is_markdown_file` (warp_util) recognizes both `.md` and `.markdown`
  as notebook files.
- The import modal's helper text already advertises "md, yaml, yml".

So a user can drag-and-drop a `.yml` workflow or a `.markdown`
notebook and it imports fine, but the picker hides those files. Aligning
the picker filter with what the importer accepts.
@cla-bot cla-bot Bot added the cla-signed label Apr 29, 2026
@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented Apr 29, 2026

@anshul-garg27

I'm starting a first review of this pull request.

You can view the conversation on Warp.

I approved this pull request. No matching stakeholder was found for the changed files, so no human reviewers were requested.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

This PR expands the Drive import file picker extension filters so YAML accepts .yaml/.yml and Markdown accepts .md/.markdown, aligning picker behavior with the importer and adding focused unit coverage.

Concerns

  • No blocking correctness, security, or maintainability concerns found in the changed lines.

Verdict

Found: 0 critical, 0 important, 0 suggestions

Approve

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

@alokedesai alokedesai requested a review from bnavetta April 29, 2026 17:09
}

#[cfg(test)]
mod tests {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Per repo conventions, could you put this in a file_picker_tests.rs file alongside this one? You can then use a #[path] attribute to add that file as the test module.

@bnavetta
Copy link
Copy Markdown
Contributor

Left a comment on test structure, but the core change looks good!

@cla-bot
Copy link
Copy Markdown

cla-bot Bot commented Apr 30, 2026

Thank you for your pull request and welcome to our community. We could not parse the GitHub identity of the following contributors: Anshul Garg.
This is most likely caused by a git client misconfiguration; please make sure to:

  1. check if your git client is configured with an email to sign commits git config --list | grep email
  2. If not, set it up using git config --global user.email email@example.com
  3. Make sure that the git commit email is configured in your GitHub account settings, see https://github.com/settings/emails

@cla-bot cla-bot Bot removed the cla-signed label Apr 30, 2026
@anshul-garg27
Copy link
Copy Markdown
Contributor Author

@bnavetta thanks! Moved the tests to file_picker_tests.rs and wired it up via #[cfg(test)] #[path = "file_picker_tests.rs"] mod tests; to match the convention used in clipboard_utils, presenter, etc.

@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented Apr 30, 2026

@anshul-garg27

I'm checking this implementation PR for association with a likely matching ready issue.

Powered by Oz

@anshul-garg27 anshul-garg27 force-pushed the fix/file-picker-extension-lists branch from e969c17 to 0a5f74c Compare April 30, 2026 06:16
@cla-bot cla-bot Bot added the cla-signed label Apr 30, 2026
@anshul-garg27 anshul-garg27 requested a review from bnavetta April 30, 2026 06:49
@bnavetta bnavetta merged commit c61ad5b into warpdotdev:master Apr 30, 2026
26 checks passed
@captainsafia captainsafia added the external-contributor Indicates that a PR has been opened by someone outside the Warp team. label Apr 30, 2026 — with Warp Dev Github Integration
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed external-contributor Indicates that a PR has been opened by someone outside the Warp team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants