Skip to content
This repository has been archived by the owner on Jul 18, 2022. It is now read-only.

Runtime error in CLSniper.py #517

Open
piprees opened this issue Aug 12, 2016 · 3 comments
Open

Runtime error in CLSniper.py #517

piprees opened this issue Aug 12, 2016 · 3 comments

Comments

@piprees
Copy link

piprees commented Aug 12, 2016

Getting the following error on windows when using the latest develop branch's "CLSniper.py"

RuntimeError:
Attempt to start a new process before the current process
has finished its bootstrapping phase.
This probably means that you are on Windows and you have
forgotten to use the proper idiom in the main module:
 if __name__ == '__main__':
freeze_support()
The "freeze_support()" line can be omitted if the program
is not going to be frozen to produce a Windows executable.

Seems like the code isn't windows compatible?

@stolencatkarma
Copy link
Collaborator

I have no idea. tested on linux. I'll mark as help wanted because I wouldn't know how to solve this.

@rirze
Copy link
Contributor

rirze commented Aug 12, 2016

You can test for os and then decide whether to run freeze_support().

Sorta related, but @infinitewarp, do we test builds on windows?

@infinitewarp
Copy link
Collaborator

Unfortunately, I don't have access to a Windows machine for testing.

FWIW: https://docs.python.org/2/library/multiprocessing.html#multiprocessing.freeze_support

Calling freeze_support() has no effect when invoked on any operating system other than Windows. In addition, if the module is being run normally by the Python interpreter on Windows (the program has not been frozen), then freeze_support() has no effect.

@teh3vil How exactly are you executing the program? Are you invoking it with the python command from the terminal or double-clicking it or something else?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants