You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
both take an argument called "buffer" of type bytes. When you click on the hyperlink, you get directed to the documentation on python strings (https://docs.python.org/3/library/stdtypes.html#str), which is not the same type as python bytes. The buffer argument is used by the methods to buffer data, but byte type objects are immutable and therefore should not be written to.
I have tried using these methods with byte type buffer, the code runs without warnings, ocassionally works but gives hard-to-detect intermittent errors.
I do not know what type one should use here but surely byte must be wrong. Additionally, in the method description, it is not clear what "count" refers to (although one might assume it is the size of the byte object). In the C functions, count appear as arguments to the function, but here they do not.
The text was updated successfully, but these errors were encountered:
The read_async and read_all_async methods
https://lazka.github.io/pgi-docs/#Gio-2.0/classes/InputStream.html#Gio.InputStream.read_async
https://lazka.github.io/pgi-docs/#Gio-2.0/classes/InputStream.html#Gio.InputStream.read_all_async
both take an argument called "buffer" of type bytes. When you click on the hyperlink, you get directed to the documentation on python strings (https://docs.python.org/3/library/stdtypes.html#str), which is not the same type as python bytes. The buffer argument is used by the methods to buffer data, but byte type objects are immutable and therefore should not be written to.
I have tried using these methods with byte type buffer, the code runs without warnings, ocassionally works but gives hard-to-detect intermittent errors.
I do not know what type one should use here but surely byte must be wrong. Additionally, in the method description, it is not clear what "count" refers to (although one might assume it is the size of the byte object). In the C functions, count appear as arguments to the function, but here they do not.
The text was updated successfully, but these errors were encountered: