clicknium / clicknium-samples

Clicknium Python automation Samples
Apache License 2.0
27 stars 5 forks source link

Converting python clicknium example with pyinstaller #12

Open CzakuGim opened 2 years ago

CzakuGim commented 2 years ago

Hello,

I have just prepared simple script importing clicknium and printing something:

script_example.py:

  from clicknium import clicknium as cc
  print(cc.edge.browsers)

The script is working when running as python file.

I want to prepare .exe file by using pyinstaller.

So I have prepared spec file:

pyi-makespec spec_file script_example.py

After running command with created spec_file.spec:

pyinstaller spec_file_name.spec

The pyinstaller is creating the .exe file.

After running created .exe file I got an error:

System.IO.FileNotFoundException: Unable to find assembly 'C:\Users\user_1\AppData\Local\Temp\_MEI197042\clicknium\.lib\automation\ClickniumJavaBridge-32.dll'

Could you help me with above?

clicknium==0.1.9 pyinstaller==5.4.1

CzakuGim commented 2 years ago

UPDATE right now (clicknium 0.1.10) there is possibility to choose console/gui app while "packaging project". I have tested it and it works as expected.