Skip to content
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

[Bug]: Inserting URL into MD-file leads to every underscore '_' gets encoded with '\' #2276

Closed
5 of 8 tasks
bvn13 opened this issue Apr 5, 2022 · 3 comments · Fixed by #2681 or #2680
Closed
5 of 8 tasks

[Bug]: Inserting URL into MD-file leads to every underscore '_' gets encoded with '\' #2276

bvn13 opened this issue Apr 5, 2022 · 3 comments · Fixed by #2681 or #2680

Comments

@bvn13
Copy link

bvn13 commented Apr 5, 2022

⚠️ This issue respects the following points: ⚠️

  • This is a bug, not a question or a configuration/webserver/proxy issue.
  • This issue is not already reported on Github (I've searched it).
  • Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
  • I agree to follow Nextcloud's Code of Conduct.

Bug description

Nextcloud from Docker: nextcloud:23.0.3-apache

When I insert (from clipboard) such URL

https://www.avito.ru/krasnodar/remont_i_stroitelstvo/doska_pola_sosna_36x110135_ab_2385730370

it turns out into

https://www.avito.ru/krasnodar/remont\_i\_stroitelstvo/doska\_pola\_sosna\_36x110135\_ab\_2385730370

It becomes broken.

Steps to reproduce

look at description

Expected behavior

URL is not broken

Installation method

Official Docker image

Operating system

Debian/Ubuntu

PHP engine version

PHP 7.3

Web server

Apache (supported)

Database engine version

PostgreSQL

Is this bug present after an update or on a fresh install?

Fresh Nextcloud Server install

Are you using the Nextcloud Server Encryption module?

Encryption is Disabled

What user-backends are you using?

  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other

Configuration report

No response

List of activated Apps

Enabled:
  - accessibility: 1.9.0
  - activity: 2.15.0
  - admin_audit: 1.13.0
  - analytics: 4.2.1
  - appointments: 1.12.2
  - bookmarks: 10.2.1
  - bruteforcesettings: 2.3.0
  - calendar: 3.2.2
  - circles: 23.1.0
  - cloud_federation_api: 1.6.0
  - collectives: 0.22.22
  - comments: 1.13.0
  - contacts: 4.1.0
  - contactsinteraction: 1.4.0
  - dashboard: 7.3.0
  - dav: 1.21.0
  - deck: 1.6.1
  - drawio: 1.0.2
  - encryption: 2.11.0
  - epubreader: 1.4.7
  - event_update_notification: 1.4.0
  - federatedfilesharing: 1.13.0
  - federation: 1.13.0
  - files: 1.18.0
  - files_accesscontrol: 1.13.0
  - files_bpm: 0.2.1
  - files_downloadactivity: 1.12.0
  - files_external: 1.15.0
  - files_markdown: 2.3.5
  - files_mindmap: 0.0.26
  - files_pdfviewer: 2.4.0
  - files_rightclick: 1.2.0
  - files_sharing: 1.15.0
  - files_trashbin: 1.13.0
  - files_versions: 1.16.0
  - files_videoplayer: 1.12.0
  - firstrunwizard: 2.12.0
  - forms: 2.4.0
  - fulltextsearch: 23.0.0
  - logreader: 2.8.0
  - lookup_server_connector: 1.11.0
  - mail: 1.11.7
  - nextcloud_announcements: 1.12.0
  - notes: 4.3.1
  - notifications: 2.11.1
  - oauth2: 1.11.0
  - onlyoffice: 7.3.2
  - password_policy: 1.13.0
  - photos: 1.5.0
  - polls: 3.5.4
  - privacy: 1.7.0
  - provisioning_api: 1.13.0
  - recommendations: 1.2.0
  - serverinfo: 1.13.0
  - settings: 1.5.0
  - sharebymail: 1.13.0
  - spreed: 13.0.4
  - support: 1.6.0
  - survey_client: 1.11.0
  - systemtags: 1.13.0
  - tables: 0.1.0
  - text: 3.4.1
  - theming: 1.14.0
  - twofactor_backupcodes: 1.12.0
  - updatenotification: 1.13.0
  - user_status: 1.3.1
  - viewer: 1.7.0
  - weather_status: 1.3.0
  - webhooks: 0.1.0
  - workflowengine: 2.5.0
Disabled:
  - user_ldap: 1.13.1

Nextcloud Signing status

No response

Nextcloud Logs

No response

Additional info

No response

@bvn13 bvn13 added 0. Needs triage bug Something isn't working labels Apr 5, 2022
@szaimen szaimen transferred this issue from nextcloud/server Apr 5, 2022
@susnux
Copy link
Contributor

susnux commented Jun 22, 2022

This is related to ProseMirror/prosemirror-markdown#65

The issue consists of two parts:

  1. URLs in general (Image and Link), this was fixed with Avoid escaping underscores within words ProseMirror/prosemirror-markdown#67
    So this behavior is fixed with prosemirror-markdown >= 1.6.2
    => Fixed for Nextcloud >= 23.0.6 and 24.0.0
  2. Autolinks, for autolinks (simply insert from clipboard or links with same target as the link text) this is still a problem, I submitted a patch upstream: Ensure the URL part of links is not escaped ProseMirror/prosemirror-markdown#71

@mejo-
Copy link
Member

mejo- commented Jun 23, 2022

Awesome, thanks a lot for looking into it @susnux! Your fix already got merged into prosemirror-markdown, so this will be fixed after we upgraded to the upcoming next release of prosemirror-markdown 🎉

@susnux
Copy link
Contributor

susnux commented Jul 4, 2022

1.9.2 is released (including this fix), waiting for the dependabot 😉

mejo- added a commit that referenced this issue Jul 6, 2022
Fixes: #931
Fixes: #2276
Fixes: #2480

Thanks a lot to Ferdinand Thiessen for bug triaging and fixing <3

Signed-off-by: Jonas <jonas@freesources.org>
mejo- added a commit that referenced this issue Jul 6, 2022
Fixes: #931
Fixes: #2276
Fixes: #2480

Thanks a lot to Ferdinand Thiessen for bug triaging and fixing <3

Signed-off-by: Jonas <jonas@freesources.org>
@susnux susnux linked a pull request Jul 6, 2022 that will close this issue
nextcloud-command pushed a commit that referenced this issue Jul 6, 2022
Fixes: #931
Fixes: #2276
Fixes: #2480

Thanks a lot to Ferdinand Thiessen for bug triaging and fixing <3

Signed-off-by: Jonas <jonas@freesources.org>
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants