Skip to content

fix(cli): garbled filenames in ov add-resource #1018

@xaotag

Description

@xaotag

Describe the bug

When using to add directories containing files with non-UTF-8 filenames (Chinese, special symbols), the filenames become garbled after upload, and displays corrupted characters like .

Reproduction steps

  1. Create a directory with special/non-ASCII filenames
  2. Run
  3. View with
  4. See garbled characters

Expected behavior

Filenames should be displayed correctly without corruption.

Desktop/Environment

  • OpenViking Version:
  • Rust CLI Version:
  • OS: Linux/macOS/Windows

Root cause & fix

Found in line 61:

Using silently replaces invalid UTF-8 characters, causing corruption. Fixed by replacing with strict UTF-8 validation:

Additional context

This breaks compatibility with filesystems using non-UTF-8 encodings and causes garbled display of internationalized filenames.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions