Skip to content

Commit

Permalink
Support custom musicbrainz servers
Browse files Browse the repository at this point in the history
I had to fork python-musicbrainzngs to add HTTPS support because
alastair/python-musicbrainzngs#197 has not
been resolved yet.
  • Loading branch information
mutantmonkey committed Nov 25, 2016
1 parent 1e8e31d commit 13cab30
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ ldap3==1.4.0
Mako==1.0.4
Markdown==2.6.7
MarkupSafe==0.23
musicbrainzngs==0.6
netaddr==0.7.18
passlib==1.6.5
psycopg2==2.6.2
Expand All @@ -43,3 +42,4 @@ vine==1.1.3
webencodings==0.5
Werkzeug==0.11.11
git+https://github.com/wuvt/orthrus
git+https://github.com/wuvt/python-musicbrainzngs
4 changes: 4 additions & 0 deletions wuvt/admin/library/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,8 @@ def library_fixup_tracks(key, page=1):
@bp.route('/library/track/<int:id>', methods=['GET', 'POST'])
@check_access('library')
def library_track(id):
musicbrainzngs.set_hostname(current_app.config['MUSICBRAINZ_HOSTNAME'])

track = Track.query.get_or_404(id)
edit_from = request.args.get('from', None)
error_fields = []
Expand Down Expand Up @@ -225,6 +227,8 @@ def library_track(id):
@bp.route('/library/track/<int:id>/musicbrainz', methods=['GET', 'POST'])
@check_access('library')
def library_track_musicbrainz(id):
musicbrainzngs.set_hostname(current_app.config['MUSICBRAINZ_HOSTNAME'])

track = Track.query.get_or_404(id)
edit_from = request.args.get('from', None)

Expand Down
1 change: 1 addition & 0 deletions wuvt/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
TRACKMAN_LABEL_BLACKLIST = ["same"]

ARCHIVE_BASE_URL = ""
MUSICBRAINZ_HOSTNAME = "musicbrainz.org"

ADMINS = []
MAIL_FROM = "noreply@localhost"
Expand Down

1 comment on commit 13cab30

@Freso
Copy link

@Freso Freso commented on 13cab30 Feb 27, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey :) Since you're using MusicBrainz you should definitely contact us so we can get you listed as a supporter!

Edit: Nevermind. I double-double checked and now I see you're already there. 🙄 Sorry! Carry on! 😇

Please sign in to comment.