Merge pull request #3297 from FichteForks/pr/more-https

More https changes
This commit is contained in:
Adrian Sampson 2019-06-06 09:20:36 -04:00 committed by GitHub
commit c04462d8d2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 20 additions and 15 deletions

View file

@ -204,7 +204,7 @@ def input_(prompt=None):
"""
# raw_input incorrectly sends prompts to stderr, not stdout, so we
# use print_() explicitly to display prompts.
# http://bugs.python.org/issue1927
# https://bugs.python.org/issue1927
if prompt:
print_(prompt, end=u' ')
@ -475,7 +475,7 @@ def human_seconds_short(interval):
# Colorization.
# ANSI terminal colorization code heavily inspired by pygments:
# http://dev.pocoo.org/hg/pygments-main/file/b2deea5b5030/pygments/console.py
# https://bitbucket.org/birkenfeld/pygments-main/src/default/pygments/console.py
# (pygments is by Tim Hatch, Armin Ronacher, et al.)
COLOR_ESCAPE = "\x1b["
DARK_COLORS = {
@ -929,7 +929,7 @@ class CommonOptionsParser(optparse.OptionParser, object):
#
# This is a fairly generic subcommand parser for optparse. It is
# maintained externally here:
# http://gist.github.com/462717
# https://gist.github.com/462717
# There you will also find a better description of the code and a more
# succinct example program.

View file

@ -412,7 +412,7 @@ def syspath(path, prefix=True):
path = path.decode(encoding, 'replace')
# Add the magic prefix if it isn't already there.
# http://msdn.microsoft.com/en-us/library/windows/desktop/aa365247.aspx
# https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247.aspx
if prefix and not path.startswith(WINDOWS_MAGIC_PREFIX):
if path.startswith(u'\\\\'):
# UNC path. Final path should look like \\?\UNC\...
@ -563,7 +563,7 @@ def unique_path(path):
# Note: The Windows "reserved characters" are, of course, allowed on
# Unix. They are forbidden here because they cause problems on Samba
# shares, which are sufficiently common as to cause frequent problems.
# http://msdn.microsoft.com/en-us/library/windows/desktop/aa365247.aspx
# https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247.aspx
CHAR_REPLACE = [
(re.compile(r'[\\/]'), u'_'), # / and \ -- forbidden everywhere.
(re.compile(r'^\.'), u'_'), # Leading dot (hidden files on Unix).

View file

@ -224,7 +224,7 @@ class BeatportRelease(BeatportObject):
if 'category' in data:
self.category = data['category']
if 'slug' in data:
self.url = "http://beatport.com/release/{0}/{1}".format(
self.url = "https://beatport.com/release/{0}/{1}".format(
data['slug'], data['id'])
@ -252,8 +252,8 @@ class BeatportTrack(BeatportObject):
except ValueError:
pass
if 'slug' in data:
self.url = "http://beatport.com/track/{0}/{1}".format(data['slug'],
data['id'])
self.url = "https://beatport.com/track/{0}/{1}" \
.format(data['slug'], data['id'])
self.track_number = data.get('trackNumber')

View file

@ -64,7 +64,8 @@ class GstPlayer(object):
"""
# Set up the Gstreamer player. From the pygst tutorial:
# http://pygstdocs.berlios.de/pygst-tutorial/playbin.html
# https://pygstdocs.berlios.de/pygst-tutorial/playbin.html (gone)
# https://brettviren.github.io/pygst-tutorial-org/pygst-tutorial.html
####
# Updated to GStreamer 1.0 with:
# https://wiki.ubuntu.com/Novacut/GStreamer1.0

View file

@ -55,6 +55,7 @@ except ImportError:
from beets import plugins
from beets import ui
from beets import util
import beets
DIV_RE = re.compile(r'<(/?)div>?', re.I)
@ -406,7 +407,10 @@ class Genius(Backend):
class LyricsWiki(SymbolsReplaced):
"""Fetch lyrics from LyricsWiki."""
URL_PATTERN = 'http://lyrics.wikia.com/%s:%s'
if util.SNI_SUPPORTED:
URL_PATTERN = 'https://lyrics.wikia.com/%s:%s'
else:
URL_PATTERN = 'http://lyrics.wikia.com/%s:%s'
def fetch(self, artist, title):
url = self.build_url(artist, title)

View file

@ -22,7 +22,7 @@ class SpotifyPlugin(BeetsPlugin):
# Base URLs for the Spotify API
# Documentation: https://developer.spotify.com/web-api
oauth_token_url = 'https://accounts.spotify.com/api/token'
open_track_url = 'http://open.spotify.com/track/'
open_track_url = 'https://open.spotify.com/track/'
search_url = 'https://api.spotify.com/v1/search'
album_url = 'https://api.spotify.com/v1/albums/'
track_url = 'https://api.spotify.com/v1/tracks/'

View file

@ -5,7 +5,7 @@ Smart Playlist Plugin
beets queries every time your library changes. This plugin is specifically
created to work well with `MPD's`_ playlist functionality.
.. _MPD's: http://www.musicpd.org/
.. _MPD's: https://www.musicpd.org/
To use it, enable the ``smartplaylist`` plugin in your configuration
(see :ref:`using-plugins`).

View file

@ -90,7 +90,7 @@ for unsupported formats/browsers. There are a number of options for this:
.. _audio.js: https://kolber.github.io/audiojs/
.. _html5media: https://html5media.info/
.. _MediaElement.js: http://mediaelementjs.com/
.. _MediaElement.js: https://mediaelementjs.com/
.. _web-cors:

View file

@ -453,7 +453,7 @@ available via your package manager. On OS X, you can install it via Homebrew
with ``brew install bash-completion``; Homebrew will give you instructions for
sourcing the script.
.. _bash-completion: http://bash-completion.alioth.debian.org/
.. _bash-completion: https://github.com/scop/bash-completion
.. _bash: https://www.gnu.org/software/bash/
The completion script suggests names of subcommands and (after typing

View file

@ -459,7 +459,7 @@ class ParseIDTest(_common.TestCase):
def test_parse_id_url_finds_id(self):
id_string = "28e32c71-1450-463e-92bf-e0a46446fc11"
id_url = "http://musicbrainz.org/entity/%s" % id_string
id_url = "https://musicbrainz.org/entity/%s" % id_string
out = mb._parse_id(id_url)
self.assertEqual(out, id_string)