Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting an Exception on the second run of the Moduile #8

Open
brendanmeyer opened this issue Dec 10, 2023 · 0 comments
Open

Getting an Exception on the second run of the Moduile #8

brendanmeyer opened this issue Dec 10, 2023 · 0 comments

Comments

@brendanmeyer
Copy link

Hey

I am able to run a python command the first time (after opening a pwsh prompt).

But once, that first command has run, on the second command I am receiving the following Exception, which seems to crash pwsh.

PowerShell 7.4.0
PS [17:22:18] C:\Users> Use-Python { Invoke-Python -Code "print('Hello, from Python!')" }
Hello, from Python!
PS [17:22:22] C:\Users> Use-Python { Invoke-Python -Code "print('Hello, from Python!')" }
SetValueInvocationException: Exception setting "PythonDLL": "This property must be set before runtime is initialized"
Fatal Python error: PyEval_SaveThread: the function must be called with the GIL held, but the GIL is released (the current Python thread state is NULL)
Python runtime state: initialized

Current thread 0x00003e48 (most recent call first):
  <no Python frame>

[process exited with code 3221226505 (0xc0000409)]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant