prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  `meltano select tap-gitlab tags "*"` fails on Windows
  Example: https://gitlab.com/meltano/legacy-ci/meltano/-/jobs/2653845782
  
  This occurs with Meltano built from `main`, i.e. `fb6ed89799eb341bea295350ea809e5049ee7ca6`.
  
  </issue>
  <code>
  [start of src/meltano/cli/cli.py]
  1 import logging  # noqa: D100
  2 import sys
  3 import warnings  # noqa: F401
  4 
  5 import click
  6 
  7 import meltano
  8 from meltano.core.behavior.versioned import IncompatibleVersionError
  9 from meltano.core.logging import LEVELS, setup_logging
  10 from meltano.core.project import Project, ProjectNotFound
  11 from meltano.core.project_settings_service import ProjectSettingsService
  12 
  13 logger = logging.getLogger(__name__)
  14 
  15 
  16 @click.group(invoke_without_command=True, no_args_is_help=True)
  17 @click.option("--log-level", type=click.Choice(LEVELS.keys()))
  18 @click.option(
  19     "--log-config", type=str, help="Path to a python logging yaml config file."
  20 )
  21 @click.option("-v", "--verbose", count=True, help="Not used.")
  22 @click.option(
  23     "--environment",
  24     envvar="MELTANO_ENVIRONMENT",
  25     help="Meltano environment name.",
  26 )
  27 @click.option(
  28     "--no-environment", is_flag=True, default=False, help="Don't use any environment."
  29 )
  30 @click.version_option(version=meltano.__version__, prog_name="meltano")
  31 @click.pass_context
  32 def cli(  # noqa: WPS231
  33     ctx,
  34     log_level: str,
  35     log_config: str,
  36     verbose: int,
  37     environment: str,
  38     no_environment: bool,
  39 ):  # noqa: WPS231
  40     """
  41     ELT for the DataOps era.
  42 
  43     \b\nRead more at https://www.meltano.com/docs/command-line-interface.html
  44     """
  45     if log_level:
  46         ProjectSettingsService.config_override["cli.log_level"] = log_level
  47 
  48     if log_config:
  49         ProjectSettingsService.config_override["cli.log_config"] = log_config
  50 
  51     ctx.ensure_object(dict)
  52     ctx.obj["verbosity"] = verbose
  53     try:  # noqa: WPS229
  54         project = Project.find()
  55         setup_logging(project)
  56 
  57         readonly = ProjectSettingsService(project).get("project_readonly")
  58         if readonly:
  59             project.readonly = True
  60         if project.readonly:
  61             logger.debug("Project is read-only.")
  62 
  63         # detect active environment
  64         selected_environment = None
  65         if no_environment or (environment and environment.lower() == "null"):
  66             logger.info("No environment is active")
  67         elif environment:
  68             selected_environment = environment
  69         elif project.meltano.default_environment:
  70             selected_environment = project.meltano.default_environment
  71         # activate environment
  72         if selected_environment:
  73             project.activate_environment(selected_environment)
  74             logger.info(
  75                 "Environment '%s' is active", selected_environment  # noqa: WPS323
  76             )
  77 
  78         ctx.obj["project"] = project
  79     except ProjectNotFound:
  80         ctx.obj["project"] = None
  81     except IncompatibleVersionError:
  82         click.secho(
  83             "This Meltano project is incompatible with this version of `meltano`.",
  84             fg="yellow",
  85         )
  86         click.echo(
  87             "For more details, visit http://meltano.com/docs/installation.html#upgrading-meltano-version"
  88         )
  89         sys.exit(3)
  90
  [end of src/meltano/cli/cli.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/src/meltano/cli/cli.py b/src/meltano/cli/cli.py
  --- a/src/meltano/cli/cli.py
  +++ b/src/meltano/cli/cli.py
  @@ -1,6 +1,6 @@
   import logging  # noqa: D100
   import sys
  -import warnings  # noqa: F401
  +from typing import NoReturn
   
   import click
   
  @@ -13,7 +13,28 @@
   logger = logging.getLogger(__name__)
   
   
  -@click.group(invoke_without_command=True, no_args_is_help=True)
  +class NoWindowsGlobbingGroup(click.Group):
  +    """A Click group that does not perform glob expansion on Windows.
  +
  +    This restores the behaviour of Click's globbing to how it was before v8.
  +    Click (as of version 8.1.3) ignores quotes around an asterisk, which makes
  +    it behave differently than most shells that support globbing, and make some
  +    typical Meltano commands fail, e.g. `meltano select tap-gitlab tags "*"`.
  +    """
  +
  +    def main(self, *args, **kwargs) -> NoReturn:
  +        """Invoke the Click CLI with Windows globbing disabled.
  +
  +        Parameters:
  +            args: Positional arguments for the Click group.
  +            kwargs: Keyword arguments for the Click group.
  +        """
  +        return super().main(*args, windows_expand_args=False, **kwargs)
  +
  +
  +@click.group(
  +    cls=NoWindowsGlobbingGroup, invoke_without_command=True, no_args_is_help=True
  +)
   @click.option("--log-level", type=click.Choice(LEVELS.keys()))
   @click.option(
       "--log-config", type=str, help="Path to a python logging yaml config file."
  
verification_info: {"golden_diff": "diff --git a/src/meltano/cli/cli.py b/src/meltano/cli/cli.py\n--- a/src/meltano/cli/cli.py\n+++ b/src/meltano/cli/cli.py\n@@ -1,6 +1,6 @@\n import logging  # noqa: D100\n import sys\n-import warnings  # noqa: F401\n+from typing import NoReturn\n \n import click\n \n@@ -13,7 +13,28 @@\n logger = logging.getLogger(__name__)\n \n \n-@click.group(invoke_without_command=True, no_args_is_help=True)\n+class NoWindowsGlobbingGroup(click.Group):\n+    \"\"\"A Click group that does not perform glob expansion on Windows.\n+\n+    This restores the behaviour of Click's globbing to how it was before v8.\n+    Click (as of version 8.1.3) ignores quotes around an asterisk, which makes\n+    it behave differently than most shells that support globbing, and make some\n+    typical Meltano commands fail, e.g. `meltano select tap-gitlab tags \"*\"`.\n+    \"\"\"\n+\n+    def main(self, *args, **kwargs) -> NoReturn:\n+        \"\"\"Invoke the Click CLI with Windows globbing disabled.\n+\n+        Parameters:\n+            args: Positional arguments for the Click group.\n+            kwargs: Keyword arguments for the Click group.\n+        \"\"\"\n+        return super().main(*args, windows_expand_args=False, **kwargs)\n+\n+\n+@click.group(\n+    cls=NoWindowsGlobbingGroup, invoke_without_command=True, no_args_is_help=True\n+)\n @click.option(\"--log-level\", type=click.Choice(LEVELS.keys()))\n @click.option(\n     \"--log-config\", type=str, help=\"Path to a python logging yaml config file.\"\n", "issue": "`meltano select tap-gitlab tags \"*\"` fails on Windows\nExample: https://gitlab.com/meltano/legacy-ci/meltano/-/jobs/2653845782\r\n\r\nThis occurs with Meltano built from `main`, i.e. `fb6ed89799eb341bea295350ea809e5049ee7ca6`.\n", "before_files": [{"content": "import logging  # noqa: D100\nimport sys\nimport warnings  # noqa: F401\n\nimport click\n\nimport meltano\nfrom meltano.core.behavior.versioned import IncompatibleVersionError\nfrom meltano.core.logging import LEVELS, setup_logging\nfrom meltano.core.project import Project, ProjectNotFound\nfrom meltano.core.project_settings_service import ProjectSettingsService\n\nlogger = logging.getLogger(__name__)\n\n\n@click.group(invoke_without_command=True, no_args_is_help=True)\n@click.option(\"--log-level\", type=click.Choice(LEVELS.keys()))\n@click.option(\n    \"--log-config\", type=str, help=\"Path to a python logging yaml config file.\"\n)\n@click.option(\"-v\", \"--verbose\", count=True, help=\"Not used.\")\n@click.option(\n    \"--environment\",\n    envvar=\"MELTANO_ENVIRONMENT\",\n    help=\"Meltano environment name.\",\n)\n@click.option(\n    \"--no-environment\", is_flag=True, default=False, help=\"Don't use any environment.\"\n)\n@click.version_option(version=meltano.__version__, prog_name=\"meltano\")\n@click.pass_context\ndef cli(  # noqa: WPS231\n    ctx,\n    log_level: str,\n    log_config: str,\n    verbose: int,\n    environment: str,\n    no_environment: bool,\n):  # noqa: WPS231\n    \"\"\"\n    ELT for the DataOps era.\n\n    \\b\\nRead more at https://www.meltano.com/docs/command-line-interface.html\n    \"\"\"\n    if log_level:\n        ProjectSettingsService.config_override[\"cli.log_level\"] = log_level\n\n    if log_config:\n        ProjectSettingsService.config_override[\"cli.log_config\"] = log_config\n\n    ctx.ensure_object(dict)\n    ctx.obj[\"verbosity\"] = verbose\n    try:  # noqa: WPS229\n        project = Project.find()\n        setup_logging(project)\n\n        readonly = ProjectSettingsService(project).get(\"project_readonly\")\n        if readonly:\n            project.readonly = True\n        if project.readonly:\n            logger.debug(\"Project is read-only.\")\n\n        # detect active environment\n        selected_environment = None\n        if no_environment or (environment and environment.lower() == \"null\"):\n            logger.info(\"No environment is active\")\n        elif environment:\n            selected_environment = environment\n        elif project.meltano.default_environment:\n            selected_environment = project.meltano.default_environment\n        # activate environment\n        if selected_environment:\n            project.activate_environment(selected_environment)\n            logger.info(\n                \"Environment '%s' is active\", selected_environment  # noqa: WPS323\n            )\n\n        ctx.obj[\"project\"] = project\n    except ProjectNotFound:\n        ctx.obj[\"project\"] = None\n    except IncompatibleVersionError:\n        click.secho(\n            \"This Meltano project is incompatible with this version of `meltano`.\",\n            fg=\"yellow\",\n        )\n        click.echo(\n            \"For more details, visit http://meltano.com/docs/installation.html#upgrading-meltano-version\"\n        )\n        sys.exit(3)\n", "path": "src/meltano/cli/cli.py"}]}