Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exec inside a function does not work #5449

Closed
faho opened this issue Dec 30, 2018 · 3 comments
Closed

Exec inside a function does not work #5449

faho opened this issue Dec 30, 2018 · 3 comments
Labels
Milestone

Comments

@faho
Copy link
Member

@faho faho commented Dec 30, 2018

$ function ouch
     exec fish
 end
$ ouch
There are still jobs active:

   PID  Command
     0  ouch

as described by @scorphus on gitter, and oh-my-fish/oh-my-fish#664.

This is caused by us checking for running jobs before doing exec now (1b1bc28), in conjunction with the hierarchical job changes.

I think we might just get away with warning only with background processes (i.e. those where is_foreground() is false). @mqudsi?

The obvious question is if this is important enough to warrant a 3.0.1, or a quick 3.1.

@faho faho added the bug label Dec 30, 2018
@faho faho added this to the fish-3.1 milestone Dec 30, 2018
@faho faho closed this in b007248 Dec 30, 2018
@mqudsi
Copy link
Contributor

@mqudsi mqudsi commented Dec 30, 2018

I would say if you publish now, it's a quick 3.0.1. If you put it off, it might become a 3.1.

@JamesMcMahon
Copy link

@JamesMcMahon JamesMcMahon commented Jan 10, 2019

I would second that as this will keep me from upgrading to Fish 3 due to it completely breaking OMF.

The issue behavior described in oh-my-fish/oh-my-fish#664 is not a great user experience:

Yah, iterm2 hangs on startup macOS after updating to fish 3.0.0 with OMF 6.0.

@zanchey zanchey mentioned this issue Jan 12, 2019
7 tasks done
@floam floam modified the milestones: fish 3.1.0, fish 3.0.1 Jan 14, 2019
ridiculousfish added a commit that referenced this issue Jan 20, 2019
Extension of fix for #5449 in b007248
ridiculousfish added a commit that referenced this issue Jan 20, 2019
ridiculousfish added a commit that referenced this issue Jan 20, 2019
If it's a foreground job, it is related to the currently running exec.

This fixes exec in functions, i.e.

    function reload
        exec fish
    end

would previously always ask about the "function reload" job.

Fixes #5449.

Fixes oh-my-fish/oh-my-fish#664.
ridiculousfish added a commit that referenced this issue Jan 20, 2019
ridiculousfish added a commit that referenced this issue Jan 20, 2019
@ridiculousfish
Copy link
Member

@ridiculousfish ridiculousfish commented Jan 22, 2019

This went into 3.0.1 as 60ced5d

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants