I hereby claim:
- I am danielroseman on github.
- I am danielroseman (https://keybase.io/danielroseman) on keybase.
- I have a public key ASBnRma2vvPVzJUHeRMFcCnuzxAlh5kqAT-VOxAIRdDq9go
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
| import re | |
| from IPython.core.magic import Magics, magics_class, line_magic | |
| from IPython.core.debugger import Pdb | |
| ipdb = Pdb() | |
| @magics_class | |
| class StepMagic(Magics): |
| Traceback (most recent call last): | |
| File "/home/convore/virtualenvs/convore/lib/python2.6/site-packages/eventlet/wsgi.py", line 336, in handle_one_response | |
| result = self.application(self.environ, start_response) | |
| File "/home/convore/virtualenvs/convore/lib/python2.6/site-packages/django/core/handlers/wsgi.py", line 245, in __call__ | |
| response = middleware_method(request, response) | |
| File "/home/convore/convore/django_ext/middleware/log.py", line 30, in process_response | |
| 'trk': getattr(request, 'trk', None), | |
| File "/home/convore/convore/django_ext/logging.py", line 27, in log_event | |
| if has_session and request.user.is_authenticated(): | |
| File "/home/convore/virtualenvs/convore/lib/python2.6/site-packages/django/contrib/auth/middleware.py", line 9, in __get__ |
| from django.core.mail.backends.base import BaseEmailBackend | |
| from utils.publish import publish_to_queue | |
| class QueueBackend(BaseEmailBackend): | |
| def send_messages(self, email_messages): | |
| for i, email in enumerate(email_messages): | |
| msg = email.__dict__ |
| 33a34> failfast = options.get('failfast', False) | |
| 65,66c66,73 | |
| < failures = test_runner(test_labels, verbosity=verbosity, | |
| < interactive=interactive) | |
| --- | |
| > if hasattr(test_runner, 'run_tests'): | |
| > test_runner = test_runner(verbosity=verbosity, | |
| > interactive=interactive, | |
| > failfast=failfast) | |
| > failures = test_runner.run_tests(test_labels) |
| import django | |
| from django.utils.translation import ugettext_lazy as _ | |
| from debug_toolbar.panels import DebugPanel | |
| from haystack.backends import queries | |
| class HaystackDebugPanel(DebugPanel): | |
| """ | |
| Panel that displays the Haystack queries. | |
| """ | |
| name = 'Haystack' |
| class PostForm(forms.ModelForm): | |
| body = forms.CharField(widget=WMDEditor) | |
| class Meta: | |
| model = Post | |
| class PostAdmin(admin.ModelAdmin): | |
| list_display = ('title', 'publish', 'status', 'visits') | |
| list_filter = ('publish', 'categories', 'status') | |
| search_fields = ('title', 'body') | |
| prepopulated_fields = {'slug': ('title',)} |