Skip to content

Check50 has problems with cloning when a deploy key is set #36

@MarijnDoeve

Description

@MarijnDoeve

Check50 (3.0.8 with lib50 2.0.0) is giving me an error:

~/psets/module1/more/ (master) $ check50 minprog/cs50x/2019/mario/more -v
Connecting...
Authenticating...
Preparing...
INFO:lib50._api:git clone --bare ssh://git@ssh.github.com:443/me50/TheRijn/CS50x-psets .git
Looks like check50 isn't enabled for your account yet. Please go to https://submit.cs50.io in your web browser and try again.
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/lib50/_api.py", line 283, in prepare
    _run(git.set(Git.cache)("clone --bare {repo} .git", repo=user.repo))
  File "/usr/local/lib/python3.7/site-packages/lib50/_api.py", line 688, in _run
    command_output = child.read().strip().replace("\r\n", "\n")
  File "/usr/local/lib/python3.7/contextlib.py", line 119, in __exit__
    next(self.gen)
  File "/usr/local/lib/python3.7/site-packages/lib50/_api.py", line 681, in _spawn
    raise Error()
lib50._errors.Error

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/bin/check50", line 11, in <module>
    load_entry_point('check50==3.0.8', 'console_scripts', 'check50')()
  File "/usr/local/lib/python3.7/site-packages/check50/__main__.py", line 305, in main
    commit_hash = lib50.push("check50", SLUG, internal.CONFIG_LOADER, data={"check50": True})[1]
  File "/usr/local/lib/python3.7/site-packages/lib50/_api.py", line 69, in push
    with authenticate(org, repo=repo) as user, prepare(tool, slug, user, included):
  File "/usr/local/lib/python3.7/contextlib.py", line 112, in __enter__
    return next(self.gen)
  File "/usr/local/lib/python3.7/site-packages/lib50/_api.py", line 291, in prepare
    raise Error(msg)
lib50._errors.Error: Looks like check50 isn't enabled for your account yet. Please go to https://submit.cs50.io in your web browser and try again.
Exception payload:
{}

My code lives in a git repo (TheRijn/CS50x-pests), this repo has a remove set via ssh with authentication via a deploy key.

This brakes ssh -oBatchMode=yes -p443 -T git@ssh.github.com, it's returning.

Hi TheRijn/CS50x-psets! You've successfully authenticated, but GitHub does not provide shell access.

During all this debugging with @Jelleas I realised that the deploy key was set and probably giving these problems.
So this is nog a big as a problem as I thought, but still a nasty edge case.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions