First release of mypy-django

Enable static type checking in your django projects

Posted by Daniel Moisset 1 year, 5 months ago Comments

We’re happy to make a release of mypy-django 0.1.1, the first of many!

It’s a collection of type stubs for using with the mypy static type checking tool (and also with other PEP-484 compliant tools). If you’re a Django developer who wants to improve the quality of documentation and checking of your code, you might be interested. You can take a look at the README file for some examples, or at the annotated version of the Django tutorial for a full project.

Our goal is to be able to annotate (and validate annotations) in our Django projects, and have yet another tool in our software quality arsenal at Machinalis... But given that we’re releasing it under a BSD license, it’s also a tool for everyone else. Feel free to let us know if you’re using it or if we can help you integrate it with your projects.

Support is mainly for Django 1.10, but older versions should work reasonably well.

Supported Components

  • HttpRequest and HttpResponse objects
    • Including supporting classes like QueryDict and file objects
  • Generic views
  • URL resolver
  • Other miscellaneous components required by the above (timezones, cookies, ...)

Documentation: Check the included README file
Twitter: @machinalis, @dmoisset

Previous / Next posts