Skip to content

Unknown argument -, when spawning shell in a folder path where a ' - ' is present #7487

Closed as not planned

Description

@MattiooFR
  • I am on the latest stable Poetry version, installed using a recommended method.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have consulted the FAQ and blog for any relevant entries or release notes.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option) and have included the output below.

Issue

Using the local venv option, I have issue with the command poetry shell if my project folder is located in a path where there is a ' - ' in the path

brainsorting.dev on  src is 📦 v0.1.0 via 🐍 v3.11.1 took 2s
❯ poetry shell -vvv
Loading configuration file /Users/mattioo/Library/Preferences/pypoetry/config.toml
Using virtualenv: /Users/mattioo/Documents/2 - Areas/brainsorting.dev/.venv
Spawning shell within /Users/mattioo/Documents/2 - Areas/brainsorting.dev/.venv

brainsorting.dev on  src is 📦 v0.1.0 via 🐍 v3.11.1
❯ emulate bash -c '. '/Users/mattioo/Documents/2 - Areas/brainsorting.dev/.venv/
bin/activate''
emulate: unknown argument -

Activity

  1. added
    kind/bugSomething isn't working as expected
    status/triageThis issue needs to be triaged
    on Feb 8, 2023
  2. dimbleby commented on Feb 8, 2023

    @dimbleby
    Contributor

    looks like you've simply failed to quote the path?

  3. neersighted commented on Feb 8, 2023

    @neersighted
    Member

    poetry shell is failing to quote the path -- this is a duplicate of the current quoting issue, though I can't find it right now 😆

  4. dimbleby commented on Feb 8, 2023

    @dimbleby
    Contributor

    I dont think it is - anyway the command that @MattiooFR pasted above is making a mess of the quoting.

    (They seem to be trying to put a single-quoted path inside an already single-quoted string)

  5. neersighted commented on Feb 8, 2023

    @neersighted
    Member

    They didn't type that -- poetry shell did using pexpect.

  6. dimbleby commented on Feb 8, 2023

    @dimbleby
    Contributor

    ack - in which case I agree that it's a bug, but I don't know the duplicate. (In particular it's not the same as the one with all the subprocess calls, per #7471)

  7. neersighted commented on Feb 8, 2023

    @neersighted
    Member

    Duplicate #7244.

  8. added and removed
    kind/bugSomething isn't working as expected
    status/triageThis issue needs to be triaged
    on Feb 8, 2023
  9. github-actions commented on Feb 29, 2024

    @github-actions

    This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

  10. locked as resolved and limited conversation to collaborators on Feb 29, 2024
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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions