Psycojoker / prosopopee

a static website generator to make beautiful customizable pictures galleries that tell a story
http://prosopopee.readthedocs.org
GNU General Public License v3.0
323 stars 55 forks source link

Themes folder has to exist or prosopopee crashes #96

Closed morremeyer closed 4 years ago

morremeyer commented 4 years ago

If the themes folder does not exist, the build process instantly crashes.

Traceback (most recent call last):
  File "/usr/local/bin/prosopopee", line 10, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.7/site-packages/prosopopee/prosopopee.py", line 610, in main
    templates = get_gallery_templates(theme)
  File "/usr/local/lib/python3.7/site-packages/prosopopee/prosopopee.py", line 336, in get_gallery_templates
    available_themes = theme, "', '".join(Path(__file__).parent.joinpath("themes").listdir())
  File "/usr/local/lib/python3.7/site-packages/path/__init__.py", line 497, in listdir
    self / child for child in os.listdir(self)
NotADirectoryError: [Errno 20] Not a directory: Path('/usr/local/lib/python3.7/site-packages/prosopopee/themes')

Affected version: 0.8.2

I’ll fix this myself as soon as I find the time to do so.

KjellConnelly commented 4 years ago

This is happening to me too. Going to mkdir and see what happens.

Update: I did, and it needs the themes. Not sure why it's not downloading themes. Going to try to reinstall via pip again. If doesn't work, I'll just download repo and move directory

jlntrt commented 4 years ago

Any news here? I have the same issue with Python 3.6.9 and the same prosopopee version.

Bouni commented 4 years ago

Same issue here, just installed via pip (python 3.8, prosopopee 0.8.2). The themes dir isn't where it should be (site-packages/prosopopee/themes). cloning the repo and copy the themes dir to site-packages/prosopopee/themes fixed the issue for me.

JocelynDelalande commented 4 years ago

I can confirm it fails. The package seems not no include the themes folder.

Current workarounds I found working : install prosopopee 0.8.1 instead of 0.8.2.

@beudbeud I suppose this is merely a pip packaging issue.

beudbeud commented 4 years ago

I just make a new package, normally the issue is fixed pip3 install prosopopee==0.8.3

JocelynDelalande commented 4 years ago

IMHO, issue can be closed. @mauricemeyer

morremeyer commented 4 years ago

I didn’t test it myself but it looks pretty fixed to me :)