How to open a file in the parent directory in python in AppEngine?

Posted by GeekTantra on Stack Overflow See other posts from Stack Overflow or by GeekTantra
Published on 2010-05-02T11:09:40Z Indexed on 2010/05/02 11:37 UTC
Read the original article Hit count: 275

Filed under:
|

How to open a file in the parent directory in python in AppEngine?

I have a python file module/mod.py with the following code

f = open('../data.yml')
z = yaml.load(f)
f.close()

data.yml is in the parent dir of module. The error I get is

IOError: [Errno 13] file not accessible: '../data.yml'

I am using AppEngine SDK 1.3.3.

Is there a work around for this?

© Stack Overflow or respective owner

Related posts about google-app-engine

Related posts about python