renovatebot / config-help

Please use the Discussions feature of https://github.com/renovatebot/renovate instead

Home Page:https://github.com/renovatebot/renovate/discussions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Setting python_version 3.8 in Pipfile prevents renovate from working

HenrikPoulsen opened this issue · comments

What Renovate type, platform and version are you using?

Self-hosted using docker tag renovate/renovate:23.

Describe the bug

Changing the python_version field in the Pipfile to 3.8 resulted in a PR being updated with the “Artifact update problem” message. And the details being:

File name: Pipfile.lock

Command failed: pipenv lock
Warning: Python 3.8 was not found on your system...
Neither 'pyenv' nor 'asdf' could be found to install Python.
You can specify specific versions of Python with:
$ pipenv --python path/to/python

I was under the impression that this should have been fixed as mentioned in renovatebot/renovate#6035 so not sure what is going on here.

Relevant debug logs

 WARN: Error in read setup file (repository=my/app)
       "stdout": "/data/repos/github/my/app\n",
       "stderr": "/usr/local/python/3.9.0/lib/python3.9/site-packages/setuptools/distutils_patch.py:25: UserWarning: Distutils was imported before Setuptools. This usage is discouraged and may exhibit undesirable behaviors or errors. Please use Setuptools' objects directly or at least import Setuptools first.\n  warnings.warn("
 INFO: Dependency extraction complete (repository=my/app)
       "baseBranch": "test",
       "stats": {
         "managers": {
           "docker-compose": {"fileCount": 1, "depCount": 2},
           "dockerfile": {"fileCount": 1, "depCount": 1},
           "pip_requirements": {"fileCount": 1, "depCount": 3},
           "pipenv": {"fileCount": 1, "depCount": 25}
         },
         "total": {"fileCount": 4, "depCount": 31}
       }
 INFO: Branch updated (repository=my/app, branch=renovate/lz4-3.x)
       "commitSha": "32ca720"
 INFO: PR updated (repository=my/app, branch=renovate/lz4-3.x)
       "pr": 272,
       "prTitle": "Update dependency lz4 to v3.1.1"
 WARN: artifactErrors (repository=my/app, branch=renovate/lz4-3.x)
       "artifactErrors": [
         {
           "lockFile": "Pipfile.lock",
           "stderr": "Command failed: pipenv lock\nWarning: Python 3.8 was not found on your system...\nNeither 'pyenv' nor 'asdf' could be found to install Python.\nYou can specify specific versions of Python with:\n$ pipenv --python path/to/python\n"
         }
       ]

To Reproduce

Set the python_version field in Pipfile to 3.8.
That's literally all I did and it went from functional to unhappy.

Additional context

Nothing to add

Renovate's official Docker image is now built with python 3.9: https://github.com/renovatebot/docker-renovate-full/blob/bbf5bb94f30ce8a485b0c7b538656d5d606a3ce7/Dockerfile#L34

If you need to run custom versions of any tools, you have two options:

  • Fork and maintain your own Dockerfile build with versions of your choosing
  • Use the slim Docker image and map the Docker socket into the Renovate container so that it can create side containers with the right version at runtime
commented

This issue has been automatically marked as stale because it has not had recent activity. It will be closed soon if no further activity occurs.
If this question is not done (either you plan to update it or are waiting on someone to respond) then please add a comment here to bump it and/or get the other person's attention.
We aim to do our best to solve every problem. This bot is here to help us clean up issues which are no longer of use to the original poster, and not to close anything prematurely, so bump as you need!