0

Ok, I read a lot. There is many people with the same issue, but all answers was not helpful for me.

I'm trying to do this - http://googlecloudplatform.github.io/appengine-php-wordpress-starter-project/ , but each time I running the app, I have the same message:

> 2014-09-22 10:12:10 Running command: "['C:\\Python27\\pythonw.exe', 'C:\\Program Files (x86)\\Google\\google_appengine\\dev_appserver.py', '--skip_sdk_update_check=yes', '--port=8080', '--admin_port=8090', 'C:\\gae\\wp39']"
INFO     2014-09-22 10:12:12,089 devappserver2.py:725] Skipping SDK update check.
Traceback (most recent call last):
  File "C:\Program Files (x86)\Google\google_appengine\dev_appserver.py", line 82, in <module>
    _run_file(__file__, globals())
  File "C:\Program Files (x86)\Google\google_appengine\dev_appserver.py", line 78, in _run_file
    execfile(_PATHS.script_file(script_name), globals_)
  File "C:\Program Files (x86)\Google\google_appengine\google\appengine\tools\devappserver2\devappserver2.py", line 970, in <module>
    main()
  File "C:\Program Files (x86)\Google\google_appengine\google\appengine\tools\devappserver2\devappserver2.py", line 963, in main
    dev_server.start(options)
  File "C:\Program Files (x86)\Google\google_appengine\google\appengine\tools\devappserver2\devappserver2.py", line 768, in start
    request_data, storage_path, options, configuration)
  File "C:\Program Files (x86)\Google\google_appengine\google\appengine\tools\devappserver2\devappserver2.py", line 867, in _create_api_server
    default_gcs_bucket_name=options.default_gcs_bucket_name)
  File "C:\Program Files (x86)\Google\google_appengine\google\appengine\tools\devappserver2\api_server.py", line 364, in setup_stubs
    auto_id_policy=datastore_auto_id_policy)
  File "C:\Program Files (x86)\Google\google_appengine\google\appengine\datastore\datastore_sqlite_stub.py", line 604, in __init__
    factory=sql_conn)
sqlite3.OperationalError: unable to open database file
2014-09-22 10:12:12 (Process exited with code 1)

Windows 8, Python27, GAE 1.9.11

  1. I checked all permisions and started GAE as administrator.
  2. I tried Compatibility Mode (XP&Me, Win7) - nothing.
  3. I tried set TMP variable in app.yaml
  4. I tried to find "datastore.db" on all C: drive - found nothing.
  5. I tried start App from CMD (as Administrator), like this:
    • C:\gae\wp39>dev_appserver.py C:\gae\wp39
    • C:\gae\wp39>dev_appserver.py --datastore_path C:\temp\data.db C:\gae\wp39
    • C:\gae\wp39>dev_appserver.py --clear_datastore=yes --datastore_path C:\temp\data.db C:\gae\wp39

The same result.

When I try run app from console with attribute "--datastore_path C:\temp\data.db' , the system creates that file (about 9KB) , but still can't open database.

The folder "C:\Users\\AppData\Local\Temp\appengine.levalult" exists, but empty. I don't know what else to do.

Thanks. I will be grateful for any advice.

1
  • have you tried to update your GAE SDK? Commented Sep 25, 2014 at 9:59

1 Answer 1

1

Solve:

Change username to none Unicode or

Change the tmp and temp environment variable value to e:\ or

In the cmd prompt, do:

  1. Change env var value

    Set temp=e:\

    Set tmp=e:\

    2: run gae

    D:\Program Files (x86)\Google\google_appengine\launcher\GoogleAppEngineLauncher.exe

Reason:

In datastore_sqllite_stub.py,

In def __init__

Before the self.__connection = sqlite3.connect:

Add the following code:

    f = open( 'e:/tmp/a.log', 'w' )

    f.write( self.__datastore_file )

    f.write( '\n' )

    for name in os.environ.keys():

        f.write( '\n' )

        v = os.environ[name]  

        f.write( name ) 

        f.write( '   ' ) 

        f.write( v )

    f.close() 

self.__datastore_file = 'e:/tmp/datastore.db'

According to the code, the database file is located in:

c:\users\%username%\appdata\local\temp\appengine.xgogo\datastore.db

which equal to:

%TEMP%\ appengine.xgogo\datastore.db

Where the %Temp% is the environment variable.

When username have Unicode characters, make failed.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.