noah-peeters / ChimpStackr

free, multi-platform focus stacking software
GNU General Public License v3.0
74 stars 8 forks source link

Program won't start #138

Open mmiller7 opened 1 year ago

mmiller7 commented 1 year ago

Describe the bug Won't run on Mint 21/Ubuntu 22.04LTS

To Reproduce Steps to reproduce the behavior:

  1. Run as suggested in readme src/run.py in a terminal

Expected behavior I expect it to run

Screenshots

$ ./run.py 
import-im6.q16: attempt to perform an operation not allowed by the security policy `PS' @ error/constitute.c/IsCoderAuthorized/421.
import-im6.q16: attempt to perform an operation not allowed by the security policy `PS' @ error/constitute.c/IsCoderAuthorized/421.
import-im6.q16: attempt to perform an operation not allowed by the security policy `PS' @ error/constitute.c/IsCoderAuthorized/421.
run.py: line 8: syntax error near unexpected token `('
./run.py: line 8: `currentdir = os.path.dirname(os.path.realpath(__file__))'

Desktop (please complete the following information):

Additional context Add any other context about the problem here.

noah-peeters commented 1 year ago

Hi Might be because os.path.realpath(__file__) is empty? (https://stackoverflow.com/questions/7783308/os-path-dirname-file-returns-empty)

Can you try adding this: print(os.path.realpath(__file__)) above the currentdir = os.path.dirname(os.path.realpath(__file__)) line?

For me, on windows it prints something like this: C:\Users\MyUser\Documents\ChimpStackr\src\run.py. If it prints empty for you, you can try replacing line 8 with this: currentdir = os.path.dirname(os.path.realpath(__file__) or ".").

Thanks for trying it out.