brewsci / homebrew-science

:snowflake: Scientific formulae for Homebrew and Linuxbrew (legacy)
https://github.com/brewsci
Other
154 stars 76 forks source link

error while installing openni2 using brew #307

Open demolen opened 1 year ago

demolen commented 1 year ago

Last 15 lines from /Users/xxxx/Library/Logs/Homebrew/openni2/02.python: 2023-04-26 09:33:53 +0000

python Packaging/Harvest.py out x64

File "/private/tmp/openni2-20230426-7247-oxun0m/OpenNI2-2.2.0-debian/Packaging/Harvest.py", line 338 print 'Usage: ' + sys.argv[0] + ' <x86|x64|Arm>' ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?

paulwetzel commented 1 year ago

Same problem here, if you take a look at the code, this error does exist in the main branch of the original repository, and I am unaware of some python magic to print without parentheses, so this I likely some bug with them

SeleDreams commented 1 year ago

i had this same issue trying to install it on my mac with brew, what's the workaround at this time ?

paulwetzel commented 1 year ago

@SeleDreams Using brew edit, you can edit the original code before running installation, if you add the parentheses at this point, you should have a working version.

BenFranzi commented 9 months ago

You need to update the brew install script to use Python2 Run brew edit openni2 and on line 32 update the following

system "python", "Packaging/Harvest.py", "out", "x64"

to

system "python2", "Packaging/Harvest.py", "out", "x64"
colinpin commented 6 months ago

@paulwetzel running into the same issue, could you elaborate a bit on the fix? I am using the brew edit openni2 but I seem to be editing a different file, i can't find where the () is missing.