Skip to content

Commit d3906ed

Browse files
committed
update uwsgi config in app.ini
1 parent 338817a commit d3906ed

7 files changed

+8
-7
lines changed

Diff for: Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ RUN pip3 --no-cache-dir install -r requirements.txt
1313
# the path.
1414
ENV MARIADB_PLUGIN_DIR /usr/lib/mariadb/plugin
1515

16-
#EXPOSE 5000
17-
#CMD ["python3", "server.py"]
16+
# EXPOSE 5000
17+
# CMD ["python3", "server.py"]
1818

1919
#run the command to start uWSGI
2020
CMD ["uwsgi", "app.ini"]

Diff for: app.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[uwsgi]
22
wsgi-file = server.py
33
callable = connex_app
4-
socket = :5000
4+
http = :5000
55
processes = 4
66
threads = 2
77
master = true

Diff for: config.py

+3
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
app.config['SQLALCHEMY_ECHO'] = False
1818
app.config['SQLALCHEMY_DATABASE_URI'] = os.getenv("SPONGE_DB_URI")
1919
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
20+
app.config['DEBUG '] = True
21+
app.config['TESTING '] = True
22+
2023

2124
@app.after_request
2225
def add_header(response):

Diff for: externalInformation.py

-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ def getAutocomplete(searchString):
1414
data = models.Gene.query.with_entities(models.Gene.ensg_number, models.Gene.gene_symbol) \
1515
.filter(models.Gene.ensg_number.ilike(searchString + "%")) \
1616
.all()
17-
print(data)
1817
if len(data) > 0:
1918
return models.GeneSchemaShort(many=True).dump(data).data
2019
else:

Diff for: geneInteraction.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -809,6 +809,6 @@ def get_distinc_ceRNA_sets(disease_name):
809809
#return models.DistinctGeneSetSchema(many=True).dump(results).data
810810
#else:
811811
#abort(404, "No data found with input parameter")
812-
return print("Null")
812+
return
813813

814814
get_distinc_ceRNA_sets(disease_name="kidney clear")

Diff for: server.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
# create a URL route in our application for "/"
1818
@connex_app.route("/")
1919
def home():
20-
return None
20+
return "SPONGEdb API"
2121

2222
if __name__ == "__main__":
2323
connex_app.run()

Diff for: survivalAnalysis.py

-1
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ def get_survival_rate(disease_name, ensg_number = None, gene_symbol = None, samp
8989

9090
if (len(patient) > 0):
9191
sample_IDs = [i.patient_information_ID for i in patient]
92-
print(sample_IDs)
9392
# save all needed queries to get correct results
9493
queries.append(models.SurvivalRate.patient_information_ID.in_(sample_IDs))
9594
else:

0 commit comments

Comments
 (0)