-
-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: a bytes-like object is required, not 'str' #64
Comments
There are some places to change, e.g.:
It looks like the r2pipe in pypi is the 2.4.0 release of this repo, but the current HEAD version changed a lot. I think you can modify the py files in your installed files. |
This is the fix for 2.4.0 (looks like it's the current r2pipe-0.9.9) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm trying to use r2pipe in Python 3 and keep running into the error "TypeError: a bytes-like object is required, not 'str'" when using the cmd() function. I have updated r2pipe via pip3, updated r2 to the latest version, and even updated r2pm just in case that would help any. I am running this on a Manjaro Linux machine, though I'm not sure if that would cause any problems. Here is the exact error I am getting:
Traceback (most recent call last):
File "test.py", line 4, in
r2.cmd( 'aa' )
File "/usr/lib/python3.6/site-packages/r2pipe/init.py", line 274, in cmd
res = self._cmd(cmd)
File "/usr/lib/python3.6/site-packages/r2pipe/init.py", line 214, in _cmd_pipe
os.write(self.pipe[1], cmd)
TypeError: a bytes-like object is required, not 'str'
The text was updated successfully, but these errors were encountered: