Commit graph

116 commits

Author SHA1 Message Date
Alex Hall
215a580fa1 Tests for exploding variables 2019-05-03 18:47:23 +03:00
Alex Hall
e4b244736a Remove empty parens from exceptions 2019-05-03 18:47:23 +03:00
Alex Hall
4ebbbf8226 BaseVariable is an ABC 2019-05-03 18:47:23 +03:00
Ram Rachum
e3688e4b63 Prefer dotted import 2019-05-03 18:47:23 +03:00
Alex Hall
18e758b0f9 Handle missing frame.f_globals 2019-05-03 18:47:23 +03:00
Alex Hall
5f34219df7 A weird __eq__ method could raise an exception when using 'in' 2019-05-03 18:47:23 +03:00
Alex Hall
e1bdbc0042 repr -> get_shortish_repr 2019-05-03 18:47:23 +03:00
Alex Hall
d09b348d96 Use collections ABCs to be safe 2019-05-03 18:47:23 +03:00
Alex Hall
97dc802ee6 Add automatic exploded_variables 2019-05-03 18:47:23 +03:00
Alex Hall
fb62a57a52 Enumerate is too risky - it exhausts iterators and will show changes when sets change order 2019-05-03 18:47:23 +03:00
Alex Hall
56d3389500 Add classes to automatically track attributes, keys, etc. of variables
# Conflicts:
#	pysnooper/tracer.py
2019-05-03 18:47:23 +03:00
Ram Rachum
5111a534d4 New release 2019-05-03 18:25:15 +03:00
Mike Bayer
20e746ac92 Allow a callable to be passed to snoop()
Fixes: #80
2019-05-03 18:24:05 +03:00
Ram Rachum
b8dec67a4f Workaround for Unicode display on Py2.7, fix #67 2019-05-02 21:51:38 +03:00
Ram Rachum
59d3a9d178 Catch ValueError because IronPython raises it on bad filename #75 2019-04-30 20:29:23 +03:00
Nikita Melentev
eb59047a88 setup.py: add test dependencies via "extras" (#66) 2019-04-29 02:45:58 +02:00
Ram Rachum
fb5b7eabbc IronPython doesn't always have frame.f_globals, fix #75 2019-04-28 22:28:01 +03:00
Alex Hall
9a81a2e76c Fixes for Python 2 2019-04-28 14:29:11 +03:00
Alex Hall
0322982875 More informative repr for exceptions. Forgot to use repr_instance 2019-04-28 14:29:11 +03:00
Alex Hall
4ec976bd14 PR feedback:
Swap imports
Raise maxother locally
Demo long variable output
2019-04-28 14:29:11 +03:00
Alex Hall
a5e420a3ab reprlib already handles both truncation and exceptions 2019-04-28 14:29:11 +03:00
Alex Hall
7de345f5cc Use reprlib 2019-04-28 14:29:11 +03:00
Ram Rachum
fbc3f98aa1 Update AUTHORS 2019-04-27 09:08:58 +03:00
pohmelie
f1289f5d88 gitignore: add mypy_cache directory 2019-04-27 08:15:45 +03:00
Ram Rachum
2775d251b3 Tweak "Contribute" part of readme 2019-04-26 21:28:53 +03:00
Ram Rachum
ec7687fab3 Add test_single_variable_no_comma 2019-04-26 12:53:46 +03:00
Ram Rachum
fe3569bdd5 Bump version 2019-04-26 12:48:58 +03:00
Ram Rachum
e21fc11352 Massaging some code 2019-04-26 12:48:58 +03:00
Alex Hall
c9a51de674 Test arbitrary expression evaluation. 2019-04-26 12:48:58 +03:00
Alex Hall
e97cdd2b6c Allow tracking arbitrary expressions in 'variables' using eval 2019-04-26 12:48:58 +03:00
Alex Hall
a1471f6fb9 Use dedent for nice multiline string 2019-04-26 10:05:12 +03:00
Alex Hall
2708376bdf Fully readable failure from assert_output 2019-04-26 10:05:12 +03:00
Alex Hall
36b3271f0a Fix incorrect tuple passed to variables in test 2019-04-26 10:05:12 +03:00
Alex Hall
d29cd6f464 Make it easier to read assert_output failure by showing mismatched line rather than just mismatched length. Also, .format can't evaluate arbitrary Python 2019-04-26 10:05:12 +03:00
Alex Hall
93edf6fced Remove more calls to decode using u prefix 2019-04-26 10:05:12 +03:00
Ram Rachum
aedaa7ee56 More styling 2019-04-25 21:59:25 +03:00
Ram Rachum
c9f1dab584 Bump version 2019-04-25 21:50:56 +03:00
Alex Hall
30e5789177 Basic fixes for linters: remove unused variables and imports, plus whitespace and other style improvements for PEP8
Edited by Ram.

# Conflicts:
#	pysnooper/pysnooper.py
#	tests/test_pysnooper.py
2019-04-25 21:49:44 +03:00
Ram Rachum
948fa7a312 Argument to overwrite file #5 2019-04-25 21:34:45 +03:00
Ram Rachum
ae001ccd19 Update AUTHORS 2019-04-25 18:13:52 +03:00
Alex Hall
7894b55a7e Remove need for conditional .decode() call which gives warning 2019-04-25 18:13:41 +03:00
Alex Hall
2b4b64b71b Cleanup generate_authors 2019-04-25 18:13:19 +03:00
Ram Rachum
c90ec63874 Part 2: Don't require setup.py to import pysnooper 2019-04-25 18:12:00 +03:00
Ram Rachum
cda2b254a1 Don't require setup.py to import pysnooper 2019-04-25 16:54:46 +03:00
Ram Rachum
24005024f4 Tweak media coverage 2019-04-25 15:00:33 +03:00
Shlomi Fish
81a8b79dc8 Add links to some online media coverage. 2019-04-25 14:58:47 +03:00
Ram Rachum
80a89cd275 Ignore coverage-related files 2019-04-25 10:44:41 +03:00
Ram Rachum
748d01bd93 Bump version 2019-04-24 23:17:56 +03:00
Ram Rachum
4c0b64fd0b Bundling decorator and six, look ma no dependencies! 2019-04-24 23:16:59 +03:00
Ram Rachum
08aea68d6a Fix bug in not closing file on PyPy 2019-04-24 22:32:08 +03:00