Discussion:
[FE-discuss] Why filter_extra_fields does not imply allow_extra_fields?
Nicolas Grilly
2009-11-19 20:53:36 UTC
Permalink
Hello list,

I'm wondering why filter_extra_fields=True does not imply
allow_extra_fields=True? There is nothing to filter if extra fields
are not allowed, isn't it? Am I missing something or is it possible to
propose this change to FormEncode?

Thanks for your advice,

Nicolas Grilly
Ian Bicking
2009-11-19 22:10:37 UTC
Permalink
On Thu, Nov 19, 2009 at 2:53 PM, Nicolas Grilly
Post by Nicolas Grilly
I'm wondering why filter_extra_fields=True does not imply
allow_extra_fields=True? There is nothing to filter if extra fields
are not allowed, isn't it? Am I missing something or is it possible to
propose this change to FormEncode?
There's no real reason for it. FormEncode is on bitbucket now, if you
want to submit a patch/pull request:
http://bitbucket.org/ianb/formencode
--
Ian Bicking | http://blog.ianbicking.org | http://topplabs.org/civichacker
Jon Nelson
2009-11-20 00:37:01 UTC
Permalink
Post by Ian Bicking
On Thu, Nov 19, 2009 at 2:53 PM, Nicolas Grilly
Post by Nicolas Grilly
I'm wondering why filter_extra_fields=True does not imply
allow_extra_fields=True? There is nothing to filter if extra fields
are not allowed, isn't it? Am I missing something or is it possible to
propose this change to FormEncode?
There's no real reason for it. FormEncode is on bitbucket now, if you
I disagree. filter_extra_fields = True is useful when you want to take a
dictionary which might have a whole bunch of keys in it and, provided the
form validates, turn out the other end *just* the validated keys.
allow_extra_fields turns the condition of any extra field into an error. At
least that's how I think it works.
--
Jon
Loading...