pipreqsnb icon indicating copy to clipboard operation
pipreqsnb copied to clipboard

Cannot find a method to run pipreqsnb in anaconda

Open henryjos opened this issue 4 years ago • 1 comments

Assigned python notebook to variable:

notebook = PureWindowsPath("C:\Users\Henry\Anaconda3\envs\fastai2\varmint_identifier.ipynb") correct_path = Path(notebook) print(correct_path) Output: C:\Users\Henry\Anaconda3\envs\fastai2\varmint_identifier.ipynb

Attempted to create reqs.txt file

pipreqsnb (correct_path --encoding=utf8 --savepath=reqs.txt)

Received an invalid syntax error

File "C:\Users\Henry\AppData\Local\Temp/ipykernel_10728/2599089689.py", line 1 pipreqsnb (correct_path --encoding=utf8 --savepath=reqs.txt)

SyntaxError: invalid syntax (at savepath '='

henryjos avatar Nov 07 '21 02:11 henryjos

I'm not fully into windows, but some hints that might help you.

  • First be sure that the enviroment in which pipreqsnb is installed is active.
  • Then, you should run the command without the parenthesis. For your case it should be something like pipreqsnb correct_path --encoding=utf8 --savepath=reqs.txt.

If you still are having some trouble please let me know.

ivanlen avatar Dec 03 '21 11:12 ivanlen