This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1296692 - Idea: symlink /usr/share/zsh/OLDVERSION to /usr/share/zsh/NEWVERSION
Idea: symlink /usr/share/zsh/OLDVERSION to /usr/share/zsh/NEWVERSION
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: zsh (Show other bugs)
24
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: James Antill
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-01-07 16:12 EST by Jason Tibbitts
Modified: 2016-03-24 13:20 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-03-24 05:21:29 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jason Tibbitts 2016-01-07 16:12:18 EST
When zsh is upgraded, existing shells have trouble because their FPATH refers to a directory which doesn't exist, and many functions are missing.  This could be alleviated by simply dropping in a symlink from, say, /usr/share/zsh/5.1.1 to /usr/share/share/zsh/5.2.  Yes, the new code might not be compatible, or might introduce bugs, but I think this would be rare enough that it would be the lesser of two evils.

Unfortunately replacing a directory with a symlink is not particularly pleasant, but there are some not terribly difficult fixes in https://fedoraproject.org/wiki/Packaging:Directory_Replacement

Anyway, I will be happy to implement this if the zsh package maintainers think it's a good idea.
Comment 1 Kamil Dudka 2016-01-07 16:29:50 EST
What would be the benefit of installing versioned directories at all if they were symlinked with each other?
Comment 2 Jason Tibbitts 2016-01-07 16:31:30 EST
I have no idea what the benefit is.  I suppose it's an upstream convention which we simply follow in the case that they want multiple versions installed in parallel.  I don't think it gets us anything besides the annoying "shell is broken" issues when an update is pushed.
Comment 3 Kamil Dudka 2016-01-07 16:39:33 EST
If we agreed that versioned directories are not useful for us, would not it be easier to just rename the directory such that it does not contain the version?
Comment 4 Jason Tibbitts 2016-01-07 18:04:37 EST
Perhaps; I don't know if that requires patching the source, and then whether the maintenance overhead is worth it.  It seems to add the versioned directory to $fpath automatically.

Alternately, we could keep the versioned directory but also add a symlink for the major (or major.minor) version and use that in fpath so that most upgrades aren't so disruptive.

For a random data point, MacOS homebrew doesn't use the versioned directory, and INSTALL actually says it's fine to not using the versioned directory if only one version of zsh is installed at a time.

But people on #zsh are openly hostile to even talking about it, so maybe it's not a good idea.  Plus there is the issue of the dlopened files in /usr/%libdir/zsh/.  So, maybe it isn't worth considering and I should probably just close this as a pointless waste of the reader's time.
Comment 5 Kamil Dudka 2016-01-08 13:04:35 EST
In my opinion, a proper solution to the above issues is to avoid updating zsh to a newer upstream version in already released versions of Fedora.  Actually, this has not happened since zsh-5.0.8.

If someone updates Fedora Rawhide, or upgrades Fedora to a newer release, such intermittent problems in already running sessions of zsh are IMO expected (and in many cases unavoidable).
Comment 6 Jan Kurik 2016-02-24 09:14:44 EST
This bug appears to have been reported against 'rawhide' during the Fedora 24 development cycle.
Changing version to '24'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora24#Rawhide_Rebase
Comment 7 Kamil Dudka 2016-03-24 05:21:29 EDT
The directories are versioned for a reason.  It makes no sense to symlink them with each other.
Comment 8 Jason Tibbitts 2016-03-24 13:20:27 EDT
Yes this is 100% true, and I should have closed the bug ages ago.

In case someone happens to come upon this while searchintg, all of you have to do anyway is type "exec zsh".

Note You need to log in before you can comment on or make changes to this bug.