Skip to content

Commit cb8c554

Browse files
vanschelvenarjun024
authored andcommitted
Print pip's version when using python's pip module
To be able to debug problems when using pip it's handy to know which version of pip is actually being used
1 parent b79852b commit cb8c554

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/python/supply/supply.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,9 @@ func (s *Supplier) InstallPip() error {
320320
pipVersion := os.Getenv(EnvPipVersion)
321321
if pipVersion == "" {
322322
s.Log.Info("Using python's pip module")
323-
return nil
323+
324+
versionCmd := append(pipCommand(), "--version")
325+
return s.Command.Execute(s.Stager.BuildDir(), indentWriter(os.Stdout), indentWriter(os.Stderr), versionCmd[0], versionCmd[1:]...)
324326
}
325327
if pipVersion != "latest" {
326328
return fmt.Errorf("invalid pip version: %s", pipVersion)

0 commit comments

Comments
 (0)