PySolFC icon indicating copy to clipboard operation
PySolFC copied to clipboard

A guide to running PySolFC on a Mac

Open holgersindbaek opened this issue 5 years ago • 6 comments

I'd love to mess around with your library, but I'm kind of new to Python. Is there any chance that someone can post a quick guide on how to get up and running on a Mac?

holgersindbaek avatar Aug 21 '20 08:08 holgersindbaek

@holgersindbaek : hi! pysolfc is not a library (see https://en.wikipedia.org/wiki/Library_(computing) ), but rather a collection of games as a GUI program/application: https://en.wikipedia.org/wiki/Graphical_user_interface . Furthermore, its choice of licence ( GPLv3 ) may limit the legal usability of most of its code as such.

Python should be easy to learn (see the recommended resources: https://github.com/shlomif/Freenode-programming-channel-FAQ/blob/master/FAQ_with_ToC__generated.md#i-want-to-learn-programming-which-language-should-i-start-with ) and you may have some luck with the macOS packages: (see the .app.tar.xz here: https://github.com/shlomif/PySolFC/releases/tag/pysolfc-2.10.1 ). We could use some help with testing on macOS.

Thanks! and good luck.

shlomif avatar Aug 21 '20 09:08 shlomif

Thanks for the clarification. I'm trying to run the app, but I get the following error:

➜  PySolFC git:(master) ✗ python pysol.py
Traceback (most recent call last):
  File "pysol.py", line 41, in <module>
    sys.exit(main(sys.argv))
  File "/PySolFC/pysollib/main.py", line 422, in main
    r = pysol_init(app, args)
  File "/PySolFC/pysollib/main.py", line 199, in pysol_init
    app.dataloader = DataLoader(args[0], f)
  File "/PySolFC/pysollib/util.py", line 136, in __init__
    str(filenames))
OSError: pysol.py: DataLoader could not find ('html/license.html',)

Do I need to generate some HTML before I can run the app?

holgersindbaek avatar Aug 21 '20 10:08 holgersindbaek

Thanks for the clarification. I'm trying to run the app, but I get the following error:

➜  PySolFC git:(master) ✗ python pysol.py
Traceback (most recent call last):
  File "pysol.py", line 41, in <module>
    sys.exit(main(sys.argv))
  File "/PySolFC/pysollib/main.py", line 422, in main
    r = pysol_init(app, args)
  File "/PySolFC/pysollib/main.py", line 199, in pysol_init
    app.dataloader = DataLoader(args[0], f)
  File "/PySolFC/pysollib/util.py", line 136, in __init__
    str(filenames))
OSError: pysol.py: DataLoader could not find ('html/license.html',)

Do I need to generate some HTML before I can run the app?

Hi!

Try typing gmake rules as specified in the README.md (where gmake is GNU make ). You may need to install other data files too.

shlomif avatar Aug 21 '20 12:08 shlomif

Pysolfc 2.10.1 won't start up on MacOS Mojave. Instead it restarts my mac. When I go back in, I need to force quit (kill) Pysolfc, or it will repeat this behavior.

megandalster avatar Oct 12 '20 00:10 megandalster

Pysolfc 2.10.1 won't start up on MacOS Mojave. Instead it restarts my mac. When I go back in, I need to force quit (kill) Pysolfc, or it will repeat this behavior.

Hi!

That sounds strange. Can you try running pysol from the command line using https://docs.python.org/3/library/trace.html e.g:

python3 -m trace --trace pysol.py |& tee ~/pysol-trace.txt

It may be a macOS bug though.

shlomif avatar Oct 12 '20 07:10 shlomif

OSError: pysol.py: DataLoader could not find ('html/license.html',)

Seems you tried running Pysol from source code.

I had the same issue. It is because the licence file is in "..html-src/licence.html" Rename the folder and it could work.

More issues may come because images are in "*master/data/images" but source looks for "master/images"

cardset are normally in "..data/YourCardset" but source looks for "master/YourCardset".

All in all very confusing.

cardset avatar Oct 12 '20 08:10 cardset