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

404 on GitLab causes yaml.parser.ParserError #1

Open
tueda opened this issue Feb 26, 2023 · 0 comments
Open

404 on GitLab causes yaml.parser.ParserError #1

tueda opened this issue Feb 26, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@tueda
Copy link
Owner

tueda commented Feb 26, 2023

.pre-commit-config.yaml:

repos:
-   repo: https://gitlab.com/pycqa/flake8
    rev: 3.9.2
    hooks:
    -   id: flake8
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/tueda/work/py-check-updates/check_updates/main.py", line 86, in main
    for updates, content in check_updates(opts.path if opts.path else None):
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/check_updates/main.py", line 52, in check_updates
    return tuple(_check_file(f) for f in files)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/check_updates/main.py", line 52, in <genexpr>
    return tuple(_check_file(f) for f in files)
                 ^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/check_updates/main.py", line 64, in _check_file
    return pre_commit.update_pre_commit(str(file))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/check_updates/pre_commit.py", line 20, in update_pre_commit
    config, content = analyze_pre_commit_config(filename)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/check_updates/pre_commit.py", line 94, in analyze_pre_commit_config
    languages = analyze_pre_commit_hooks(name, rev)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/check_updates/pre_commit.py", line 164, in analyze_pre_commit_hooks
    data = yaml.load(_get_pre_commit_hook_impl(name, rev), Loader=yaml.SafeLoader)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/.venv/lib/python3.11/site-packages/yaml/__init__.py", line 81, in load
    return loader.get_single_data()
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/.venv/lib/python3.11/site-packages/yaml/constructor.py", line 49, in get_single_data
    node = self.get_single_node()
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/.venv/lib/python3.11/site-packages/yaml/composer.py", line 39, in get_single_node
    if not self.check_event(StreamEndEvent):
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/.venv/lib/python3.11/site-packages/yaml/parser.py", line 98, in check_event
    self.current_event = self.state()
                         ^^^^^^^^^^^^
  File "/home/tueda/work/py-check-updates/.venv/lib/python3.11/site-packages/yaml/parser.py", line 171, in parse_document_start
    raise ParserError(None, None,
yaml.parser.ParserError: expected '<document start>', but found '<scalar>'
  in "<unicode string>", line 7, column 1:
    <meta http-equiv="refresh" conte ...
    ^
@tueda tueda added the bug Something isn't working label Feb 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant