Bug#1122186: magit fails to start after trixie upgrade

2025-12-12 Thread Steve McIntyre
Hey Nicholas!

I think we've sussed the problem - see my other mail to the bug a
couple of minutes ago!

Cheers,

Steve

On Tue, Dec 09, 2025 at 11:10:23PM -0500, Nicholas D Steeves wrote:
>Hi Steve,
>
>Steve McIntyre  writes:
>
>> Package: elpa-magit
>> Version: 4.3.5-1+deb13u1
>> Severity: important
>>
>> Hi!
>>
>> After upgrading a machine to trixie locally, emacs seems to be working
>> fine. Using it to write this mail!
>>
>> But when I try to start magit using M-x magit-status, I get the
>> following error and no magit:
>>
>> slot-missing: Invalid slot name: "#> transient-option-1037fa0c2081>", :always-read
>
>I'm curious how to trigger this, because isn't completing-read the
>default, and isn't :always-read a user customisation (or file-local, or
>dir-locals)?  This suspicion is based off of a superficial search, btw.
>
>> In case it's my local config in .emacs etc. that might be causing this
>> problem, I've tested again with a new user with no customisations and
>> I still see the same issue.
>
>Was this a freshly-created user, (ie: empty $HOME except for the files
>copied from /etc/skel during user account creation) or had it ever run
>Emacs before?  The reason I ask is because a minority of users have been
>affected by one of several native-compilation-related bugs this upgrade
>cycle.  The test and workaround for the first class of these (Emacs
>doesn't invalidate the cache and recompile platform native code that
>needs to be recompiled) is this:
>
>  mv ~/.emacs.d/eln-cache ~/.emacs.d/possibly-broken-eln-cache
>
>and restart emacs.
>
>If that doesn't fix it, or if the problem comes back, then I worry this
>might be one of the not-fun-to-find-and-actually-fix bugs like #1036359
>(elpa-markdown-toc).  The tldr of that bug is that several packages
>appear to have interacted with native-compilation in a way that made
>elpa-markdown-toc crash, and it's not clear to me where the
>release-critical bug[s] actually were; however, it[they] now appear to
>have been transient.  The first step of exploring this hypothesis could
>be to get a list of packages that would be removed were you to uninstall
>elpa-transient.
>
>If you get tired of debugging and suspect a system state-related bug and
>wanted to purge (and then reinstall) and wanted to use an aggressive
>method, this should do the trick:
>
>  dpkg --get-selections | grep elpa.*install | wc -l  # Gets number of packages
>  elpa_packages=$(dpkg --get-selections | grep elpa.*install | awk '{print 
> $1}' | tr '\n' ' ')
>  apt purge "$elpa_packages"  # Needs further work if this doesn't equal
>  # number of packages from step 1, and I
>  # recommend aborting if there is no time to 
> investigate
>  apt install "$elpa_packages"
>  # One limitation of this method is that every package in the list will
>  # be marked as "manual" rather than "auto".
>
>Ideally it would be nice to gather some more data about the difficult to
>reproduce bugs, but if one of the heavy handed approaches (that
>shouldn't ever be necessary!) fixes the magit issue on your system, then
>I'm guessing that you'll consider it a good resolution.
>
>Cheers,
>Nicholas


-- 
Steve McIntyre, Cambridge, [email protected]
You raise the blade, you make the change... You re-arrange me 'til I'm sane...



Bug#1122186: magit fails to start after trixie upgrade

2025-12-09 Thread Nicholas D Steeves
Hi Steve,

Steve McIntyre  writes:

> Package: elpa-magit
> Version: 4.3.5-1+deb13u1
> Severity: important
>
> Hi!
>
> After upgrading a machine to trixie locally, emacs seems to be working
> fine. Using it to write this mail!
>
> But when I try to start magit using M-x magit-status, I get the
> following error and no magit:
>
> slot-missing: Invalid slot name: "# transient-option-1037fa0c2081>", :always-read

I'm curious how to trigger this, because isn't completing-read the
default, and isn't :always-read a user customisation (or file-local, or
dir-locals)?  This suspicion is based off of a superficial search, btw.

> In case it's my local config in .emacs etc. that might be causing this
> problem, I've tested again with a new user with no customisations and
> I still see the same issue.

Was this a freshly-created user, (ie: empty $HOME except for the files
copied from /etc/skel during user account creation) or had it ever run
Emacs before?  The reason I ask is because a minority of users have been
affected by one of several native-compilation-related bugs this upgrade
cycle.  The test and workaround for the first class of these (Emacs
doesn't invalidate the cache and recompile platform native code that
needs to be recompiled) is this:

  mv ~/.emacs.d/eln-cache ~/.emacs.d/possibly-broken-eln-cache

and restart emacs.

If that doesn't fix it, or if the problem comes back, then I worry this
might be one of the not-fun-to-find-and-actually-fix bugs like #1036359
(elpa-markdown-toc).  The tldr of that bug is that several packages
appear to have interacted with native-compilation in a way that made
elpa-markdown-toc crash, and it's not clear to me where the
release-critical bug[s] actually were; however, it[they] now appear to
have been transient.  The first step of exploring this hypothesis could
be to get a list of packages that would be removed were you to uninstall
elpa-transient.

If you get tired of debugging and suspect a system state-related bug and
wanted to purge (and then reinstall) and wanted to use an aggressive
method, this should do the trick:

  dpkg --get-selections | grep elpa.*install | wc -l  # Gets number of packages
  elpa_packages=$(dpkg --get-selections | grep elpa.*install | awk '{print $1}' 
| tr '\n' ' ')
  apt purge "$elpa_packages"  # Needs further work if this doesn't equal
  # number of packages from step 1, and I
  # recommend aborting if there is no time to 
investigate
  apt install "$elpa_packages"
  # One limitation of this method is that every package in the list will
  # be marked as "manual" rather than "auto".

Ideally it would be nice to gather some more data about the difficult to
reproduce bugs, but if one of the heavy handed approaches (that
shouldn't ever be necessary!) fixes the magit issue on your system, then
I'm guessing that you'll consider it a good resolution.

Cheers,
Nicholas


signature.asc
Description: PGP signature


Bug#1122186: magit fails to start after trixie upgrade

2025-12-09 Thread Xiyue Deng
Hi Steve,

Steve McIntyre  writes:

> On Tue, Dec 09, 2025 at 11:42:36AM +, Steve McIntyre wrote:
>>
>>Hmmm, OK. That works without errors.
>>

I just realized that the minimalist command I provided didn't load the
transient package, so it's using the transient bundled in Emacs instead.
Can you also try the following command that does that and see whether
you can reproduce the issue?

,[ Minialist command with trasient loaded ]
| emacs -Q --eval "(progn (add-to-list 'load-path 
\"/usr/share/emacs/site-lisp/elpa/magit-4.3.5\") (add-to-list 'load-path 
\"/usr/share/emacs/site-lisp/elpa/llama-0.6.2\") (add-to-list 'load-path 
\"/usr/share/emacs/site-lisp/elpa/magit-section-4.3.5\") (add-to-list 
'load-path \"/usr/share/emacs/site-lisp/elpa/with-editor-3.4.3\") (add-to-list 
'load-path \"/usr/share/emacs/site-lisp/elpa/transient-0.8.8\") (require 
'magit))"
`

This should help determine whether anything related to the
transient-0.8.8 installation is causing issues.

>>I'll dig a little more.
>
> No joy at all :-(
>
> For now I've gone back to elpa-magit from bookworm so I can continue
> working. Happy to help with debugging if you can suggest anything more
> to try; I'm really not an elisp hacker and I'm out of my depth.
>

Another thing to try is to check whether you have any residual transient
installation lingering around under `/usr/share/emacs/site-lisp/elpa',
like `transient-0.3.7' from bookworm.  If so, can you remove it and
retry?

In that spirit, you can also try to remove the native compilation files
and regenerate them to see if that helps (they will regenerate next time
you launch Emacs after removal), which is usually named `eln-cache' and
located under the Emacs configuration directory (~/.config/emacs or
~/.emacs.d).

Also I would suggest to add `(setq load-prefer-newer t)' to your init.el
if you haven't done so, which should avoid most of the cache related
issues.

> -- 
> Steve McIntyre, Cambridge, [email protected]
> Google-bait:   https://www.debian.org/CD/free-linux-cd
>   Debian does NOT ship free CDs. Please do NOT contact the mailing
>   lists asking us to send them to you.
>

-- 
Regards,
Xiyue Deng


signature.asc
Description: PGP signature


Bug#1122186: magit fails to start after trixie upgrade

2025-12-09 Thread Steve McIntyre
On Tue, Dec 09, 2025 at 11:42:36AM +, Steve McIntyre wrote:
>
>Hmmm, OK. That works without errors.
>
>I'll dig a little more.

No joy at all :-(

For now I've gone back to elpa-magit from bookworm so I can continue
working. Happy to help with debugging if you can suggest anything more
to try; I'm really not an elisp hacker and I'm out of my depth.

-- 
Steve McIntyre, Cambridge, [email protected]
Google-bait:   https://www.debian.org/CD/free-linux-cd
  Debian does NOT ship free CDs. Please do NOT contact the mailing
  lists asking us to send them to you.



Bug#1122186: magit fails to start after trixie upgrade

2025-12-09 Thread Steve McIntyre
Hi!

On Mon, Dec 08, 2025 at 05:14:41PM -0800, Xiyue Deng wrote:
>Steve McIntyre  writes:
>
>> Package: elpa-magit
>> Version: 4.3.5-1+deb13u1
>> Severity: important
>>
>> Hi!
>>
>> After upgrading a machine to trixie locally, emacs seems to be working
>> fine. Using it to write this mail!
>>
>> But when I try to start magit using M-x magit-status, I get the
>> following error and no magit:
>>
>> slot-missing: Invalid slot name: "#> transient-option-1037fa0c2081>", :always-read
>>
>> In case it's my local config in .emacs etc. that might be causing this
>> problem, I've tested again with a new user with no customisations and
>> I still see the same issue.
>>
>> Help please!
>>
>
>I cannot seem to reproduce this on my Trixie machine even with minimal
>settings.
>
>Can you try to run with `emacs -Q' and only load the required addons (as
>in the following command) to see whether it's reproducible this way?
>
>,[ Minimal command to run magit on Trixie ]
>| emacs -Q --eval "(progn (add-to-list 'load-path 
>\"/usr/share/emacs/site-lisp/elpa/magit-4.3.5\") (add-to-list 'load-path 
>\"/usr/share/emacs/site-lisp/elpa/llama-0.6.2\") (add-to-list 'load-path 
>\"/usr/share/emacs/site-lisp/elpa/magit-section-4.3.5\") (add-to-list 
>'load-path \"/usr/share/emacs/site-lisp/elpa/with-editor-3.4.3\") (require 
>'magit))"
>`

Hmmm, OK. That works without errors.

I'll dig a little more.

-- 
Steve McIntyre, Cambridge, [email protected]
"... the premise [is] that privacy is about hiding a wrong. It's not.
 Privacy is an inherent human right, and a requirement for maintaining
 the human condition with dignity and respect."
  -- Bruce Schneier



Processed: Re: Bug#1122186: magit fails to start after trixie upgrade

2025-12-08 Thread Debian Bug Tracking System
Processing control commands:

> tags -1 moreinfo
Bug #1122186 [elpa-magit] magit fails to start after trixie upgrade
Added tag(s) moreinfo.

-- 
1122186: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1122186
Debian Bug Tracking System
Contact [email protected] with problems



Processed: Re: Bug#1122186: magit fails to start after trixie upgrade

2025-12-08 Thread Debian Bug Tracking System
Processing control commands:

> tags -1 moreinfo
Bug #1122186 [elpa-magit] magit fails to start after trixie upgrade
Ignoring request to alter tags of bug #1122186 to the same tags previously set

-- 
1122186: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1122186
Debian Bug Tracking System
Contact [email protected] with problems



Bug#1122186: magit fails to start after trixie upgrade

2025-12-08 Thread Xiyue Deng
Control: tags -1 moreinfo

Hi Steve,

Steve McIntyre  writes:

> Package: elpa-magit
> Version: 4.3.5-1+deb13u1
> Severity: important
>
> Hi!
>
> After upgrading a machine to trixie locally, emacs seems to be working
> fine. Using it to write this mail!
>
> But when I try to start magit using M-x magit-status, I get the
> following error and no magit:
>
> slot-missing: Invalid slot name: "# transient-option-1037fa0c2081>", :always-read
>
> In case it's my local config in .emacs etc. that might be causing this
> problem, I've tested again with a new user with no customisations and
> I still see the same issue.
>
> Help please!
>

I cannot seem to reproduce this on my Trixie machine even with minimal
settings.

Can you try to run with `emacs -Q' and only load the required addons (as
in the following command) to see whether it's reproducible this way?

