You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the end of this description, a possible solution is proposed.
Symptoms
Describe the bug
The function Save as from any richdocuments editor does not work as intended on Alpine PHP containers. A copy of the file is saved, not with the input name, but in the format (#) with # a number that is not yet used in that folder. If saving is successful, the current file in the editor changes to the saved as file, but not with this bug.
To Reproduce
Steps to reproduce the behavior:
Edit a document
Click Save as under menu tab File
Enter a name of choice and press save
Be greeted by an error pop-up stating:
The document can't be saved to storage. Check your permissions or contact the storage server administrator.
Expected behavior
The file is saved as the name as input, and the editing of the program continues in this new saved as file.
Client details:
Problem occurs on multiple devices, in multiple browsers (Firefox on Ubuntu, Chromium on Ubuntu, Firefox on Windows 10, Chrome on Windows 10).
Server details
Operating system: Docker container fpm-alpine-production (currently alias for 22.2.3-fpm-alpine) Web server: Nginx Database: mariadb PHP version: 8.0 Nextcloud version: 22.2.3 Version of the richdocuments app: 4.2.3 Version of Collabora Online: 21.06.10.1
The Nextcloud Mail app also had an issue with limited iconv support, see nextcloud/mail#4351. Their solution was to avoid using these missing features. The missing features are part of the official PHP-FPM Alpine container upon which the official Nextcloud PHP-FPM Alpine container is based. This would arise from using musl (instead of glibc), and the limitations are well noted by the musl docs, which implies no intention to change this.
As a long-term solution, I propose switching from iconv to mb_convert_encoding, as it has the UTF-7 encoding (and more) support built-in, and mbstring is quite standard (and already used by Nextcloud Server). I will submit a PR shortly.
The text was updated successfully, but these errors were encountered:
Keessaus
added a commit
to Keessaus/richdocuments
that referenced
this issue
Jan 7, 2022
At the end of this description, a possible solution is proposed.
Symptoms
Describe the bug
The function
Save as
from any richdocuments editor does not work as intended on Alpine PHP containers. A copy of the file is saved, not with the input name, but in the format(#)
with#
a number that is not yet used in that folder. If saving is successful, the current file in the editor changes to the saved as file, but not with this bug.To Reproduce
Steps to reproduce the behavior:
Save as
under menu tabFile
Expected behavior
The file is saved as the name as input, and the editing of the program continues in this new saved as file.
Client details:
Problem occurs on multiple devices, in multiple browsers (Firefox on Ubuntu, Chromium on Ubuntu, Firefox on Windows 10, Chrome on Windows 10).
Server details
Operating system: Docker container
fpm-alpine-production
(currently alias for22.2.3-fpm-alpine
)Web server: Nginx
Database: mariadb
PHP version: 8.0
Nextcloud version: 22.2.3
Version of the richdocuments app: 4.2.3
Version of Collabora Online: 21.06.10.1
Logs
Nextcloud log (from
/settings/admin/logging
)Workaround and solution
After some tiring research, I found out
iconv
on my PHP-FPM Alpine container does not support the UTF-7 encoding in the Alpine PHP container.The Nextcloud Mail app also had an issue with limited
iconv
support, see nextcloud/mail#4351. Their solution was to avoid using these missing features. The missing features are part of the official PHP-FPM Alpine container upon which the official Nextcloud PHP-FPM Alpine container is based. This would arise from using musl (instead of glibc), and the limitations are well noted by the musl docs, which implies no intention to change this.The issue is also discussed in the docker-library/php project. A currently working workaround is proposed in docker-library/php#240 (comment).
As a long-term solution, I propose switching from
iconv
tomb_convert_encoding
, as it has the UTF-7 encoding (and more) support built-in, and mbstring is quite standard (and already used by Nextcloud Server). I will submit a PR shortly.The text was updated successfully, but these errors were encountered: