Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

venv creation broken on Windows with spaces in python path

Open
#140 3 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
48/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
python
Domain
tooling

Research direction

Start with hooks/post_gen_project.py lines 61-65 and reproduce the venv creation command using the reported Windows Python path containing spaces. Check the remaining calls in post_gen_project.py after venv creation, and consider the issue complete when project generation succeeds without manually rerunning the commands.

Written by the indexing model from the issue text.

Description

These lines to generate the virtual environment didn't work on my machine.

My python.exe is at c:\program files\python37\python.exe. Here's the error I get:

C:\temp_workspace\dash_temp>cookiecutter gh:plotly/dash-component-boilerplate
You've downloaded C:\Users\reube\.cookiecutters\dash-component-boilerplate before. Is it okay to delete and re-download it? [yes]:
project_name [my dash component]: test
project_shortname [test]:
component_name [Test]:
jl_prefix []:
r_prefix []:
author_name [Enter your first and last name (For package.json)]: test
author_email [Enter your email (For package.json)]: test@test.com
github_org []:
description [Project Description]: test
Select use_async:
1 - False
2 - True
Choose from 1, 2 [1]:
Select license:
1 - MIT License
2 - BSD License
3 - ISC License
4 - Apache Software License 2.0
5 - GNU General Public License v3
6 - Not open source
Choose from 1, 2, 3, 4, 5, 6 [1]:
publish_on_npm [True]: False
install_dependencies [True]: True
use_async
False
use_async is set to False, your component will not be lazy loaded and fragments will not be created.
Executing: c:\program files\python37\python.exe -m venv venv
'c:\program' is not recognized as an internal or external command,
operable program or batch file.
post_gen_project command failed: c:\program files\python37\python.exe -m venv venv

        venv creation failed.
        Make sure you have installed virtualenv on Python 2.

ERROR: Stopping generation because post_gen_project hook script didn't exit successfully
Hook script failed (exit status: 1)

I worked around this by running the venv commands and remaining calls in post_gen_project.py manually, but it'd be better if it worked.

Looks like #23 is a similar but much older issue.

Dominant language
Python
Stars
294
Forks
196
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from plotly/dash-component-boilerplate

All issues in plotly/dash-component-boilerplate

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.