,[ Minimal command to run magit on Trixie ]
| emacs -Q --eval "(progn (add-to-list 'load-path 
\"/usr/share/emacs/site-lisp/elpa/magit-4.3.5\") (add-to-list 'load-path 
\"/usr/share/emacs/site-lisp/elpa/llama-0.6.2\") (add-to-list 'load-path 
\"/usr/share/emacs/site-lisp/elpa/magit-section-4.3.5\") (add-to-list 
'load-path \"/usr/share/emacs/site-lisp/elpa/with-editor-3.4.3\") (require 
'magit))"
`

> -- System Information:
> Debian Release: 13.2
>   APT prefers stable-updates
>   APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 
> 'stable')
> Architecture: amd64 (x86_64)
> Foreign Architectures: i386
>
> Kernel: Linux 6.12.57+deb13-amd64 (SMP w/12 CPU threads; PREEMPT)
> Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), 
> LANGUAGE=en_GB:en
> Shell: /bin/sh linked to /usr/bin/dash
> Init: systemd (via /run/systemd/system)
> LSM: AppArmor: enabled
>
> Versions of packages elpa-magit depends on:
> ii  dh-elpa-helper 2.1.9
> ii  elpa-llama 0.6.2-1
> ii  elpa-magit-section 4.3.5-1+deb13u1
> ii  elpa-transient 0.8.8-1
> ii  elpa-with-editor   3.4.3-1
> ii  emacs  1:30.1+1-6
> ii  emacs-common [elpa-transient]  1:30.1+1-6
> ii  emacs-lucid [emacs]1:30.1+1-6
> ii  emacsen-common 3.0.8
> ii  git1:2.47.3-0+deb13u1
>
> elpa-magit recommends no packages.
>
> elpa-magit suggests no packages.
>
> -- no debconf information
>

-- 
Regards,
Xiyue Deng


signature.asc
Description: PGP signature


Bug#1122186: magit fails to start after trixie upgrade

2025-12-08 Thread Steve McIntyre
Package: elpa-magit
Version: 4.3.5-1+deb13u1
Severity: important

Hi!

After upgrading a machine to trixie locally, emacs seems to be working
fine. Using it to write this mail!

But when I try to start magit using M-x magit-status, I get the
following error and no magit:

slot-missing: Invalid slot name: "#", :always-read

In case it's my local config in .emacs etc. that might be causing this
problem, I've tested again with a new user with no customisations and
I still see the same issue.

Help please!

-- System Information:
Debian Release: 13.2
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.12.57+deb13-amd64 (SMP w/12 CPU threads; PREEMPT)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_GB:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages elpa-magit depends on:
ii  dh-elpa-helper 2.1.9
ii  elpa-llama 0.6.2-1
ii  elpa-magit-section 4.3.5-1+deb13u1
ii  elpa-transient 0.8.8-1
ii  elpa-with-editor   3.4.3-1
ii  emacs  1:30.1+1-6
ii  emacs-common [elpa-transient]  1:30.1+1-6
ii  emacs-lucid [emacs]1:30.1+1-6
ii  emacsen-common 3.0.8
ii  git1:2.47.3-0+deb13u1

elpa-magit recommends no packages.

elpa-magit suggests no packages.

-- no debconf information