views:

32

answers:

1

i can download data from gae (http://zjm1126.appspot.com/remote_api), this is code:

appcfg.py download_data  --application=zjm1126 --url=http://zjm1126.appspot.com/remote_api --filename=a.csv

and it successful :

D:\zjm_demo\app>appcfg.py download_data  --application=zjm1126 --url=http://zjm1
126.appspot.com/remote_api --filename=a.csv
Downloading data records.
[INFO    ] Logging to bulkloader-log-20100618.162421
[INFO    ] Throttling transfers:
[INFO    ] Bandwidth: 250000 bytes/second
[INFO    ] HTTP connections: 8/second
[INFO    ] Entities inserted/fetched/modified: 20/second
[INFO    ] Batch Size: 10
[INFO    ] Opening database: bulkloader-progress-20100618.162421.sql3
[INFO    ] Opening database: bulkloader-results-20100618.162421.sql3
[INFO    ] Connecting to zjm1126.appspot.com/remote_api
Please enter login credentials for zjm1126.appspot.com
Email: [email protected]
Password for [email protected]:
[INFO    ] Downloading kinds: [u'LogText', u'Greeting', u'Forum', u'Thread']
....
[INFO    ] Have 0 entities, 0 previously transferred
[INFO    ] 0 entities (8804 bytes) transferred in 11.3 seconds

so i want to know can load data from 127.0.0.1 , this is my code :

appcfg.py download_data  --application=zjm1126 --url=http://localhost:8100/remote_api --filename=a.csv

and the error is :

D:\zjm_demo\app>appcfg.py download_data  --application=zjm1126 --url=http://loca
lhost:8100/remote_api --filename=a.csv
Downloading data records.
[INFO    ] Logging to bulkloader-log-20100618.162325
[INFO    ] Throttling transfers:
[INFO    ] Bandwidth: 250000 bytes/second
[INFO    ] HTTP connections: 8/second
[INFO    ] Entities inserted/fetched/modified: 20/second
[INFO    ] Batch Size: 10
[INFO    ] Opening database: bulkloader-progress-20100618.162325.sql3
[INFO    ] Opening database: bulkloader-results-20100618.162325.sql3
Please enter login credentials for localhost
Email: [email protected]
Password for [email protected]:
[INFO    ] Connecting to localhost:8100/remote_api
[ERROR   ] Exception during authentication
Traceback (most recent call last):
  File "d:\Program Files\Google\google_appengine\google\appengine\tools\bulkload
er.py", line 3169, in Run
    self.request_manager.Authenticate()
  File "d:\Program Files\Google\google_appengine\google\appengine\tools\bulkload
er.py", line 1178, in Authenticate
    remote_api_stub.MaybeInvokeAuthentication()
  File "d:\Program Files\Google\google_appengine\google\appengine\ext\remote_api
\remote_api_stub.py", line 542, in MaybeInvokeAuthentication
    datastore_stub._server.Send(datastore_stub._path, payload=None)
  File "d:\Program Files\Google\google_appengine\google\appengine\tools\appengin
e_rpc.py", line 346, in Send
    f = self.opener.open(req)
  File "D:\Python25\lib\urllib2.py", line 387, in open
    response = meth(req, response)
  File "D:\Python25\lib\urllib2.py", line 498, in http_response
    'http', request, response, code, msg, hdrs)
  File "D:\Python25\lib\urllib2.py", line 425, in error
    return self._call_chain(*args)
  File "D:\Python25\lib\urllib2.py", line 360, in _call_chain
    result = func(*args)
  File "D:\Python25\lib\urllib2.py", line 506, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 404: Not Found
[INFO    ] Authentication Failed

so what should i do ,

thanks

A: 

You may need to use --kind=LogText for your LogText kind and then repeat for each of your other kinds, as the development web server does not support downloading all kinds - it can only do one at a time.

Not sure if that would cause a 404 though.

Saxon Druce