Hi Rudolf,
> remote_api_stub.ConfigureRemoteDatastore('parlorweb', '/remote_api',
> auth_func, host)
Perhaps you can put the line bellow after setting up remote_api_stub.
remote_api_stub.MaybeInvokeAuthentication()
hope it helps
--
Takashi Matsuo
Kay's daddy
On Fri, Oct 16, 2009 at 8:20 PM, [email protected] <[email protected]> wrote:
>
> before 1.2.7 I returned None, None in the auth_func. Now I have to use
> the Google passwords, all other return
> urllib2.HTTPError: HTTP Error 401: Unauthorized
>
> This is the Skript I run:
>
> from gae import models
> import pserver
>
> from google.appengine.ext.remote_api import remote_api_stub
> from google.appengine.ext import db
>
>
> host = '127.0.0.1:8080'
>
> def auth_func():
> return 'benutzer', 'axyert01'
>
>
> remote_api_stub.ConfigureRemoteDatastore('parlorweb', '/remote_api',
> auth_func, host)
>
> rec = models.Configuration(key_name='STAATEN')
> rec.custid = ''
> rec.content = str(pserver.adr({'func': 'showStaat'}))
> rec.put() #line 20
>
> This is the output:
>
> C:\parlor>gae_init.py
> Traceback (most recent call last):
> File "C:\parlor\gae_init.py", line 20, in <module>
> rec.put()
> File "C:\Programme\Google\google_appengine\google\appengine\ext\db
> \__init__.py
> ", line 795, in put
> return datastore.Put(self._entity)
> File "C:\Programme\Google\google_appengine\google\appengine\api
> \datastore.py",
> line 179, in Put
> apiproxy_stub_map.MakeSyncCall('datastore_v3', 'Put', req, resp)
> File "C:\Programme\Google\google_appengine\google\appengine\api
> \apiproxy_stub_
> map.py", line 72, in MakeSyncCall
> apiproxy.MakeSyncCall(service, call, request, response)
> File "C:\Programme\Google\google_appengine\google\appengine\api
> \apiproxy_stub_
> map.py", line 266, in MakeSyncCall
> rpc.CheckSuccess()
> File "C:\Programme\Google\google_appengine\google\appengine\api
> \apiproxy_rpc.p
> y", line 111, in CheckSuccess
> raise self.exception
> urllib2.HTTPError: HTTP Error 200:
>
> C:\parlor>
>
> This is the Log Console:
> 2009-10-16 12:51:42 Running command: "['C:\\Python25\\python.exe', 'C:\
> \Program Files\\Google\\google_appengine\\dev_appserver.py', '--
> admin_console_server=', '--port=8080', 'C:\\parlor\\gae']"
> INFO 2009-10-16 10:51:46,605 dev_appserver_main.py:478] Running
> application parlorweb on port 8080: http://localhost:8080
> INFO 2009-10-16 10:52:11,900 dev_appserver.py:3038] "POST /
> remote_api? HTTP/1.1" 401 -
> INFO 2009-10-16 10:52:11,910 dev_appserver_index.py:205] Updating
> C:\parlor\gae\index.yaml
> INFO 2009-10-16 10:52:13,315 dev_appserver.py:3038] "POST /
> remote_api? HTTP/1.1" 401 -
> INFO 2009-10-16 10:53:35,999 dev_appserver.py:3038] "POST /
> remote_api? HTTP/1.1" 401 -
> INFO 2009-10-16 10:53:37,486 dev_appserver.py:3038] "GET /_ah/
> login?continue=http%3A%2F%2Flocalhost
> %2F&auth=DQAAAHkAAADW7iGDI7I-9xfPr89rCXQI_YgeqdQ3JR5pXzLMuO-
> UKf_jLAJ2Aet0VZuktstNHlEWNHjuNrNGFruH1gT8QxKVfyYWlIzarWscFwwK5yzszSjsiyYyR0bHwSmoMmc8GNdsBpQeNJxxnerMM_OqQjIHN8K-
> xqf6zSmuBCB0ZHsQkg HTTP/1.1" 200 -
>
> The Skript worked in 1.2.5.
>
> Thanks,
>
> Rudolf
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---