JonRobertson 72 Posted October 23, 2023 I just installed Phython4Delphi. The first demo, Demo01, throws an EPyRuntimeError (s_type = 'RuntimeError', s_value = '') when I click Execute Script on the simple print(2+2) example. The fourth line of Run_CommandAsObjectWithDict calls CheckError, which calls PyErr_Occurred, which does not return nil. I am just getting started with Python (for fun), so I am in the dark about why this error would occur or what needs to be done to resolve the issue. I have python 3.12 installed, both 32-bit and 64-bit. I have tested Demo01 as 32-bit and 64-bit and both throw the same exception. I can launch python at a command prompt and execute the script with no error. Any idea why this is occurring? Thanks. Share this post Link to post
pyscripter 689 Posted October 23, 2023 20 minutes ago, JonRobertson said: I just installed Phython4Delphi. Did you install the master branch from pyscripter/python4delphi: Free components that wrap up Python into Delphi and Lazarus (FPC) (github.com)? Here Demo01 and other demos run fine. Share this post Link to post
JonRobertson 72 Posted October 23, 2023 I installed three packages from GetIt: Python4Delphi 1.0 Python Environments 1.0 Lightweight Python Wrappers 1.0 I am using Delphi 11.3. Share this post Link to post
JonRobertson 72 Posted October 23, 2023 52 minutes ago, pyscripter said: Did you install the master branch from pyscripter/python4delphi: Free components that wrap up Python into Delphi and Lazarus (FPC) (github.com)? 12 minutes ago, JonRobertson said: I installed three packages from GetIt I cloned the repo from github and copied everything to Documents\Embarcadero\Studio\22.0\CatalogRepository\Python4Delphi-1.0\Source. Now the demos are working. Thanks. Share this post Link to post