longld / peda

PEDA - Python Exploit Development Assistance for GDB
Other
5.81k stars 798 forks source link

syntax errors when sourcing `peda.py` #147

Open CaptainTux opened 4 years ago

CaptainTux commented 4 years ago

So recently, when I do source peda.py in gdb, I get some syntax warnings image It did never happen to me until a new weeks ago. It probably started after I did some updates, so maybe some syntax checks in the new python versions. My python versions are

$ python3 -V
  Python 3.8.0
$ python2 -V
  Python 2.7.17
$ python -V
  Python 3.8.0

It is not a major issue, but maybe this should be fixed, as I do not see any specific python version requirements for peda.

Emilio66 commented 4 years ago

Same issue. source is a bash command for importing Bash script, how could that be legally used to 'source' a Python script? PS: my GDB version is v8.3

growlnx commented 4 years ago

So recently, when I do source peda.py in gdb, I get some syntax warnings image It did never happen to me until a new weeks ago. It probably started after I did some updates, so maybe some syntax checks in the new python versions. My python versions are

$ python3 -V
  Python 3.8.0
$ python2 -V
  Python 2.7.17
$ python -V
  Python 3.8.0

It is not a major issue, but maybe this should be fixed, as I do not see any specific python version requirements for peda.

The same thing happened here. I replaced "is" with "==" on these lines and the warning apparently disappeared.

growlnx commented 4 years ago

Same issue. source is a bash command for importing Bash script, how could that be legally used to 'source' a Python script? PS: my GDB version is v8.3

https://sourceware.org/gdb/current/onlinedocs/gdb/Extending-GDB.html#Extending-GDB

CaptainTux commented 4 years ago

apparently there are already two pull requests for this issue https://github.com/longld/peda/pull/145 https://github.com/longld/peda/pull/149 god what have I done :eyes: I didn't mean to close this :/ although it could probably be closed if someone merged that pull request