Majic Projects
Go to the previous open issue
Go to the previous issue (open or closed)
Please log in to bookmark issues
Closed Bug report MAR-145 Python requirements upgrade checks not compatible with latest pip-tools
Go to the next issue (open or closed)
Go to the next open issue
icon_info.png This issue has been closed with status "Closed" and resolution "RESOLVED".
Issue basics
  • Type of issue
    Bug report
  • Category
  • Targetted for
  • Status
  • Progress
  • Priority
    Not determined
User pain
  • Type of bug
    Not triaged
  • Likelihood
    Not triaged
  • Effect
    Not triaged
Affected by this issue (1)
People involved
Times and dates
  • Posted at
  • Last updated
  • Estimated time
    4 hours
  • Time spent
    4 hours
    Click here to see time logged against this issue
Issue details
  • Resolution
  • Reproducability
  • Severity
    Not determined
Attachments (0)
There is nothing attached to this issue
Duplicate issues (0)
This issue does not have any duplicates

The Python requirements upgrade checks are implemented through a wrapper script that utilises the pip-tools utilities.

When used with latest pip-tools release (4.0.0), the script will produce "spurious" output on the standard error stream, causing the cron job to fire off a mail due to detected errors. This happens because the pip-compile utility now outputs the debug/verbose information (mainly the one that includes full listing of compiled requirements) to stderr instead of stdout (change from previous behaviour).

It would be necessary to fix the wrapper script to hide the extra listing of requirements on the stderr, and to only show actual errors there.

The following should be done:

  • Update the script to fix the issue.
  • Make sure the script works with both Python 2 and Python 3.
  • Bump the requirements for wrapper script virtual environment itself as well.
Steps to reproduce this issue

Reproduction steps:

  1. Set-up test configuration for the requirements checks script:

    mkdir -p ~/tmp/pipreqcheckissue/django/
    echo "django~=1.8.0" > ~/tmp/pipreqcheckissue/django/
    echo "django==1.8.19" > ~/tmp/pipreqcheckissue/django/requirements.txt

  2. Set-up a virtual environment with latest pip-tools and pip:

    mkvirtualenv pipreqcheckissue
    workon pipreqcheckissue
    pip install -U pip-tools pip

  3. Run the upgrade checks script:

    cd ~/projects/majic-ansible-roles/
    ./roles/common/files/ ~/tmp/pipreqcheckissue/

Expected results:

  1. Output in step 3 is:

    [INFO] No upgrades available for: /home/USERNAME/tmp/pipreqcheckissue//django/requirements.txt

Actual results:

  1. Output in step 3 is (notice the first line showing Django version - this is output to stderr):

    [INFO] No upgrades available for: /home/branko/tmp/pipreqcheckissue//django/requirements.txt

Comments ()
There are no comments