Pulling from private repository without known_hosts hangs forever

Bug #2052928 reported by Guillaume Beuzeboc
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Snapcraft
New
Undecided
Unassigned

Bug Description

Having a part source pulling from private repo without known_hosts (--bind-ssh passed) hangs until I press a key in the terminal.
It appears that the Yes/No question from git is hidden by the snapcraft progress line.
Snapcraft should return an error or the input question.

To reproduce:

snapcraft.yaml:

name: nope
base: core22
version: '0.1'
summary: Nope
description: |
  Nope

grade: devel
confinement: strict

parts:
  my-part:
    plugin: python
    source: <email address hidden>:nope/doesnt_exist.git

-----------------

logs:

Starting Snapcraft 8.0.2
Logging execution to '.../.local/state/snapcraft/log/snapcraft-20240212-112649.931680.log'
Running on amd64 for amd64
Launching instance...
Starting instance
Starting Snapcraft 8.0.2
Logging execution to '/tmp/snapcraft.log'
Running on amd64 for amd64
Initializing parts lifecycle
Installing build-packages
Installing build-snaps
The authenticity of host 'github.com (140.82.121.3)' can't be established.
ED25519 key fingerprint is SHA256:+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU.
This key is not known by any other names
Pulling my-part - (309.9s)
Pulling my-part # <--- Hit enter otherwise it hangs
Failed to pull source: command ['git', 'clone', '--recursive', '<email address hidden>:nope/doesnt_exist.git', '/root/parts/my-part/src'] exited with code 128.
Make sure sources are correctly specified.
Failed to execute pack in instance.
Recommended resolution: Run the same command again with --debug to shell into the environment if you wish to introspect this failure.
Full execution log: '.../.local/state/snapcraft/log/snapcraft-20240212-112649.931680.log'

description: updated
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.