Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#56911 - [paintown] Cannot exec from the fish shell

Attached to Project: Community Packages
Opened by Ramiro Magno (rmagno) - Sunday, 31 December 2017, 01:23 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Friday, 16 March 2018, 06:59 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Sven-Hendrik Haase (Svenstaro)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:Cannot exec paintown from the fish shell, it will however from bash.


Additional info:
* package version: 3.6.0-3


Steps to reproduce:

1. Login to a fish shell
2. Run paintown: $ paintown

You will get this error:

Failed to execute process '/usr/bin/paintown'. Reason:
exec: Exec format error
The file '/usr/bin/paintown' is marked as an executable but could not be run by the operating system.
This task depends upon

Closed by  Sven-Hendrik Haase (Svenstaro)
Friday, 16 March 2018, 06:59 GMT
Reason for closing:  Won't fix
Comment by Eli Schwartz (eschwartz) - Sunday, 31 December 2017, 02:58 GMT
  • Field changed: Summary (Cannot exec paintown from the fish shell → [paintown] Cannot exec from the fish shell)
  • Field changed: Status (Unconfirmed → Assigned)
  • Field changed: Category (Packages → Upstream Bugs)
  • Field changed: Architecture (x86_64 → All)
  • Task assigned to Sven-Hendrik Haase (Svenstaro)
This happens for two reasons.

1) Fish is a sucky shell that sucks

2) Upstream does not include a shebang in their wrapper script launcher, and while every shell in the world will invoke executable files that have no shebang and for which the kernel returns ENOEXEC, using either the current shell or the /bin/sh interpreter. Even the higher-level wrapper library functions from the execve(2) family will do this. (e.g. bash uses itself, zsh and the execve(2) wrapper functions use /bin/sh) This is a legacy feature which works quite well when people are lazy and neglect to properly create their tiny wrapper scripts...

fish, being something that is non-posix compliant, not compatible with bash, incompatible with most scripting models and user workflows, and attempting to make up for it by being "user-friendly" (but only when you don't do anything interesting enough to bite you), has apparently decided this is not only a stupid legacy feature, but also, apparently, "dangerous".

So fish will break on many such scripts. That being said, it is arguably wrong to neglect the shebang and make the user's shell interpret this. Upstream should probably fix their installation process to install a better wrapper script: https://github.com/kazzmir/paintown/blob/e1c668557dca00164b4e8a7ad7b466bad7aaf9fd/install.sh#L40

(But you should seriously consider using another shell. I've never really seen anything that fish does by default, that you cannot configure a real shell like bash or zsh to do also. fish essentially remains relevant by being preconfigured.)
Comment by Sven-Hendrik Haase (Svenstaro) - Sunday, 07 January 2018, 12:54 GMT
I would rebuild this and fix it but I can't because of https://github.com/kazzmir/paintown/issues/16.
Comment by Sven-Hendrik Haase (Svenstaro) - Friday, 16 March 2018, 06:59 GMT
I dropped paintown because it's mostly unmaintained and doesn't build anymore and I have no interest in maintaining it.

Loading...