GNU bug report logs - #78948
[PATCH] Retain the <base> tag when making a page in EWW document readable

Previous Next

Package: emacs;

Reported by: Steven Allen <steven <at> stebalien.com>

Date: Wed, 2 Jul 2025 21:39:02 UTC

Severity: normal

Tags: patch

Done: Jim Porter <jporterbugs <at> gmail.com>

To reply to this bug, email your comments to 78948 AT debbugs.gnu.org.
There is no need to reopen the bug first.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to larsi <at> gnus.org, jporterbugs <at> gmail.com, bug-gnu-emacs <at> gnu.org:
bug#78948; Package emacs. (Wed, 02 Jul 2025 21:39:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Steven Allen <steven <at> stebalien.com>:
New bug report received and forwarded. Copy sent to larsi <at> gnus.org, jporterbugs <at> gmail.com, bug-gnu-emacs <at> gnu.org. (Wed, 02 Jul 2025 21:39:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Steven Allen <steven <at> stebalien.com>
To: bug-gnu-emacs <at> gnu.org
Subject: [PATCH] Retain the <base> tag when making a page in EWW document
 readable
Date: Wed, 02 Jul 2025 14:37:27 -0700
[Message part 1 (text/plain, inline)]
Tags: patch


Retain the <base> tag when making a page in EWW document
readable. Otherwise, relative links aren't resolved correctly.

In GNU Emacs 31.0.50 (build 1, x86_64-pc-linux-gnu, cairo version
 1.18.4) of 2025-07-02 built on Laptop
Repository revision: bf7d9f3c47ee59d45129d08490411e572a737db5
Repository branch: makepkg
Windowing system distributor 'The X.Org Foundation', version 11.0.12101018
System Description: Arch Linux

Configured using:
 'configure
 'CPPFLAGS=-I/run/user/1000/build/emacs-git/src/mps-git/build/include '
 'LDFLAGS=-L/run/user/1000/build/emacs-git/src/mps-git/build/lib -Wl,-O1
 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now
 -Wl,-z,pack-relative-relocs -flto=auto' --prefix=/usr --sysconfdir=/etc
 --libexecdir=/usr/lib --localstatedir=/var --mandir=/usr/share/man
 --with-gameuser=:games --with-modules --without-m17n-flt
 --without-selinux --without-pop --without-gconf --disable-gc-mark-trace
 --with-mps=yes --enable-link-time-optimization
 --with-native-compilation=yes --with-xinput2 --with-x-toolkit=no
 --without-toolkit-scroll-bars --without-xaw3d --without-gsettings
 --with-cairo-xcb --without-xft --with-sound=no --with-tree-sitter
 --without-gpm --without-compress-install
 '--program-transform-name=s/\([ec]tags\)/\1.emacs/'
 'CFLAGS=-march=native -mtune=native -O3 -pipe -fno-plt -fexceptions
 -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security
 -fstack-clash-protection -fcf-protection -fomit-frame-pointer
 -fno-math-errno -fno-trapping-math -fno-math-errno -fno-trapping-math
 -flto=auto''

[0001-Retain-the-base-tag-when-making-a-page-in-EWW-docume.patch (text/patch, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#78948; Package emacs. (Thu, 03 Jul 2025 03:50:03 GMT) Full text and rfc822 format available.

Message #8 received at 78948 <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Steven Allen <steven <at> stebalien.com>, 78948 <at> debbugs.gnu.org
Cc: Lars Magne Ingebrigtsen <larsi <at> gnus.org>
Subject: Re: bug#78948: [PATCH] Retain the <base> tag when making a page in
 EWW document readable
Date: Wed, 2 Jul 2025 20:49:18 -0700
On 7/2/2025 2:37 PM, Steven Allen via Bug reports for GNU Emacs, the 
Swiss army knife of text editors wrote:
> Retain the <base> tag when making a page in EWW document
> readable. Otherwise, relative links aren't resolved correctly.

This makes sense to me. Just one small question to be sure: this isn't a 
new regression, right? I know I merged a patch to this code recently, 
but I don't think the previous version was doing anything about <base> 
tags either...




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#78948; Package emacs. (Thu, 03 Jul 2025 04:04:02 GMT) Full text and rfc822 format available.

Message #11 received at 78948 <at> debbugs.gnu.org (full text, mbox):

From: Steven Allen <steven <at> stebalien.com>
To: Jim Porter <jporterbugs <at> gmail.com>, 78948 <at> debbugs.gnu.org
Cc: Lars Magne Ingebrigtsen <larsi <at> gnus.org>
Subject: Re: bug#78948: [PATCH] Retain the <base> tag when making a page in
 EWW document readable
Date: Wed, 02 Jul 2025 21:03:38 -0700
Jim Porter <jporterbugs <at> gmail.com> writes:

> On 7/2/2025 2:37 PM, Steven Allen via Bug reports for GNU Emacs, the 
> Swiss army knife of text editors wrote:
>> Retain the <base> tag when making a page in EWW document
>> readable. Otherwise, relative links aren't resolved correctly.
>
> This makes sense to me. Just one small question to be sure: this isn't a 
> new regression, right? I know I merged a patch to this code recently, 
> but I don't think the previous version was doing anything about <base> 
> tags either...

No, this isn't a new regression as far as I can tell.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#78948; Package emacs. (Thu, 03 Jul 2025 05:11:01 GMT) Full text and rfc822 format available.

Message #14 received at 78948 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Steven Allen <steven <at> stebalien.com>
Cc: jporterbugs <at> gmail.com, larsi <at> gnus.org, 78948 <at> debbugs.gnu.org
Subject: Re: bug#78948: [PATCH] Retain the <base> tag when making a page in EWW
 document readable
Date: Thu, 03 Jul 2025 08:10:14 +0300
> Cc: Lars Magne Ingebrigtsen <larsi <at> gnus.org>,
>  Jim Porter <jporterbugs <at> gmail.com>
> Date: Wed, 02 Jul 2025 14:37:27 -0700
> From:  Steven Allen via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> 
> Retain the <base> tag when making a page in EWW document
> readable. Otherwise, relative links aren't resolved correctly.

Thanks.  Could you please show a recipe for reproducing the problem?
Also, would it make sense to have a test for this?




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#78948; Package emacs. (Thu, 03 Jul 2025 15:19:03 GMT) Full text and rfc822 format available.

Message #17 received at 78948 <at> debbugs.gnu.org (full text, mbox):

From: Steven Allen <steven <at> stebalien.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: jporterbugs <at> gmail.com, larsi <at> gnus.org, 78948 <at> debbugs.gnu.org
Subject: Re: bug#78948: [PATCH] Retain the <base> tag when making a page in
 EWW document readable
Date: Thu, 03 Jul 2025 08:18:31 -0700
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> writes:

>> Cc: Lars Magne Ingebrigtsen <larsi <at> gnus.org>,
>>  Jim Porter <jporterbugs <at> gmail.com>
>> Date: Wed, 02 Jul 2025 14:37:27 -0700
>> From:  Steven Allen via "Bug reports for GNU Emacs,
>>  the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>>
>> Retain the <base> tag when making a page in EWW document
>> readable. Otherwise, relative links aren't resolved correctly.
>
> Thanks.  Could you please show a recipe for reproducing the problem?

1. Start emacs.
2. M-x eww RET https://stebalien.com/tags/emacs/ RET
3. R (readable mode)
4. Try to follow the top link and get a 404 error code.

> Also, would it make sense to have a test for this?

Good point, see attached.

[0001-Retain-the-base-tag-when-making-a-page-in-EWW-docume.patch (text/x-patch, attachment)]

Reply sent to Jim Porter <jporterbugs <at> gmail.com>:
You have taken responsibility. (Fri, 04 Jul 2025 04:06:01 GMT) Full text and rfc822 format available.

Notification sent to Steven Allen <steven <at> stebalien.com>:
bug acknowledged by developer. (Fri, 04 Jul 2025 04:06:02 GMT) Full text and rfc822 format available.

Message #22 received at 78948-done <at> debbugs.gnu.org (full text, mbox):

From: Jim Porter <jporterbugs <at> gmail.com>
To: Steven Allen <steven <at> stebalien.com>, Eli Zaretskii <eliz <at> gnu.org>
Cc: larsi <at> gnus.org, 78948-done <at> debbugs.gnu.org
Subject: Re: bug#78948: [PATCH] Retain the <base> tag when making a page in
 EWW document readable
Date: Thu, 3 Jul 2025 21:04:52 -0700
On 7/3/2025 8:18 AM, Steven Allen via Bug reports for GNU Emacs, the 
Swiss army knife of text editors wrote:
> Good point, see attached.

Thanks. This all looks good to me, so I've merged it to the master 
branch as f10bf71151b. (I hope... I got an error while pushing, but I 
think everything's in sync. I guess Savannah's under attack again.)




This bug report was last modified 1 day ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.