Skip to content

Commit

Permalink
Fix merge
Browse files Browse the repository at this point in the history
  • Loading branch information
lAngelP committed Mar 11, 2018
2 parents dcbd795 + df6e897 commit 1c119cd
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 12 deletions.
Binary file modified Database/__pycache__/__init__.cpython-36.pyc
Binary file not shown.
Binary file modified Database/__pycache__/data_base.cpython-36.pyc
Binary file not shown.
Binary file modified Streaming/__pycache__/streaming.cpython-36.pyc
Binary file not shown.
19 changes: 10 additions & 9 deletions Streaming/streaming.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import sys
sys.path.append("../")
#import sys
#sys.path.append("../")
import tweepy
from time import time, sleep
from Database.data_base import *
import time
from time import sleep
#from Database.data_base import *

class StreamData:
def __init__(self, id_tweet, url, posted_at, username, displayname, text, fav, rt):
Expand All @@ -29,9 +30,9 @@ def __init__(self):
def on_status(self, status):
global tfinal
global myStream
global evento
insertar_tweet_evento([status.user.screen_name, status.user.name, status.user.profile_background_image_url, status.user.followers_count,
status.user.friends_count], evento)
#global evento
#insertar_tweet_evento([status.user.screen_name, status.user.name, status.user.profile_background_image_url, status.user.followers_count,
# status.user.friends_count], evento)
if status.text[0:2] != "RT":
print("Received Tweet")

Expand All @@ -58,8 +59,8 @@ def get_auth(i, keys):


def start_streaming(hashtag, nombre, equipos, fecha, lugar, tinicio, duracion):
global evento
evento = insertar_evento(nombre, equipos, fecha, lugar)
#global evento
#evento = insertar_evento(nombre, equipos, fecha, lugar)
global tfinal
global myStream
#insertar_evento()
Expand Down
4 changes: 2 additions & 2 deletions server_camisetas/run_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ def load_binary(file):
@app.route('/createt_shirt')
def generatet_shirt():
time.sleep(3)
res = Flask.make_response(app, load_binary("img/final"+str(random.randint(1,5))+".jpg"))
res = Flask.make_response(app, load_binary("img/final"+str(random.randint(1,4))+".jpg"))
res.headers['Content-Type'] = 'image/jpg'

return res

if __name__ == '__main__':
app.run()
app.run(port=8080)
2 changes: 1 addition & 1 deletion website/data/test.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
758807u,972713377326948352
VivasComunica,972711122171244544

0 comments on commit 1c119cd

Please sign in to comment.