TypeError: '_sre.SRE_Match' object is not subscriptable
See original GitHub issueI can’t run it.
# python3 engine.py --server-port 80 --strategy "[TCP:flags:PA]-duplicate(tamper{TCP:dataofs:replace:10}(tamper{TCP:chksum:corrupt},),)-|" --log debug
Traceback (most recent call last):
File "engine.py", line 329, in main
log_level=args["log"])
File "engine.py", line 54, in __init__
self.strategy = actions.utils.parse(string_strategy, self.logger)
File "/root/geneva/actions/utils.py", line 74, in parse
new_tree.parse(str_action, logger)
File "/root/geneva/actions/tree.py", line 180, in parse
if not match or not match[0]:
TypeError: '_sre.SRE_Match' object is not subscriptable
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "engine.py", line 338, in <module>
main(vars(get_args()))
File "engine.py", line 334, in main
eng.shutdown_nfqueue()
UnboundLocalError: local variable 'eng' referenced before assignment
Debian GNU/Linux 9.11 (stretch)
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Python - TypeError: '_sre.SRE_Match' object is not subscriptable
In python 3.5 I get back 'TypeError: '_sre.SRE_Match' object is not subscriptable.' I am not convinced the error is the differences in ...
Read more >TypeError: '_sre.SRE_Match' object is not subscriptable
TypeError : '_sre.SRE_Match' object is not subscriptable. Hello can anyone help me, I cant seem to make my code work on linux, when...
Read more >Codewars - '_sre.SRE_Match' object is not subscriptable
This seems to work fine on my IDE (Pycharm) but when I put the solution in to the codewars interpreter it returns the...
Read more >Why did #python open up dictionary access to match objects ...
Why did #python open up dictionary access to match objects? ( TypeError: '_sre.SRE_Match' object is not subscriptable ) #1281.
Read more >Python3 正则匹配match 函数提示TypeError: '_sre.SRE_Match ...
一般来说,返回之后我们可以直接获取他的值,但是有时候也会出问题,会提示 TypeError: '_sre.SRE_Match' object is not subscriptable 的错误,下面看 ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Thanks so much for testing this out. Sorry to make you the guinea pig on this issue.
We have a fix for python3.5 and we’ll be pushing that soon. The fix for python 3.7+ is tougher, but we’ll work on it!
I’m leaving this issue open until the fix comes out as I imagine other people will run into it.
Hey @xhdix - I updated the parsing code to support Python 3.5. Let us know if you have any other issues!