Avoid deleting previous PYTHONPATH

Review Request #6001 — Created June 16, 2014 and submitted

Information

Djblets

Reviewers

With the previous putenv command, if an user had already set the PYTHONPATH environment variable, its value was deleted and substituted by os.getcwd(), which may prevent the installation if the dependencies are installed in a different path. Now, it appends this value to the previous value set in the sys.path, so the user configuration is kept.


 
Description From Last Updated

Col: 24 E211 whitespace before '('

reviewbotreviewbot
reviewbot
  1. This is a review from Review Bot.
      Tool: PEP8 Style Checker
      Processed Files:
        setup.py
      Ignored Files:
    
    
  2. setup.py (Diff revision 1)
     
     
    Show all issues
    Col: 24
     E211 whitespace before '('
    
  3. 
      
reviewbot
  1. This is a review from Review Bot.
      Tool: Pyflakes
      Processed Files:
        setup.py
      Ignored Files:
    
    
  2. 
      
CA
CA
reviewbot
  1. This is a review from Review Bot.
      Tool: PEP8 Style Checker
      Processed Files:
        setup.py
      Ignored Files:
    
    
  2. 
      
reviewbot
  1. This is a review from Review Bot.
      Tool: Pyflakes
      Processed Files:
        setup.py
      Ignored Files:
    
    
  2. 
      
david
  1. Ship It!

  2. 
      
CA
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-0.8.x (c79ff44)
sgallagh
  1. I wish I had seen this sooner. This change completely reverts the fix from https://reviews.reviewboard.org/r/5300/

    The reason that it was done as a os.putenv() instead of as sys.path.append() is because the subprocess doesn't inherit this value. By changing this, you reintroduced the original issue.

    The correct fix here would be to append to the PYTHONPATH environment variable instead of replacing it. I'll submit a new patch to fix this.

  2. 
      
Loading...