Skip to content
This repository was archived by the owner on Mar 24, 2025. It is now read-only.
This repository was archived by the owner on Mar 24, 2025. It is now read-only.

Crashes when trying to copy files with question marks in the name. #48

@JonathanH-UK

Description

@JonathanH-UK

I get the following crash and terminal output. For me, I have just renamed the file so that it doesn't include the funky Spanish upside-down question mark nor the closing question mark and now it works fine... Not sure if this is the scritp failing to escape the special character(s) or a limitation of adb...

adb: error: failed to copy '/home/jonathan/Personal/Music/Trumpet_Stuff/Books//Latin_Band/11 - Sway (¿Quién Será?) - Demo.mp3' to '/storage/3666-6130/Music/Trumpet//Latin_Band/11 - Sway (¿Quién Será?) - Demo.mp3': remote couldn't create file: Invalid argument
/home/jonathan/Personal/Music/Trumpet_Stuff/Books//Latin_Band/11 - Sway (¿Quién Será?) - Demo.mp3: 0 files pushed. 28.0 MB/s (65536 bytes in 0.002s)
INFO:root:Interrupted-Push-Delete: b'/storage/3666-6130/Music/Trumpet//Latin_Band/11 - Sway (\xc2\xbfQui\xc3\xa9n Ser\xc3\xa1?) - Demo.mp3'
rm: /storage/3666-6130/Music/Trumpet//Latin_Band/11 - Sway (¿Quién Será?) - Demo.mp3: No such file or directory
INFO:root:Total: 19375 KB/s (444203239 bytes in 22.388s)
Traceback (most recent call last):
  File "./adb-sync", line 638, in PerformCopies
    self.copy[i](src_name, dst_name)
  File "./adb-sync", line 331, in Push
    raise OSError('push failed')
OSError: push failed

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "./adb-sync", line 883, in <module>
    main()
  File "./adb-sync", line 877, in main
    syncer.PerformCopies()
  File "./adb-sync", line 640, in PerformCopies
    self.num_bytes += s.st_size
  File "./adb-sync", line 465, in __exit__
    self.fs.unlink(self.name)
  File "./adb-sync", line 286, in unlink
    raise OSError('unlink failed')
OSError: unlink failed

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions