homebrew-science icon indicating copy to clipboard operation
homebrew-science copied to clipboard

error while installing openni2 using brew

Open demolen opened this issue 1 year ago • 5 comments

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] + ' <OutDir> <x86|x64|Arm>' ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?

demolen avatar Apr 26 '23 09:04 demolen

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

paulwetzel avatar May 18 '23 19:05 paulwetzel

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

SeleDreams avatar Jun 02 '23 12:06 SeleDreams

@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.

paulwetzel avatar Jun 05 '23 21:06 paulwetzel

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"

BenFranzi avatar Nov 28 '23 13:11 BenFranzi

@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.

colinpin avatar Feb 22 '24 23:02 colinpin