Commit Graph

41 Commits

Author SHA1 Message Date
Anthony Ricaud
bf604a0398 Add BaseForm._html_output (#364) 2020-04-30 14:36:55 +03:00
Onyeka Aghanenu
90ed7f332d Fix Modelform auto_id to accept Boolean type. (#356) 2020-04-13 19:04:18 +03:00
Ceesjan Luiten
2964ed53d7 Improve type of BaseForms.files (#350)
This is valid Django, which failed to pass with the old type-defintion:

    class MyForm(Form):
      myparam = MultiFileField(...)

      self.clean(self, *args, **kwargs):
        self.files.getlist('myparam', [])
2020-03-31 10:16:02 +03:00
Brian Helba
d96aee7a8b Fix the type of form.Field.widget (#321)
The `widget` class attribute of `form.Field` expects a `Widget` class, not an instance of `Widget`.

See: https://docs.djangoproject.com/en/3.0/ref/forms/fields/#widget
Also usages at: 3259983f56/django/forms/fields.py (L46)
2020-02-07 12:42:02 +03:00
JR Heard
031d42a75d update ChoiceField's choices kwarg's annotation (#273)
per the [docs](https://docs.djangoproject.com/en/3.0/ref/forms/fields/#choicefield), `choices` is:

> Either an iterable of 2-tuples to use as choices for this field, or a callable that returns such an iterable.
2019-12-14 09:30:50 +03:00
Maksim Kurnikov
1c31e71ffc enable 'model_forms' for tests typechecking (#270) 2019-12-13 13:30:21 +03:00
Patrick Gingras
df4c17a947 added base_fields and declared_fields properties to Form (#235) 2019-11-27 22:48:05 +03:00
Christopher Sabater Cordero
7b74a6944a Add a few missing types to the stubfiles (#214)
* Add types to stub files.

* Fix black and flake8 errors.
2019-11-12 18:25:31 +03:00
Maxim Kurnikov
be3fc259d5 fix compatibility with 0.730 (#189) 2019-09-28 05:23:55 +03:00
Maxim Kurnikov
963d50c717 add linting stubs with flake8-pyi and check for unused imports (#186) 2019-09-25 02:20:23 +03:00
Jared Kerim
b8379d4fe6 Add property to forms.changed_data fixes #148 (#149) 2019-08-30 11:18:24 +03:00
Maxim Kurnikov
fc9a335dfd make ValuesQuerySet have proper Collection generic type (#140) 2019-08-24 18:24:21 +03:00
Maxim Kurnikov
5b2aacddba add missing field methods 2019-07-24 13:38:49 +03:00
Maxim Kurnikov
335c5765c3 enable test folders: select_for_update, i18n, httpwrappers, auth_tests, extra_regress (#107) 2019-07-10 19:38:36 +03:00
Maxim Kurnikov
2799646723 add missing files throughout the codebase (#102) 2019-07-09 05:18:15 +03:00
Maxim Kurnikov
5c6be7ad12 Add test to import all modules to check validity of stubs (#56)
* add import_all.test builder

* fix errors

* fix typechecking errors

* fix migrations typechecking
2019-03-25 01:57:34 +03:00
Maxim Kurnikov
7c57143310 forms/__init__ reimports 2019-03-10 21:14:15 +03:00
Maxim Kurnikov
df5c70c703 fixes for FormMixin's get_form/get_form_class 2019-02-25 04:01:36 +03:00
Maxim Kurnikov
b686751f19 fix some stubs 2019-02-22 02:55:49 +03:00
Maxim Kurnikov
2d3b5492f0 fix form errors in CI 2019-02-20 21:24:49 +03:00
Maxim Kurnikov
116aa2c539 clean up forms 2019-02-20 15:22:46 +03:00
Maxim Kurnikov
916df1efb6 add Model.__init__ typechecking 2019-02-08 17:16:03 +03:00
Maxim Kurnikov
191496ed72 enable some test folders, bunch of fixes 2019-02-07 00:08:05 +03:00
Maxim Kurnikov
69d4ccaf54 fixes, add some testing folders 2019-02-04 19:31:37 +03:00
Maxim Kurnikov
d03fddd96d split error suppression for tests typechecking, fix ci, bunch of fixes 2019-02-03 19:33:51 +03:00
Maxim Kurnikov
b1153204d7 enable bunch of folders 2019-01-30 21:01:33 +03:00
Maxim Kurnikov
628c1224d6 enable test typechecking for a bunch of django test suite folders 2019-01-30 15:56:59 +03:00
Maxim Kurnikov
1afa079b0b add tests for the django test suite 2019-01-26 17:17:35 +03:00
Maxim Kurnikov
87877774cd fix problems with 0.660 2019-01-20 18:57:26 +03:00
Maxim Kurnikov
98e60d084f fixes for ci imports failures 2019-01-06 21:00:01 +03:00
Maxim Kurnikov
070cecda10 finish moving generated stubs 2018-12-22 05:18:27 +03:00
Maxim Kurnikov
d56ca8ea31 move most of the generated files 2018-12-21 05:47:24 +03:00
Maxim Kurnikov
96cd3ddb27 move generated stubs to separate directory, too messty 2018-11-10 17:49:18 +03:00
Maxim Kurnikov
2676b335f1 add __init__.pyi files to all directories when it doesnt exist 2018-09-16 02:55:00 +03:00
Maxim Kurnikov
a13d4c352a fifth iteration 2018-08-14 12:01:01 +03:00
Maxim Kurnikov
8cc446150c fourth iteration 2018-08-11 02:23:18 +03:00
Maxim Kurnikov
c6bceb19f4 third iteration of stubs 2018-08-11 00:19:50 +03:00
Maxim Kurnikov
fa718b8e55 better stubs 2018-08-05 03:13:19 +03:00
Maxim Kurnikov
cf85607969 reformat with black 2018-07-29 23:34:58 +03:00
Maxim Kurnikov
4866354600 merge with stubgen output 2018-07-29 23:25:20 +03:00
Maxim Kurnikov
f471b7b1bf make pep561 compliant 2018-07-29 20:19:43 +03:00