Skip to content

pyvenv --symlinks option is a no-op? #59486

Closed

Description

@pitrou
BPO 15281
Nosy @loewis, @vsajip, @pitrou

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2012-07-08.16:51:05.189>
created_at = <Date 2012-07-07.15:37:22.628>
labels = ['type-bug', 'library']
title = 'pyvenv --symlinks option is a no-op?'
updated_at = <Date 2013-04-15.21:57:13.080>
user = 'https://github.com/pitrou'

bugs.python.org fields:

activity = <Date 2013-04-15.21:57:13.080>
actor = 'piotr.dobrogost'
assignee = 'none'
closed = True
closed_date = <Date 2012-07-08.16:51:05.189>
closer = 'python-dev'
components = ['Library (Lib)']
creation = <Date 2012-07-07.15:37:22.628>
creator = 'pitrou'
dependencies = []
files = []
hgrepos = []
issue_num = 15281
keywords = []
message_count = 10.0
messages = ['164879', '164895', '164899', '164927', '164928', '164930', '165024', '186961', '186969', '187034']
nosy_count = 5.0
nosy_names = ['loewis', 'vinay.sajip', 'pitrou', 'python-dev', 'piotr.dobrogost']
pr_nums = []
priority = 'normal'
resolution = 'fixed'
stage = 'resolved'
status = 'closed'
superseder = None
type = 'behavior'
url = 'https://bugs.python.org/issue15281'
versions = ['Python 3.3']

Activity

  1. pitrou commented on Jul 7, 2012

    @pitrou
    MemberAuthor

    It seems that, regardless of whether I specify --symlinks or not, pyvenv always creates symlinks:

    $ pyvenv-3.3 env 
    $ tree env/
    env/
    |-- bin
    |   |-- activate
    |   |-- pydoc
    |   |-- pysetup3
    |   |-- python -> python3.3
    |   |-- python3 -> python3.3
    |   `-- python3.3 -> /home/antoine/opt/bin/python3.3
    |-- include
    |-- lib
    |   `-- python3.3
    |       `-- site-packages
    `-- pyvenv.cfg

    5 directories, 7 files

  2. added
    stdlibStandard Library Python modules in the Lib/ directory
    type-bugAn unexpected behavior, bug, or error
    on Jul 7, 2012
  3. loewis commented on Jul 7, 2012

    loewismannequin
    Mannequin

    Try --no-symlinks.

  4. pitrou commented on Jul 7, 2012

    @pitrou
    MemberAuthor
    $ pyvenv-3.3 --no-symlinks env
    usage: venv [-h] [--system-site-packages] [--symlinks] [--clear] [--upgrade]
                ENV_DIR [ENV_DIR ...]
    venv: error: unrecognized arguments: --no-symlinks

    :-)

  5. vsajip commented on Jul 7, 2012

    @vsajip
    Member

    Following discussions on python-dev, the default is always to symlink, except on Windows (no support for true symlinks on XP and older) and Mac OS X (problems with framework builds). The --symlinks indicates, on those platforms where symlinks is not the default, to use symlinks anyway. This will most likely only be useful on Windows Vista, Windows 7 and Mac OS X with a non-framework build of Python.

  6. pitrou commented on Jul 7, 2012

    @pitrou
    MemberAuthor

    Following discussions on python-dev, the default is always to symlink,
    except on Windows (no support for true symlinks on XP and older) and
    Mac OS X (problems with framework builds). The --symlinks indicates,
    on those platforms where symlinks is not the default, to use symlinks
    anyway. This will most likely only be useful on Windows Vista, Windows
    7 and Mac OS X with a non-framework build of Python.

    Ok, then it might be nice to make the usage string (which is printed
    with pyvenv --help) clearer.

  7. vsajip commented on Jul 7, 2012

    @vsajip
    Member

    Ok, then it might be nice to make the usage string (which is printed
    with pyvenv --help) clearer.

    Fair point, I'll update the help text to be clearer.

  8. python-dev commented on Jul 8, 2012

    python-devmannequin
    Mannequin

    New changeset 9c345b4bd97e by Vinay Sajip in branch 'default':
    Closes bpo-15281, bpo-15283: Don't make venv scripts executable, but copy source mode instead, and provide better help for pyvenv.
    http://hg.python.org/cpython/rev/9c345b4bd97e

  9. piotrdobrogost commented on Apr 14, 2013

    piotrdobrogostmannequin
    Mannequin

    Following discussions on python-dev, the default is always to symlink,
    except on Windows (no support for true symlinks on XP and older) and

    In this case couldn't symlinks be automatically used on Windows Vista or newer?

  10. vsajip commented on Apr 15, 2013

    @vsajip
    Member

    In this case couldn't symlinks be automatically used on Windows Vista or newer?

    It seems simpler if the default behaviour is the same on all Windows flavours - you can specify --symlinks if you're on Windows Vista or later.

  11. piotrdobrogost commented on Apr 15, 2013

    piotrdobrogostmannequin
    Mannequin

    It's simpler but is it better this way? I doubt. I think we should take advantage of symlinks whenever we can and only fallback to copying if they are not available.

  12. transferred this issue fromon Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    stdlibStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions