Skip to content

Commit b1c42b2

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents 54e7673 + 807eb69 commit b1c42b2

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@ RUN touch /etc/service/dataset_eval/down
136136

137137
# Add cron jobs
138138
COPY ./docker/cron/crontab /etc/cron.d/acousticbrainz
139+
RUN chmod 0644 /etc/cron.d/acousticbrainz
139140
COPY ./docker/cron/cron-config.service /etc/service/cron-config/run
140141
COPY docker/cron/consul-template-cron-config.conf /etc/consul-template-cron-config.conf
141142
RUN touch /etc/service/cron/down

webserver/errors.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ def not_found(error):
3232
return jsonify_error(error)
3333
return render_template('errors/404.html', error=error), 404
3434

35+
@app.errorhandler(429)
36+
def too_many_requests(error):
37+
# always returning JSON because this is only raised from API endpoints
38+
return jsonify_error(error, 429)
39+
3540
@app.errorhandler(500)
3641
def internal_server_error(error):
3742
if request.path.startswith(webserver.API_PREFIX):

0 commit comments

Comments
 (0)