I've got a SyntaxError on my except:
try: opts, args = getopt.getopt(sys.argv[1:], 'P:D:H:d:u:p:nvhmJi:c:Ml:TB:', ['host=', 'port=', 'directory=', 'user=', 'password=', 'daemon=', 'noauth', 'help', 'verbose', 'mysql', 'icounter=', 'config=', 'nolock', 'nomime', 'loglevel', 'noiter', 'baseurl=']) except getopt.GetoptError, e: print usage print '>>>> ERROR: %s' % str(e) sys.exit(2)
I get the error:
File "main.py", line 199 except getopt.GetoptError, e: SyntaxError: invalid syntax
Anyone have any idea?
Trailing or leading spaces Probably the most common cause of Excel not recognizing duplicates. Check if the one cell has trailing, leading or extra spaces in the cell. Excel sees the space as an individual character but humans tend to ignore it.
In Excel, there are several ways to filter for unique values—or remove duplicate values: To filter for unique values, click Data > Sort & Filter > Advanced. To remove duplicate values, click Data > Data Tools > Remove Duplicates.
You use python3 and in python3 the raise syntax no longer accepts comma-separated arguments.
Use as
instead:
except getopt.GetoptError as e:
This form is also backwards-compatible with 2.6 and 2.7.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With