[Lldb-commits] [PATCH] D15318: Get rid of global variables in dotest.py

Zachary Turner via lldb-commits lldb-commits at lists.llvm.org
Mon Dec 7 21:58:01 PST 2015


Hmm, yea that code path only gets run on OSX.  I think the problem is that
I changed the order that happens in.  It now happens right when you import
`configuration` for the first time, and it used to happen explicitly in
`main()`.  So maybe just make that function public, and call in the same
place it used to be called.

On Mon, Dec 7, 2015 at 9:55 PM Todd Fiala <todd.fiala at gmail.com> wrote:

> tfiala added a comment.
>
> Here's what I'm seeing so far (as of r254983) when running on OS X:
>
>   $ test/dotest.py --results-formatter
> lldbsuite.test.basic_results_formatter.BasicResultsFormatter
>   Traceback (most recent call last):
>     File "test/dotest.py", line 6, in <module>
>       import lldbsuite.test
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/__init__.py",
> line 5, in <module>
>       from . import dotest
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/dotest.py",
> line 43, in <module>
>       from . import configuration
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/configuration.py",
> line 223, in <module>
>       __setupCrashInfoHook()
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/configuration.py",
> line 33, in __setupCrashInfoHook
>       test_dir = os.environ['LLDB_TEST']
>     File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/UserDict.py",
> line 23, in __getitem__
>       raise KeyError(key)
>   KeyError: 'LLDB_TEST'
>
>
>
>   $ test/dotest.py --curses
>   Traceback (most recent call last):
>     File "test/dotest.py", line 6, in <module>
>       import lldbsuite.test
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/__init__.py",
> line 5, in <module>
>       from . import dotest
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/dotest.py",
> line 43, in <module>
>       from . import configuration
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/configuration.py",
> line 223, in <module>
>       __setupCrashInfoHook()
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/configuration.py",
> line 33, in __setupCrashInfoHook
>       test_dir = os.environ['LLDB_TEST']
>     File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/UserDict.py",
> line 23, in __getitem__
>       raise KeyError(key)
>   KeyError: 'LLDB_TEST'
>
>
>
>   $ test/dotest.py
>   Traceback (most recent call last):
>     File "test/dotest.py", line 6, in <module>
>       import lldbsuite.test
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/__init__.py",
> line 5, in <module>
>       from . import dotest
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/dotest.py",
> line 43, in <module>
>       from . import configuration
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/configuration.py",
> line 223, in <module>
>       __setupCrashInfoHook()
>     File
> "/Users/tfiala/src/lldb-tot/lldb/packages/Python/lldbsuite/test/configuration.py",
> line 33, in __setupCrashInfoHook
>       test_dir = os.environ['LLDB_TEST']
>     File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/UserDict.py",
> line 23, in __getitem__
>       raise KeyError(key)
>   KeyError: 'LLDB_TEST'
>
>
> http://reviews.llvm.org/D15318
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20151208/800d1636/attachment.html>


More information about the lldb-commits mailing list