Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -30,26 +30,9 @@ with fs.open('trends_chrome_extension_bucket/lastradartext.txt', 'rb') as file:
|
|
| 30 |
data_old = file.read()
|
| 31 |
print(data_old)
|
| 32 |
###download both text and image from cloud to display
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
destination_file_name= 'lastradartext.txt'
|
| 37 |
-
storage_client = storage.Client(project='createinsightsproject')
|
| 38 |
-
bucket = storage_client.bucket(bucket_name)
|
| 39 |
-
blob = bucket.blob(source_blob_name)
|
| 40 |
-
blob.download_to_filename(destination_file_name)
|
| 41 |
-
|
| 42 |
-
with open('lastradartext.txt', 'r') as file:
|
| 43 |
-
data_old = file.read()
|
| 44 |
-
"""
|
| 45 |
-
value1,value2,value3,value4,value5,value6=data_old.split('SEPERATOR')
|
| 46 |
-
|
| 47 |
-
source_blob_name = 'lasttechradar.png'
|
| 48 |
-
destination_file_name= 'lasttechradar.png'
|
| 49 |
-
storage_client = storage.Client()
|
| 50 |
-
bucket = storage_client.bucket(bucket_name)
|
| 51 |
-
blob = bucket.blob(source_blob_name)
|
| 52 |
-
blob.download_to_filename(destination_file_name)
|
| 53 |
|
| 54 |
def getstuff(openapikey):
|
| 55 |
dateforfilesave=datetime.today().strftime("%d-%m-%Y %I:%M%p")
|
|
|
|
| 30 |
data_old = file.read()
|
| 31 |
print(data_old)
|
| 32 |
###download both text and image from cloud to display
|
| 33 |
+
value1,value2,value3,value4,value5,value6=str(data_old).split('SEPERATOR')
|
| 34 |
+
|
| 35 |
+
fs.get_file('trends_chrome_extension_bucket/lasttechradar.png')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
|
| 37 |
def getstuff(openapikey):
|
| 38 |
dateforfilesave=datetime.today().strftime("%d-%m-%Y %I:%M%p")
|