apache / apache/cordova-plugin-file

FileEntry - getFile error code 5 for files with : in filename on android

Open
#294 1 comment 0 reactions 0 assignees View on GitHub
bug platform: android
Dominant language
JavaScript
Stars
744
Forks
754
Avg merge
3d 4h
Merged PRs (30d)
1

Description

When calling getFile() we are getting an error if we want to open a file with a double point : in the name.

We tried:
```
var path = "sync/data/Wichtige Dokumente/Test:mehrseitiges PDF SO.pdf"
directoryEntry.getFile(path, {create: false}, ..);
```
or
```
var path = "sync%2Fdata%2FWichtige%20Dokumente%2FTest%3Amehrseitiges%20PDF%20SO.pdf";
directoryEntry.getFile getFile(path, {create: false}, ..);
```

but we always get the error code 5.
Any ideas?

Contributor guide

Open the contributing guide

Research direction

Start by reproducing FileEntry.getFile on Android with the reported path containing a colon, and inspect how that entry point handles the filename and error code 5. Done means a file whose name contains a colon can be opened successfully through getFile().

Written by the indexing model from the issue text.

Assessment

Tech stack
android, javascript
Domain
mobile-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.