Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
broken by the FPATH environment variable defined by bash / lmod
- X-seq: zsh-workers 55092
- From: Vincent Lefevre <vincent@xxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: broken by the FPATH environment variable defined by bash / lmod
- Date: Mon, 17 Aug 2026 15:17:11 +0200
- Archived-at: <https://zsh.org/workers/55092>
- List-id: <zsh-workers.zsh.org>
- Mail-followup-to: zsh-workers@xxxxxxx
FYI, I've just reported the following bug:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1144635
Package: zsh
Version: 5.9-8+b23
Severity: serious
Tags: upstream
On a machine that has just been upgraded to trixie, I start zsh
via a bash login shell (run by sshd). The issue is that when it
is a login shell, bash defines the $FPATH environement variable
to '/usr/share/lmod/lmod/init/ksh_funcs' as shown by
echo "FPATH = '$FPATH'" >&2
at the beginning of the ~/.bash_profile file, which outputs:
FPATH = '/usr/share/lmod/lmod/init/ksh_funcs'
This is possibly due to /usr/share/lmod/8.7.60/init/bash from the
lmod package, as mentioned at
https://github.com/direnv/direnv/issues/858
(note that I'm not a direnv user... this was found by Google + AI).
Such a setting completely breaks zsh, which outputs
zsh:1: url-quote-magic: function definition file not found
each time I type a key (the key has no other effect, i.e. the
command line at the prompt remains empty, so I need to type Ctrl-D
to quit zsh).
It appears that instead of ignoring the $FPATH environment variable
on startup, zsh sets $fpath to $FPATH.
Note that the zshparam(1) man page says: "Some environment variables
are not imported for reasons of security or because they would
interfere with the correct operation of other shell features.",
which should be the case here.
--
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / Pascaline project (LIP, ENS-Lyon)
Messages sorted by:
Reverse Date,
Date,
Thread,
Author