Bench Init not working on Windows

I’m trying to create a desktop app in C# and .NET that can fetch the data from the cloud. I read that I’d have to install Frappe Bench first so I did and it was successful. But when I try to run bench init with any parameters and I get this

Traceback (most recent call last):
  File "C:\Python27\Scripts\bench-script.py", line 11, in <module>
    load_entry_point('bench', 'console_scripts', 'bench')()
  File "c:\python27\lib\site-packages\pkg_resources\__init__.py", line 565, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "c:\python27\lib\site-packages\pkg_resources\__init__.py", line 2631, in load_entry_point
    return ep.load()
  File "c:\python27\lib\site-packages\pkg_resources\__init__.py", line 2291, in load
    return self.resolve()
  File "c:\python27\lib\site-packages\pkg_resources\__init__.py", line 2297, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "d:\desktop\kash\programming\cp\erpnext\bench-repo\bench\cli.py", line 2, in <module>
    import os, sys, logging, json, pwd, subprocess
ImportError: No module named pwd

The same thing happens when I try to add a site.

try python -v , and tell me if it works ?

You probably installed frappe bench with easy install. a better idea is to install manually. Make sure you uninstall all components before installing it manually. And yes bench supports only Linux and Mac

Refer

Bench is Linux based system tool. Won’t support for Windows. Use erpnext virtual machine if you are using Windows.

https://erpnext.com/download

1 Like