Hello,
after hours of examinating and debugging the Django source code I
decided to post my problem here.
I'm using Django 1.3.1 and its docs say:
The is_valid() method and errors
Changed in Django 1.2: Please, see the release notes
The first time you call is_valid() or access the errors attri
That explains my thoughts that the debugger is "disturbing" the
correct execution of the code, but this discussion does *not* (!)
answer my question where the *model* of a *ModelForm* gets full_clean-
ed - and why it doesn't do so in my case.
On Sep 29, 8:48 pm, Shawn Milochik wrote:
> This exact
Well, with the new knowledge about the debugger I found the place
where BaseModelForm calls all three form-validation methods in forms/
models.py:306:_post_form
Sorry.
On Sep 29, 9:26 pm, momo2k wrote:
> That explains my thoughts that the debugger is "disturbing" the
> correct
Hello,
this may be a python-general question, but it came across my way while
working with django:
Imagine you have a model:
class A(Model)
name = CharField()
type = SmallIntegerField(choices=SOME_TYPES)
def do_something(self):
fancy_things
I want do_something() do different
A minute ago I have understood what proxy inheritance is good for.
sorry!
On 4 Okt., 01:26, momo2k wrote:
> Hello,
>
> this may be a python-general question, but it came across my way while
> working with django:
> Imagine you have a model:
>
> class A(Model)
> name
Hello,
strange Problem here:
LOGGER = logging.getLogger('somename')
LOGGER.error('Could not do something: %s', err.output, exc_info=True)
In the mail it shows 'Could not do something: %s', but in the logfile
(RotatingFileHandler) %s is correcly substituted by err.output. Am I
missing the paragra
I'm using Django for about a year by now and I'm using translation
since users of my website are mixed german/english speaking.
makemessages works well on Windows, but on Debian 5 it doesn't work
with multiple line messages and I can't figure out why. I'm sure it's
a simple problem, but I don't ge
No one?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this gr
Well, dos2unix solved
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options,
Did you restart the interpreter after adding the code?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@go
Hello,
Is there a way to set dynamic default values for custom fields in the
admin?
Description of the problem:
# models.py
# there are two models
class Meal(models.Model):
name = ...
def check_new_price(self, price):
# checks if the price is new and creates a new price if
necce
Thanks, working :)
def __init__(self, *args, **kwargs):
super(MealModelForm, self).__init__(*args, **kwargs)
try:
instance = kwargs['instance']
self.fields['price'].initial = instance.price()
except (KeyError, AttributeError):
pass
-
12 matches
Mail list logo