From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: Bug: HTTP links that contain %20 get malformed to %2520 - affects ODT export [9.2.1 (9.2.1-dist @ /home/ehere/emacs-scripts/org-9.2.1/lisp/)] Date: Fri, 01 Mar 2019 18:06:07 +0100 Message-ID: <878sxyo77k.fsf@nicolasgoaziou.fr> References: <20190222043318.47t3kkpsa5kva2rp@as-4028.astro.su.se> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([209.51.188.92]:42131) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gzlc2-0004bQ-DN for emacs-orgmode@gnu.org; Fri, 01 Mar 2019 12:06:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gzlc0-0002D1-Dl for emacs-orgmode@gnu.org; Fri, 01 Mar 2019 12:06:18 -0500 Received: from relay5-d.mail.gandi.net ([217.70.183.197]:37565) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gzlc0-00025d-4w for emacs-orgmode@gnu.org; Fri, 01 Mar 2019 12:06:16 -0500 In-Reply-To: <20190222043318.47t3kkpsa5kva2rp@as-4028.astro.su.se> (Edmund Christian Herenz's message of "Fri, 22 Feb 2019 13:33:18 +0900") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Edmund Christian Herenz Cc: emacs-orgmode@gnu.org Hello, Edmund Christian Herenz writes: > Consider the following HTTP link: > http://skyserver.sdss.org/dr14/en/tools/quicklook/summary.aspx?ra=11%2054%2048.85&dec=+24%2043%2033.0 > > I have this link in the kill-ring, mark 'some text' in an org-mode buffer > and run org-insert-link (C-c C-l). Then I yank the link (C-y) in the > minibuffer, and hit enter twice (since the marked text is what I want > for the description). > > Now, this is what I get in the org-mode buffer: > [[http://skyserver.sdss.org/dr14/en/tools/quicklook/summary.aspx?ra=11%252054%252048.85&dec=+24%252043%252033.0][some text]] > > As you can see the %20 gets encoded again to %2520. %25 is the % sign > defined in RFC 3986. I think we run into the problem that is mentioned > in this RFC in Sect 2.4 https://tools.ietf.org/html/rfc3986 - > i.e. encoding an decoding the % sign in URIs when it is not required, as > the URI is already formed. It is not an issue per se. For historical reasons, Org needs to escape % characters, and uses percent encoding to do so. So you have two layers of percent encoding. > > Th expected behavoiour would be that the link gets inserted as is. It does not work that way at the moment. However, that might change in a next release. This is being discussed at the moment in this ML. > However, when exporting to ODT, no such decoding happens - and I got > malformed URL (i.e. with %2520 instead of %20) in my ODT document. This should now be fixed. Thank you. Regards, -- Nicolas Goaziou