aboutsummaryrefslogtreecommitdiff
path: root/paludis/python_hooks.cc
AgeCommit message (Collapse)AuthorLines
2019-10-22python: Normalize exceptionsAvatar Marvin Schmidt -0/+1
The python 3 incompatible call of `file` in the python hook caused an exception. Trying to get the traceback failed because the exception isn't normalized: 13: [ RUN ] Hooker.Ordering 13: paludis@1565848332: [WARNING hook.python.traceback_failed] In thread ID '13623': 13: ... When triggering hook 'ordering': 13: ... When running hook 'hooker_TEST_dir/ordering/py_hook.py' for hook 'ordering': 13: ... When getting traceback 13: ... Hook 'hooker_TEST_dir/ordering/py_hook.py': _get_traceback(): traceback.format_exception failed 13: paludis@1565848332: [WARNING hook.python.failure] Hook 'hooker_TEST_dir/ordering/py_hook.py': running hook_run_ordering function failed: 'Getting traceback failed' 13: paludis@1565848332: [WARNING hook.python.failure] Hook 'hooker_TEST_dir/ordering/py_hook.py' failed unexpectedly: 'Traceback (most recent call last): 13: File "/usr/x86_64-pc-linux-gnu/lib/python3.7/traceback.py", line 121, in format_exception 13: type(value), value, tb, limit=limit).format(chain=chain)) 13: File "/usr/x86_64-pc-linux-gnu/lib/python3.7/traceback.py", line 476, in __init__ 13: if (exc_value and exc_value.__cause__ is not None 13: AttributeError: 'str' object has no attribute '__cause__' 13: 13: The above exception was the direct cause of the following exception: 13: 13: Traceback (most recent call last): 13: File "/home/marv/devel/paludis-worktrees/cross/python/paludis_output_wrapper.py", line 101, in restore_prefix 13: restore("both") 13: File "/home/marv/devel/paludis-worktrees/cross/python/paludis_output_wrapper.py", line 80, in restore 13: if len(stderr_cache): 13: SystemError: <built-in function len> returned a result with an error set' 13: ../paludis/hooker_TEST.cc:76: Failure 13: Expected equality of these values: 13: 0 13: result.max_exit_status() 13: Which is: 1 13: ../paludis/hooker_TEST.cc:83: Failure 13: Expected equality of these values: 13: "e\nc\nf\nd\nb\na\npy_hook\ng\ni\nh\nsohook\nk\nj\n" 13: line 13: Which is: "e\nc\nf\nd\nb\na\ng\ni\nh\nsohook\nk\nj\n" 13: With diff: 13: @@ -5,5 @@ 13: b 13: a 13: -py_hook 13: g 13: i 13: 13: [ FAILED ] Hooker.Ordering (195 ms)
2013-05-22Switch to std mutex and condition_variableAvatar Ciaran McCreesh -6/+6
2011-03-20Missing env_varsAvatar Ciaran McCreesh -1/+2
2010-08-24FSEntry -> FSPath, FSStatAvatar Ciaran McCreesh -7/+6
Fixes: ticket:967
2010-08-12Let hooks take an output managerAvatar Ciaran McCreesh -2/+2
2010-07-24DeboilerplateiseAvatar Ciaran McCreesh -1/+1
2010-07-23Avoid more explicit newageAvatar Ciaran McCreesh -1/+1
2010-07-22Use std::make_shared<>Avatar Ciaran McCreesh -2/+1
2010-07-22No more tr1:: and tr1/Avatar Ciaran McCreesh -4/+4
2010-05-19New improved NamedValue syntaxAvatar Ciaran McCreesh -6/+6
2008-12-05kill some srAvatar Ciaran McCreesh -6/+7
2008-04-26paludis::tr1:: is dead. We no longer support compilers that don't do tr1 ↵Avatar Ciaran McCreesh -4/+4
(that means you, gcc-3).
2008-04-16Give log messages an idAvatar Ciaran McCreesh -61/+61
2008-03-22Implement auto hooks, new install_task hook phases. Fixes: ticket:434, ↵Avatar Ciaran McCreesh -0/+8
ticket:435, ticket:502
2007-09-25Rename const iterators to ConstIterator, mutable to Iterator. Fixes: ticket:365Avatar Ciaran McCreesh -2/+2
2007-09-10Python Hooks.Avatar Piotr Jaroszyński -0/+436