Skip to content

Useless error when ca-certificates are missing #5065

@glandium

Description

@glandium

I was trying to cargo build something in a newly created chroot and got the following output:

    Updating registry `https://github.com/rust-lang/crates.io-index`
warning: spurious network error (2 tries remaining): curl error: 
; class=Net (12)
warning: spurious network error (1 tries remaining): curl error: 
; class=Net (12)
error: failed to fetch `https://github.com/rust-lang/crates.io-index`           

Caused by:
  curl error: 
; class=Net (12)

Even with colors, this is not a great error message.
Strace hinted me that /etc/ssl/certs/ca-certificates.crt was missing, and sure enough, it worked after installing the ca-certificates package. But that wasn't thanks to cargo's error message.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions