|
@@ -148,10 +148,10 @@ def fetchDataADEI():
|
|
|
print "Data: " + first_value
|
|
|
print "\n"
|
|
|
|
|
|
- with open(".tmp.yaml", 'w') as stream_tmp:
|
|
|
+ with open("/tmp/.tmp.yaml", 'w') as stream_tmp:
|
|
|
stream_tmp.write(yaml.dump(cache_data, default_flow_style=False))
|
|
|
- src_file = os.getcwd() + "/.tmp.yaml"
|
|
|
- dst_file = os.getcwd() + "/cache.yaml"
|
|
|
+ src_file = os.getcwd() + "/tmp/.tmp.yaml"
|
|
|
+ dst_file = os.getcwd() + "/tmp/cache.yaml"
|
|
|
shutil.copy(src_file, dst_file)
|
|
|
|
|
|
|
|
@@ -169,7 +169,7 @@ class BaseHandler(tornado.web.RequestHandler):
|
|
|
|
|
|
class ListHandler(tornado.web.RequestHandler):
|
|
|
def get(self):
|
|
|
- with open("cache.yaml", 'r') as stream:
|
|
|
+ with open("/tmp/cache.yaml", 'r') as stream:
|
|
|
try:
|
|
|
#print(yaml.load(stream))
|
|
|
response = yaml.load(stream)
|
|
@@ -204,7 +204,7 @@ class DesignerHandler(tornado.web.RequestHandler):
|
|
|
@tornado.web.authenticated
|
|
|
def get(self):
|
|
|
print "In designer mode."
|
|
|
- with open("cache.yaml", 'r') as stream:
|
|
|
+ with open("/tmp/cache.yaml", 'r') as stream:
|
|
|
try:
|
|
|
#print(yaml.load(stream))
|
|
|
cache_data = yaml.load(stream)
|
|
@@ -403,7 +403,7 @@ class AdeiKatrinHandler(tornado.web.RequestHandler):
|
|
|
class GetDataHandler(tornado.web.RequestHandler):
|
|
|
def get(self):
|
|
|
cache_data = None
|
|
|
- with open("cache.yaml", 'r') as stream:
|
|
|
+ with open("/tmp/cache.yaml", 'r') as stream:
|
|
|
try:
|
|
|
#print(yaml.load(stream))
|
|
|
cache_data = yaml.load(stream)
|
|
@@ -438,7 +438,7 @@ class AuthLoginHandler(BaseHandler):
|
|
|
if auth:
|
|
|
self.set_current_user(username)
|
|
|
print "In designer mode."
|
|
|
- with open("cache.yaml", 'r') as stream:
|
|
|
+ with open("/tmp/cache.yaml", 'r') as stream:
|
|
|
try:
|
|
|
#print(yaml.load(stream))
|
|
|
cache_data = yaml.load(stream)
|