-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't edit text files with external app #2952
Comments
I verified that the same problem is also present in version |
I tested it with 3.3.0 RC1 and amaze text editor:
This is done on a 8.x device with only internal storage |
@tobiasKaminsky Indeed it works with the Amaze text editor for some reason. I wonder how it's different from all other text editors I've tried (that works with Dropbox) I think this is still a problem, it should be agnostic to which text editor you are using. How many people will happen to have one of the magic text editors that works with Nextcloud? I would consider Quoda to be one of the most important popular free Android text editors, and nextcloud Android should behave properly so it can edit text files from NC. Could you try one of the text editors I linked to, to confirm other NC doesn't play well with them? |
I just tried Quoda on a BQ Aquarius X Pro with Android 8.1. Indeed, you cannot open text files with Quoda from within the NC app. But you can open the files stored under Android/media/com.nextcloud.client/... with Quoda's "open" dialog. Then you can edit and save them. Afterwards, you can use the "Sync" feature of NC client to upload the changes. Just a workaround, though. To add an editor to the list of working apps: |
@sehucke Thank you for confirming. I do not find my downloaded (available offline, is this what you mean with "downloaded"?) textfile in |
Imho, the wording of those features is a bit misleading. I remember there was a discussion about it between some Nextcloud devs some time ago. And then there is the "mark as available offline" ("Als Offline verfügbar markieren") feature. It automatically syncs remote and local changes to the file with your NC server. Imho the second feature should be renamed to "Keep in sync" or "Auto-sync with server". Now back to your permission problem: |
@sehucke NC is set to internal storage (there is not external on Oneplus 2). See NC settings: |
Hmm... Have you checked app permissions? I had #1285 in mind but it should be fixed since 3.0.0. |
Please check the permissions of the apps used to open files out of NC as well. Or it maybe a general problem with those specific apps when opening files stored within another app's media folder in Android 6. Have you tried this with Quoda and some other (sync) app? |
Yes e.g. Quoda has storage permissions Hmm there is obviously some difference between the combination NC + Quoda vs Dropbox + Quoda, as the latter works fine. Since the component Quoda is the common denominator, it must be that there is a difference between NC and Dropbox. From the Screenshot in my first post here, we see that when files from NC are opened, they are in the path However when I open a text file from Dropbox, the path is Assuming that the prefix Edit.I went in to NC settings and tried out the 2 other storage paths available, but I get the same error as before (here trying the SE Editor) |
Hmm... AFAIK, the first path option should be the place where you have the least problems to access files. It is the app's media folder that is also made available through the BTW: Which app did you use to explore the folder structure? Have you tried Total Commander? I think this topic needs some third-level support. Maybe @mario or @tobiasKaminsky can help you further... I am not a Android/Java developer so all I can do is speculate... :-| |
There are different ways to open a file from one app to another (e.g. open with app XY from within NC files app): XY can try to open the file directly, like you would do on a computer. This can fail depending on where the file is stored (in apps internal storage it is not readable; but on sdcard it is) XY can use a file:// uri. We are using the latter one as this is the most recent one. To test this, can please someone point me to an open source app where it does not work, so I can debug it? |
@sehucke I use Solid Explorer as my file manager, as it has integration with Dropbox, Samba, FTP etc. But this is unrelated to the issues reported if I'm not mistaken? :) @tobiasKaminsky Thank you for digging in! |
Ted seems to be very old and I cannot get it to run :-/ |
In your previous post you said that Nextcloud uses "content:// uri", so I assume that this is the same as "Content Provider" mentioned in the error message. Which ever other way Dropbox uses seems to be a better way, as it works with many more apps than the "content://" URI. Could we switch so that NC-android uses the better way? =) |
@erikw I was just wondering why you were not able to browse the downloaded Nextcloud files in the media folder. Thought of some issue special to your device that prohibits access to the files. But in the meantime the analysis points into a different direction.
I think this is not about "better" or "worse" (at least not only... :-) ). It is about the intended functionality. E.g. if one wants to explicitly permit a third party app to read/write files - or if you don't care and grant everyone access through choosing a publicly accessible storage space. Please correct me if I got this wrong @tobiasKaminsky (since I am not an Android expert for now): If you choose to store the files inside Nextcloud's internal storage the mechanism to open the files with write access could be different compared to storage paths like a world-writable media folder? (See https://stackoverflow.com/questions/30286920/android-external-app-cant-access-apps-files ) |
With upcoming version (and current dev version) this should be fixed/included, please test it and if there is something not working as expected, please re-open. |
@ all beware that this means the app you are using to edit a file (no matter what format) needs to support the document provider (like the Android files app where you need to choose your Nextcloud account), if you open the file straight from the file system thatn this won't work since you are actually bypassing the Nextcloud files app itself. One example for a text editor that does support this would be: https://play.google.com/store/apps/details?id=com.byteexperts.texteditor |
Great!! Thanks for for the work. I'll try this out when I upgrade |
Since Dropbox is effectively shutting down Linux support, I'm now one of the Dropbox2Nextcloud migrating users.
My main use case with Dropbox has been for years and years to view and edit
.txt
files on shared between my laptop and my mobile phone. Unfortunately this use case it not working for me with Nextcloud Android.Actual behavior
External text editors can't open or save a
.txt
file from Nextcloud. I've tried these following text editor which all works fine with editing text files from Dropbox with. See attached Screenshots at the end of this issue.Expected behavior
Opening
.txt
files with external text editor apps should work. It should be possible to open them for reading and editing. When saving from external app, Nextcloud should upload the changes (Like Dropbox works)Steps to reproduce
.txt
in Nextcloud android app which has content inside.Environment data
Android version: 6.0.1
Device model: Oneplus 2
Stock or customized system: Stock
Nextcloud app version: 3.2.3
Nextcloud server version: 13.0.5
Screenshots
The text was updated successfully, but these errors were encountered: