Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed8.news.xs4all.nl!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'python,': 0.02; 'path.': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'python': 0.10; 'jan': 0.11; 'do,': 0.15; "'from": 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; 'sorts': 0.16; 'stuff.': 0.16; 'x.y': 0.16; 'wrote:': 0.16; 'debugging': 0.18; 'tree': 0.18; 'work,': 0.21; 'am,': 0.23; 'seems': 0.23; 'sets': 0.23; 'import': 0.24; 'header:In-Reply-To:1': 0.24; "i've": 0.25; 'header:User-Agent:1': 0.26; 'header:X-Complaints- To:1': 0.26; 'appreciated.': 0.27; 'distribute': 0.27; 'package.': 0.27; 'installed,': 0.29; 'environment': 0.29; "i'm": 0.30; "i'd": 0.31; "can't": 0.32; 'related': 0.32; 'topic': 0.32; 'source': 0.33; 'directory,': 0.33; 'file': 0.34; 'running': 0.34; 'advice': 0.35; 'but': 0.36; 'too': 0.36; 'project': 0.36; 'there': 0.36; 'tool': 0.36; '(and': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'received:org': 0.37; 'seem': 0.37; 'version': 0.38; 'files': 0.38; 'sure': 0.39; 'to:addr:python.org': 0.40; 'where': 0.40; 'still': 0.40; 'some': 0.40; 'ever': 0.60; 'received:fios.verizon.net': 0.91 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Terry Reedy Subject: Re: debugging during package development Date: Sat, 1 Aug 2015 02:44:55 -0400 References: <87fv43y6z4.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: pool-98-114-97-173.phlapa.fios.verizon.net User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 In-Reply-To: <87fv43y6z4.fsf@gmail.com> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.20+ Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 24 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1438411508 news.xs4all.nl 2899 [2001:888:2000:d::a6]:38412 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:94831 On 8/1/2015 12:21 AM, Seb wrote: > It seems too cumbersome to have to update `sys.path` to include the > development tree of a package (and sub-packages) that's still very > young. With lots of debugging to do, the last thing I'd want is to > worry about the search path. So I've been searching for better ways to > work, but I can't seem hit the right keywords and come with all sorts of > tangentially related stuff. I'm sure there must be some tool that sets > up the development environment when the package source is not on > `sys.path`. Any advice on this topic would be appreciated. I am not sure what you are asking, but do you know about .pth files in site-packages? For each python installed, I put in site-packages a python.pth containing one line "F:/python". That file contains my project directory, call it x/ Running any version of python, 'from x import y' or 'from x.y import z' just works, the same as if x/ *were* in site-packages, and will be if I ever distribute the x package. No fuss with search paths; python plugs x into site-packages for me. I do not know where this is documented. -- Terry Jan Reedy