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

Silent `unset -f` error in zsh #843

Merged
merged 1 commit into from Jan 22, 2016

Conversation

Projects
None yet
5 participants
@Gnouc
Contributor

Gnouc commented Jan 20, 2016

With zsh version 5.2, unset -f function_not_exist will raise an error:

$ unset -f function_not_exist
unset: no such hash table element: function_not_exist

virtualenv version 14.0.0, an error message will dump to terminal when source activate:

$ virtualenv --version
14.0.0

$ virtualenv venv
New python executable in /tmp/venv/bin/python
Installing setuptools, pip, wheel...done.

$ source venv/bin/activate
deactivate:unset:1: no such hash table element: pydoc

This pull just silent the error message by redirecting all its output to /dev/null.

@Gnouc

This comment has been minimized.

Show comment
Hide comment
@Gnouc

Gnouc Jan 22, 2016

Contributor

@Ivoz Can you please take a look at it?

Contributor

Gnouc commented Jan 22, 2016

@Ivoz Can you please take a look at it?

Ivoz added a commit that referenced this pull request Jan 22, 2016

Merge pull request #843 from Gnouc/develop
Silent `unset -f` error in zsh

@Ivoz Ivoz merged commit e22e3f1 into pypa:develop Jan 22, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

Ivoz added a commit that referenced this pull request Jan 22, 2016

@Ivoz

This comment has been minimized.

Show comment
Hide comment
@Ivoz

Ivoz Jan 22, 2016

Member

Thanks

Member

Ivoz commented Jan 22, 2016

Thanks

@Namita26

This comment has been minimized.

Show comment
Hide comment
@Namita26

Namita26 Jan 25, 2016

had this been solved ? I am still getting the error:
deactivate:unset:1: no such hash table element: pydoc
I have installed the it today only.

Namita26 commented Jan 25, 2016

had this been solved ? I am still getting the error:
deactivate:unset:1: no such hash table element: pydoc
I have installed the it today only.

@Gnouc

This comment has been minimized.

Show comment
Hide comment
@Gnouc

Gnouc Jan 25, 2016

Contributor

@Namita26 Check your version, AFAICT, the version fixed this error haven't been released yet. See https://github.com/pypa/virtualenv/blob/develop/docs/changes.rst

Contributor

Gnouc commented Jan 25, 2016

@Namita26 Check your version, AFAICT, the version fixed this error haven't been released yet. See https://github.com/pypa/virtualenv/blob/develop/docs/changes.rst

@suizman

This comment has been minimized.

Show comment
Hide comment
@suizman

suizman Jan 27, 2016

Same here using v14.0.1-1 on Arch

suizman commented Jan 27, 2016

Same here using v14.0.1-1 on Arch

@Gnouc

This comment has been minimized.

Show comment
Hide comment
@Gnouc

Gnouc Jan 28, 2016

Contributor

@suizman You need to wait for v14.1.0

Contributor

Gnouc commented Jan 28, 2016

@suizman You need to wait for v14.1.0

@Ivoz

This comment has been minimized.

Show comment
Hide comment
@Ivoz

Ivoz Jan 28, 2016

Member

Now released on 14.0.3

Member

Ivoz commented Jan 28, 2016

Now released on 14.0.3

@sailorsamoor

This comment has been minimized.

Show comment
Hide comment
@sailorsamoor

sailorsamoor Oct 11, 2017

Hello.
If you use virtualenvwrapper may be suit such script in postmkvirtualenv as a crutch:

if [ -n "$VIRTUAL_ENV" ]; then sed -i '' 's#unset -f pydoc$#unset -f pydoc >/dev/null 2>&1#' $VIRTUAL_ENV/bin/activate fi

sailorsamoor commented Oct 11, 2017

Hello.
If you use virtualenvwrapper may be suit such script in postmkvirtualenv as a crutch:

if [ -n "$VIRTUAL_ENV" ]; then sed -i '' 's#unset -f pydoc$#unset -f pydoc >/dev/null 2>&1#' $VIRTUAL_ENV/bin/activate fi

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment