Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dbtenv which bug #37

Open
NiallRees opened this issue Oct 4, 2022 · 0 comments
Open

dbtenv which bug #37

NiallRees opened this issue Oct 4, 2022 · 0 comments

Comments

@NiallRees
Copy link
Contributor

There's a bug in running dbtenv which

dbtenv which

Traceback (most recent call last):
  File "/Users/niall.woodward/.local/bin/dbtenv", line 8, in <module>
    sys.exit(main())
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/main.py", line 168, in main
    which_subcommand.execute(parsed_args)
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/which.py", line 51, in execute
    version = dbtenv.version.get_version(self.env, adapter_type=adapter_type)
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/version.py", line 345, in get_version
    project_version = try_get_project_version(env, preferred_version, adapter_type)
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/version.py", line 309, in try_get_project_version
    installable_versions = dbtenv.versions.get_installable_versions(env, adapter_type=adapter_type)
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/versions.py", line 66, in get_installable_versions
    return dbtenv.pip.get_pypi_package_versions(adapter_type)
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/pip.py", line 65, in get_pypi_package_versions
    package_metadata = get_pypi_package_metadata(f"dbt-{adapter_type}")
  File "/Users/niall.woodward/.local/pipx/venvs/dbtenv-dbt-alias/lib/python3.8/site-packages/dbtenv/pip.py", line 61, in get_pypi_package_metadata
    with urllib.request.urlopen(package_json_url) as package_json_response:
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/urllib/request.py", line 222, in urlopen
    return opener.open(url, data, timeout)
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/urllib/request.py", line 525, in open
    response = self._open(req, data)
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/urllib/request.py", line 542, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/urllib/request.py", line 1397, in https_open
    return self.do_open(http.client.HTTPSConnection, req,
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/urllib/request.py", line 1354, in do_open
    h.request(req.get_method(), req.selector, req.data, headers,
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/http/client.py", line 1252, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/http/client.py", line 1263, in _send_request
    self.putrequest(method, url, **skips)
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/http/client.py", line 1097, in putrequest
    self._validate_path(url)
  File "/Users/niall.woodward/.pyenv/versions/3.8.9/lib/python3.8/http/client.py", line 1197, in _validate_path
    raise InvalidURL(f"URL can't contain control characters. {url!r} "
http.client.InvalidURL: URL can't contain control characters. "/pypi/dbt-('snowflake', None)/json" (found at least ' ')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant