James Stewart Miller

Results 28 comments of James Stewart Miller

Is the website on github? On 4 June 2016 at 17:37, monolux [email protected] wrote: > Yes, would be a good move to update the Asual website. > > — >...

Thanks dude. That's really helpful, and you've saved me hours of barking up the wrong tree whilst I familiarise myself with Java and Android coming from C++ (long time ago)...

this is probably the same fault that is reported in #222 . I have just started using pytest-sugar and when I pytest with any combination of the -r flag, I...

I am guessing the codebase has been updated on github and pypi hasn't been updated.

There is a note about this in the instructions that says something like use 'summernotetextfield' which uses bleach to sanitize html. However, when I use a summernotetextfield on my model,...

Also, in the latest django_summernote from pypi, there is no bleach at all. from Fields.py in my site-packages: ``` from django.db import models from django.forms import fields from django_summernote.widgets import...

if its any consolation the same thing happens with django_tinymce. I am guessing the correct answer is to catch the text in the form_valid function and regex out any annoying...

Ok, it seems it was my fault. Bleach does work, but not on escaped html. So, I now run ``` import html model = form.save(commit=False) model.text = bleach.clean(html.unescape(model.text), tags=ALLOWED_TAGS, attributes=ATTRIBUTES,...

Of course, django_summernote has got bleach baked in, at least it will do, when pypi is updated.... :(

I am guessing this is due to the following code in fields.py ``` class SummernoteTextFormField(fields.CharField): def __init__(self, *args, **kwargs): kwargs.update({'widget': SummernoteWidget()}) super().__init__(*args, **kwargs) ```