File "/base/data/home/apps/x/1.339792748057786391/
minifb.py", line 178, in call
md5hash.update(_Hashable(secret))
File "/base/data/home/apps/x/1.339792748057786391/
minifb.py", line 265, in _Hashable
value = buffer(value)
RuntimeError: cannot create buffer objects in restricted execution
mode
In the short term, you could change the FacebookSecret class to just
use a string internally. The way that the string is encapsulated, I
doubt any error reporting would ever reveal the secret. I'll have to
use something else though so that it works on Google App Engine. I
should be able to get a new version during Pycon in the next few days?
On Feb 10, 10:35 am, quano <sweken...@gmail.com> wrote:
> I'm using google app engine and cannot get this to work. I'm making a
> call to facebook (users.isVerified), and this is what I get back:
> RuntimeError: cannot create buffer objects in restricted execution
> mode
Python objects implemented in C can export a group of functions called
the “buffer interface.” These functions can be used by an object to
expose its data in a raw, byte-oriented format. Clients of the object
can use the buffer interface to access the object data directly,
without needing to copy it first.
So because the buffer links to native C code it will not be allowed to
run in the Google App Engine.
The following code from minifb version 1.2 is not allowed to run in
appengine:
def buffer(value):
if isinstance(value, str):
return memoryview(value.encode())
return memoryview(value)