prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Vaughnlive RTMP port changed from 1935 to 2935
  Very brief bug, very simple fix.
  
  rtmp_server_map for all requests uses 192.240.105.171:1935 and doesn't work. (No data returned from stream)
  rtmp_server_map change all requests to 192.240.105.171:2935 works for me.
  
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `src/streamlink/plugins/vaughnlive.py`
  Content:
  ```
  1 import itertools
  2 import logging
  3 import random
  4 import re
  5 import ssl
  6 
  7 import websocket
  8 
  9 from streamlink.plugin import Plugin
  10 from streamlink.plugin.api import useragents
  11 from streamlink.stream import RTMPStream
  12 
  13 _url_re = re.compile(r"""
  14     http(s)?://(\w+\.)?
  15     (?P<domain>vaughnlive|breakers|instagib|vapers|pearltime).tv
  16     (/embed/video)?
  17     /(?P<channel>[^/&?]+)
  18 """, re.VERBOSE)
  19 
  20 
  21 class VLWebSocket(websocket.WebSocket):
  22     def __init__(self, **_):
  23         self.session = _.pop("session")
  24         self.logger = logging.getLogger("streamlink.plugins.vaughnlive.websocket")
  25         sslopt = _.pop("sslopt", {})
  26         sslopt["cert_reqs"] = ssl.CERT_NONE
  27         super(VLWebSocket, self).__init__(sslopt=sslopt, **_)
  28 
  29     def send(self, payload, opcode=websocket.ABNF.OPCODE_TEXT):
  30         self.logger.debug("Sending message: {0}", payload)
  31         return super(VLWebSocket, self).send(payload + "\n\x00", opcode)
  32 
  33     def recv(self):
  34         d = super(VLWebSocket, self).recv().replace("\n", "").replace("\x00", "")
  35         return d.split(" ", 1)
  36 
  37 
  38 class VaughnLive(Plugin):
  39     servers = ["wss://sapi-ws-{0}x{1:02}.vaughnlive.tv".format(x, y) for x, y in itertools.product(range(1, 3),
  40                                                                                                    range(1, 6))]
  41     origin = "https://vaughnlive.tv"
  42     rtmp_server_map = {
  43         "594140c69edad": "192.240.105.171:1935",
  44         "585c4cab1bef1": "192.240.105.171:1935",
  45         "5940d648b3929": "192.240.105.171:1935",
  46         "5941854b39bc4": "192.240.105.171:1935"
  47     }
  48     name_remap = {"#vl": "live", "#btv": "btv", "#pt": "pt", "#igb": "instagib", "#vtv": "vtv"}
  49     domain_map = {"vaughnlive": "#vl", "breakers": "#btv", "instagib": "#igb", "vapers": "#vtv", "pearltime": "#pt"}
  50 
  51     @classmethod
  52     def can_handle_url(cls, url):
  53         return _url_re.match(url)
  54 
  55     def api_url(self):
  56         return random.choice(self.servers)
  57 
  58     def parse_ack(self, action, message):
  59         if action.endswith("3"):
  60             channel, _, viewers, token, server, choked, is_live, chls, trns, ingest = message.split(";")
  61             is_live = is_live == "1"
  62             viewers = int(viewers)
  63             self.logger.debug("Viewers: {0}, isLive={1}", viewers, is_live)
  64             domain, channel = channel.split("-", 1)
  65             return is_live, server, domain, channel, token, ingest
  66         else:
  67             self.logger.error("Unhandled action format: {0}", action)
  68 
  69     def _get_info(self, stream_name):
  70         server = self.api_url()
  71         self.logger.debug("Connecting to API: {0}", server)
  72         ws = websocket.create_connection(server,
  73                                          header=["User-Agent: {0}".format(useragents.CHROME)],
  74                                          origin=self.origin,
  75                                          class_=VLWebSocket,
  76                                          session=self.session)
  77         ws.send("MVN LOAD3 {0}".format(stream_name))
  78         action, message = ws.recv()
  79         return self.parse_ack(action, message)
  80 
  81     def _get_rtmp_streams(self, server, domain, channel, token):
  82         rtmp_server = self.rtmp_server_map.get(server, server)
  83 
  84         url = "rtmp://{0}/live?{1}".format(rtmp_server, token)
  85 
  86         yield "live", RTMPStream(self.session, params={
  87             "rtmp": url,
  88             "pageUrl": self.url,
  89             "playpath": "{0}_{1}".format(self.name_remap.get(domain, "live"), channel),
  90             "live": True
  91         })
  92 
  93     def _get_streams(self):
  94         m = _url_re.match(self.url)
  95         if m:
  96             stream_name = "{0}-{1}".format(self.domain_map[(m.group("domain").lower())],
  97                                            m.group("channel"))
  98 
  99             is_live, server, domain, channel, token, ingest = self._get_info(stream_name)
  100 
  101             if not is_live:
  102                 self.logger.info("Stream is currently off air")
  103             else:
  104                 self.logger.info("Stream powered by VaughnSoft - remember to support them.")
  105                 for s in self._get_rtmp_streams(server, domain, channel, token):
  106                     yield s
  107 
  108 
  109 __plugin__ = VaughnLive
  110
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/src/streamlink/plugins/vaughnlive.py b/src/streamlink/plugins/vaughnlive.py
  --- a/src/streamlink/plugins/vaughnlive.py
  +++ b/src/streamlink/plugins/vaughnlive.py
  @@ -40,10 +40,10 @@
                                                                                                      range(1, 6))]
       origin = "https://vaughnlive.tv"
       rtmp_server_map = {
  -        "594140c69edad": "192.240.105.171:1935",
  -        "585c4cab1bef1": "192.240.105.171:1935",
  -        "5940d648b3929": "192.240.105.171:1935",
  -        "5941854b39bc4": "192.240.105.171:1935"
  +        "594140c69edad": "192.240.105.171:2935",
  +        "585c4cab1bef1": "192.240.105.171:2935",
  +        "5940d648b3929": "192.240.105.171:2935",
  +        "5941854b39bc4": "192.240.105.171:2935"
       }
       name_remap = {"#vl": "live", "#btv": "btv", "#pt": "pt", "#igb": "instagib", "#vtv": "vtv"}
       domain_map = {"vaughnlive": "#vl", "breakers": "#btv", "instagib": "#igb", "vapers": "#vtv", "pearltime": "#pt"}
  
verification_info: {"golden_diff": "diff --git a/src/streamlink/plugins/vaughnlive.py b/src/streamlink/plugins/vaughnlive.py\n--- a/src/streamlink/plugins/vaughnlive.py\n+++ b/src/streamlink/plugins/vaughnlive.py\n@@ -40,10 +40,10 @@\n                                                                                                    range(1, 6))]\n     origin = \"https://vaughnlive.tv\"\n     rtmp_server_map = {\n-        \"594140c69edad\": \"192.240.105.171:1935\",\n-        \"585c4cab1bef1\": \"192.240.105.171:1935\",\n-        \"5940d648b3929\": \"192.240.105.171:1935\",\n-        \"5941854b39bc4\": \"192.240.105.171:1935\"\n+        \"594140c69edad\": \"192.240.105.171:2935\",\n+        \"585c4cab1bef1\": \"192.240.105.171:2935\",\n+        \"5940d648b3929\": \"192.240.105.171:2935\",\n+        \"5941854b39bc4\": \"192.240.105.171:2935\"\n     }\n     name_remap = {\"#vl\": \"live\", \"#btv\": \"btv\", \"#pt\": \"pt\", \"#igb\": \"instagib\", \"#vtv\": \"vtv\"}\n     domain_map = {\"vaughnlive\": \"#vl\", \"breakers\": \"#btv\", \"instagib\": \"#igb\", \"vapers\": \"#vtv\", \"pearltime\": \"#pt\"}\n", "issue": "Vaughnlive RTMP port changed from 1935 to 2935\nVery brief bug, very simple fix.\r\n\r\nrtmp_server_map for all requests uses 192.240.105.171:1935 and doesn't work. (No data returned from stream)\r\nrtmp_server_map change all requests to 192.240.105.171:2935 works for me.\r\n\n", "before_files": [{"content": "import itertools\nimport logging\nimport random\nimport re\nimport ssl\n\nimport websocket\n\nfrom streamlink.plugin import Plugin\nfrom streamlink.plugin.api import useragents\nfrom streamlink.stream import RTMPStream\n\n_url_re = re.compile(r\"\"\"\n    http(s)?://(\\w+\\.)?\n    (?P<domain>vaughnlive|breakers|instagib|vapers|pearltime).tv\n    (/embed/video)?\n    /(?P<channel>[^/&?]+)\n\"\"\", re.VERBOSE)\n\n\nclass VLWebSocket(websocket.WebSocket):\n    def __init__(self, **_):\n        self.session = _.pop(\"session\")\n        self.logger = logging.getLogger(\"streamlink.plugins.vaughnlive.websocket\")\n        sslopt = _.pop(\"sslopt\", {})\n        sslopt[\"cert_reqs\"] = ssl.CERT_NONE\n        super(VLWebSocket, self).__init__(sslopt=sslopt, **_)\n\n    def send(self, payload, opcode=websocket.ABNF.OPCODE_TEXT):\n        self.logger.debug(\"Sending message: {0}\", payload)\n        return super(VLWebSocket, self).send(payload + \"\\n\\x00\", opcode)\n\n    def recv(self):\n        d = super(VLWebSocket, self).recv().replace(\"\\n\", \"\").replace(\"\\x00\", \"\")\n        return d.split(\" \", 1)\n\n\nclass VaughnLive(Plugin):\n    servers = [\"wss://sapi-ws-{0}x{1:02}.vaughnlive.tv\".format(x, y) for x, y in itertools.product(range(1, 3),\n                                                                                                   range(1, 6))]\n    origin = \"https://vaughnlive.tv\"\n    rtmp_server_map = {\n        \"594140c69edad\": \"192.240.105.171:1935\",\n        \"585c4cab1bef1\": \"192.240.105.171:1935\",\n        \"5940d648b3929\": \"192.240.105.171:1935\",\n        \"5941854b39bc4\": \"192.240.105.171:1935\"\n    }\n    name_remap = {\"#vl\": \"live\", \"#btv\": \"btv\", \"#pt\": \"pt\", \"#igb\": \"instagib\", \"#vtv\": \"vtv\"}\n    domain_map = {\"vaughnlive\": \"#vl\", \"breakers\": \"#btv\", \"instagib\": \"#igb\", \"vapers\": \"#vtv\", \"pearltime\": \"#pt\"}\n\n    @classmethod\n    def can_handle_url(cls, url):\n        return _url_re.match(url)\n\n    def api_url(self):\n        return random.choice(self.servers)\n\n    def parse_ack(self, action, message):\n        if action.endswith(\"3\"):\n            channel, _, viewers, token, server, choked, is_live, chls, trns, ingest = message.split(\";\")\n            is_live = is_live == \"1\"\n            viewers = int(viewers)\n            self.logger.debug(\"Viewers: {0}, isLive={1}\", viewers, is_live)\n            domain, channel = channel.split(\"-\", 1)\n            return is_live, server, domain, channel, token, ingest\n        else:\n            self.logger.error(\"Unhandled action format: {0}\", action)\n\n    def _get_info(self, stream_name):\n        server = self.api_url()\n        self.logger.debug(\"Connecting to API: {0}\", server)\n        ws = websocket.create_connection(server,\n                                         header=[\"User-Agent: {0}\".format(useragents.CHROME)],\n                                         origin=self.origin,\n                                         class_=VLWebSocket,\n                                         session=self.session)\n        ws.send(\"MVN LOAD3 {0}\".format(stream_name))\n        action, message = ws.recv()\n        return self.parse_ack(action, message)\n\n    def _get_rtmp_streams(self, server, domain, channel, token):\n        rtmp_server = self.rtmp_server_map.get(server, server)\n\n        url = \"rtmp://{0}/live?{1}\".format(rtmp_server, token)\n\n        yield \"live\", RTMPStream(self.session, params={\n            \"rtmp\": url,\n            \"pageUrl\": self.url,\n            \"playpath\": \"{0}_{1}\".format(self.name_remap.get(domain, \"live\"), channel),\n            \"live\": True\n        })\n\n    def _get_streams(self):\n        m = _url_re.match(self.url)\n        if m:\n            stream_name = \"{0}-{1}\".format(self.domain_map[(m.group(\"domain\").lower())],\n                                           m.group(\"channel\"))\n\n            is_live, server, domain, channel, token, ingest = self._get_info(stream_name)\n\n            if not is_live:\n                self.logger.info(\"Stream is currently off air\")\n            else:\n                self.logger.info(\"Stream powered by VaughnSoft - remember to support them.\")\n                for s in self._get_rtmp_streams(server, domain, channel, token):\n                    yield s\n\n\n__plugin__ = VaughnLive\n", "path": "src/streamlink/plugins/vaughnlive.py"}], "after_files": [{"content": "import itertools\nimport logging\nimport random\nimport re\nimport ssl\n\nimport websocket\n\nfrom streamlink.plugin import Plugin\nfrom streamlink.plugin.api import useragents\nfrom streamlink.stream import RTMPStream\n\n_url_re = re.compile(r\"\"\"\n    http(s)?://(\\w+\\.)?\n    (?P<domain>vaughnlive|breakers|instagib|vapers|pearltime).tv\n    (/embed/video)?\n    /(?P<channel>[^/&?]+)\n\"\"\", re.VERBOSE)\n\n\nclass VLWebSocket(websocket.WebSocket):\n    def __init__(self, **_):\n        self.session = _.pop(\"session\")\n        self.logger = logging.getLogger(\"streamlink.plugins.vaughnlive.websocket\")\n        sslopt = _.pop(\"sslopt\", {})\n        sslopt[\"cert_reqs\"] = ssl.CERT_NONE\n        super(VLWebSocket, self).__init__(sslopt=sslopt, **_)\n\n    def send(self, payload, opcode=websocket.ABNF.OPCODE_TEXT):\n        self.logger.debug(\"Sending message: {0}\", payload)\n        return super(VLWebSocket, self).send(payload + \"\\n\\x00\", opcode)\n\n    def recv(self):\n        d = super(VLWebSocket, self).recv().replace(\"\\n\", \"\").replace(\"\\x00\", \"\")\n        return d.split(\" \", 1)\n\n\nclass VaughnLive(Plugin):\n    servers = [\"wss://sapi-ws-{0}x{1:02}.vaughnlive.tv\".format(x, y) for x, y in itertools.product(range(1, 3),\n                                                                                                   range(1, 6))]\n    origin = \"https://vaughnlive.tv\"\n    rtmp_server_map = {\n        \"594140c69edad\": \"192.240.105.171:2935\",\n        \"585c4cab1bef1\": \"192.240.105.171:2935\",\n        \"5940d648b3929\": \"192.240.105.171:2935\",\n        \"5941854b39bc4\": \"192.240.105.171:2935\"\n    }\n    name_remap = {\"#vl\": \"live\", \"#btv\": \"btv\", \"#pt\": \"pt\", \"#igb\": \"instagib\", \"#vtv\": \"vtv\"}\n    domain_map = {\"vaughnlive\": \"#vl\", \"breakers\": \"#btv\", \"instagib\": \"#igb\", \"vapers\": \"#vtv\", \"pearltime\": \"#pt\"}\n\n    @classmethod\n    def can_handle_url(cls, url):\n        return _url_re.match(url)\n\n    def api_url(self):\n        return random.choice(self.servers)\n\n    def parse_ack(self, action, message):\n        if action.endswith(\"3\"):\n            channel, _, viewers, token, server, choked, is_live, chls, trns, ingest = message.split(\";\")\n            is_live = is_live == \"1\"\n            viewers = int(viewers)\n            self.logger.debug(\"Viewers: {0}, isLive={1}\", viewers, is_live)\n            domain, channel = channel.split(\"-\", 1)\n            return is_live, server, domain, channel, token, ingest\n        else:\n            self.logger.error(\"Unhandled action format: {0}\", action)\n\n    def _get_info(self, stream_name):\n        server = self.api_url()\n        self.logger.debug(\"Connecting to API: {0}\", server)\n        ws = websocket.create_connection(server,\n                                         header=[\"User-Agent: {0}\".format(useragents.CHROME)],\n                                         origin=self.origin,\n                                         class_=VLWebSocket,\n                                         session=self.session)\n        ws.send(\"MVN LOAD3 {0}\".format(stream_name))\n        action, message = ws.recv()\n        return self.parse_ack(action, message)\n\n    def _get_rtmp_streams(self, server, domain, channel, token):\n        rtmp_server = self.rtmp_server_map.get(server, server)\n\n        url = \"rtmp://{0}/live?{1}\".format(rtmp_server, token)\n\n        yield \"live\", RTMPStream(self.session, params={\n            \"rtmp\": url,\n            \"pageUrl\": self.url,\n            \"playpath\": \"{0}_{1}\".format(self.name_remap.get(domain, \"live\"), channel),\n            \"live\": True\n        })\n\n    def _get_streams(self):\n        m = _url_re.match(self.url)\n        if m:\n            stream_name = \"{0}-{1}\".format(self.domain_map[(m.group(\"domain\").lower())],\n                                           m.group(\"channel\"))\n\n            is_live, server, domain, channel, token, ingest = self._get_info(stream_name)\n\n            if not is_live:\n                self.logger.info(\"Stream is currently off air\")\n            else:\n                self.logger.info(\"Stream powered by VaughnSoft - remember to support them.\")\n                for s in self._get_rtmp_streams(server, domain, channel, token):\n                    yield s\n\n\n__plugin__ = VaughnLive\n", "path": "src/streamlink/plugins/vaughnlive.py"}]}