venv: bin/activate.fish doesn't work

Bug #1628165 reported by roland
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python3.5 (Ubuntu)
New
Undecided
Unassigned

Bug Description

Creating a virtual env with pyvenv and activating it using the fish shell will throw an error.
This is due to a '$' being added to the venv prompt.
This is behavior that is not in python 3.5: https://hg.python.org/cpython/file/3.5/Lib/venv/

/tmp> pyvenv venv
/tmp> source venv/bin/activate.fish
The “$” character begins a variable name. The character “(”, which directly followed a “$”, is not allowed as a part of a variable name, and variable names may not be zero characters long. To learn more about variable expansion in fish, type “help expand-variable”.
venv/bin/activate.fish (line 58): if test -n "$(venv) "
                                                     ^
from sourcing file venv/bin/activate.fish
 called on standard input

source: Error while reading file “venv/bin/activate.fish”

Ubuntu 16.04.1 LTS
pyvenvv-3.5

Revision history for this message
roland (roland-micite) wrote :

I have this bug with 3.5.

affects: python3.4 (Ubuntu) → python3.5 (Ubuntu)
Revision history for this message
roland (roland-micite) wrote :

I only affect me on Ubuntu 16.04, not on 16.10.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.