10 ms·
Django 1.9 Released
- FabioFleitas 11y agoExcited about the new JSONField added: https://docs.djangoproject.com/en/1.9/ref/contrib/postgres/fields/#jsonfield https://docs.djangoproject.com/en/1.9/ref/contrib/postgres/f...
- Alex3917 11y agoI upgraded from hstore a couple days ago. I expected it would take me a couple days, but it only took two or three hours. I basically just had to replace the field in the model, and was surprised to see the test suite passing. But it turns out that all of the application code just magically worked as is. And it's also a security win since you needed to be a Postgres superuser to install hstore.
- johndevor 11y agoWhat does the new admin style look like?
- collinmanderson 11y agohttps://docs.djangoproject.com/en/1.9/intro/tutorial02/#enter-the-admin-site https://docs.djangoproject.com/en/1.9/intro/tutorial02/#ente...
- cdnsteve 11y agoParallel tests, curious if folks are seeing a big difference in their existing testing suite? On_commit sounds nice.
- jkarneges 11y agoBefore anyone says something about Django not being hip enough for realtime stuff, just know that you can layer Pushpin (http://pushpin.org http://pushpin.org) in front of it. This may sound like a bandage but it's actually good design, regardless of programming language. Disclaimer: author.
- simonw 11y agoI'm a big fan of the design of pushpin - it's a really elegant solution for adding real-time features to frameworks like Django. I don't think it feels like a band-aid at all: for most web programming tasks, I'd much rather think in terms of a standard request/response cycle - it makes scaling with a shared-nothing architecture much easier to reason about.
- iyn 11y agoI didn't hear about Pushpin before, looks like a solid product, will definitely look into it. I'm not sure if that's a valid question, but how does the Pushpin compare to something like SwampDragon (http://swampdragon.net/ http://swampdragon.net/), besides not being tied to Django?
- jkarneges 11y agoSwampDragon is a more comprehensive solution. It comes with a JS client and lets you define data models. Pushpin is lower level. It has no client protocol nor client library and handles various push primitives on behalf of the backend. If you want to add realtime endpoints to an existing Django project, or if you want to build an API, then Pushpin may be preferable. SwampDragan may be preferable for new, non-API projects. It might be cool to see the two projects integrate somehow, since they actually sit at different levels in the stack. There could be value in SwampDragon being able to delegate push responsibility to Pushpin.
- ergo14 11y agoI'm doing my own thing called channelstream: https://github.com/AppEnlight/channelstream https://github.com/AppEnlight/channelstream It's gevent based and supports websockets and long-polling, by design it integrates with any kind of application for real-time broadcasts, be it django, php, cron scripts etc.
- jsmeaton 11y agoAndrew Godwin (the author of django migrations and south before that) is working on something he calls Django Channels http://channels.readthedocs.org/en/latest/ http://channels.readthedocs.org/en/latest/ . The aim is to bring it into core (possibly for 1.10), which will allow real time features. The traditional request/response cycle will then just become producers and consumers of a "request" channel.
- jMyles 11y agoIf you are deploying a new django project, let me suggest hendrix (twisted + django) as your WSGI publisher. hendrix makes concurrency simple, fun, and fast using Twisted, which is battle-tested and experiencing an amazing renaissance of young talent (as evidenced by the amazing vibes in the Twisted room at the PyCon sprints). https://github.com/hendrix/hendrix https://github.com/hendrix/hendrix
- jsmeaton 11y agoI can't say I've used twisted at all, but Amber had a fairly good talk at Django Under the Hood this year on this topic: https://opbeat.com/events/duth/#twisted-and-django https://opbeat.com/events/duth/#twisted-and-django
- japhyr 11y agoI just got around to skimming the release notes, and I'm curious about running tests in parallel. I'm looking forward to upgrading, and seeing if this has a meaningful impact on my tests. I don't have a large number of tests yet; my project runs its full test suite in ~10 seconds at the moment. But I'm well aware this should grow significantly as my project matures. Does anyone have any sense yet of how this affects the speed of the test suite in your real-world projects? https://docs.djangoproject.com/en/1.9/releases/1.9/#running-tests-in-parallel https://docs.djangoproject.com/en/1.9/releases/1.9/#running-...
- cscharenberg 11y agoMassive speedups once you get to thousands of tests. We 12 minute runs for the 3 apps that are part of a release. When we went parallel it reduced it by 1/6 (6 test processes). Of course, we also had some slow tests we rewrote and had to fix some tests that did not play nice concurrently. But it was well worth it. I don't think you'll see a big benefit for a current 10-second run because of fixed cost of startup is some of that. But running tests in parallel may reveal some bad testing practices: leaving data behind or improper mocking that cause tests to fail in parallel. Fixing all that once you get to a massive set of tests is really painful and slow becuase you have to fix them ALL before switching your testing config. So that might be a benefit to turning it on soon and growing your tests already in an parallel environment.
- japhyr 11y agoThanks for the thoughtful response. I appreciate the perspective on what it means for large test suites, and why it's beneficial to think about this in early development stages as well.
- snogglemedia 11y agoIs the Django team planning anything big for a 2.0 release?
- ubernostrum 11y agoExpanding a bit: the plan is that 2.0 just switches us to a new versioning system. The tl;dr is: Versions start going 2.0, 2.1, 2.2, then 3.0, 3.1, 3.2, then 4.0, 4.1, etc. Every X.2 is a long-term support release. The deprecation cycle gets tweaked so that if you're on, say, 2.2 LTS and your codebase runs with no deprecation warnings, then you'll be able to just run as-is on 3.2 LTS. You can then clean up any deprecation warnings on 3.2, and you'd be good to go for 4.2 LTS, etc.
- Scarblac 11y agoAnd as a special case of that: according to the current roadmap, 1.11 will be the last version to support Python 2.7, 2.0 won't.
- minimaxir 11y agoNot for a couple years: https://www.djangoproject.com/weblog/2015/jun/25/roadmap/ https://www.djangoproject.com/weblog/2015/jun/25/roadmap/
- jsmeaton 11y agoNo, not really. Django is moving to an "almost semver" versioning system. The X.0 releases will be when deprecated features are actually removed. There are still some big ticket features that various people want to work on. These get released as they become ready. There may be some feature that is targeted for 2.0, but we won't know what until after 1.11.
- ponytech 11y agoThe integration of Andrew Godwin's django channels [1] would be a big thing :) [1] https://github.com/andrewgodwin/channels https://github.com/andrewgodwin/channels
- theli0nheart 11y agoMusic to my ears! I literally just installed 1.9rc2 thirty minutes ago. Congrats to everyone involved in the release.
- dudus 11y agoI'm curious what the redesigned admin looks like, does anyone have screenshots?
- omniaura 11y agoLooks like the new intro tutorial docs have some screenshots: https://docs.djangoproject.com/en/1.9/intro/tutorial02/#enter-the-admin-site https://docs.djangoproject.com/en/1.9/intro/tutorial02/#ente...
- jsmeaton 11y agoIt's CSS only changes to be backwards compatible. Here's a screenshot I dug up from google. http://imgur.com/3xGdZ04 http://imgur.com/3xGdZ04 The changes were originally released in a 3rd party package: https://pypi.python.org/pypi/django-flat-theme https://pypi.python.org/pypi/django-flat-theme that has some screenshots too.
- mangeletti 11y agoThank you everyone who committed their time and code to this release.
- rafaquintanilha 11y agoThis is still better when you are able to experiment versions without quirks and workarounds. Hail virtualenv.
- meetbryce 11y agoalso, hail Docker.
- olau 11y agoDjango is really easy to deploy manually too. Download the tarball, untar it, make a symlink from inside your project dir to the "django" subdir. If you want to try another version, you just change the symlink to point to the other version. If you are curious which version you're running, you can just do a "ls -l" in the project dir. That's it.
- jsmeaton 11y agoThis might be a good time to mention that Django is always trying to raise funds: https://www.djangoproject.com/fundraising/ https://www.djangoproject.com/fundraising/ The really quick turn around on tickets and pull requests is largely thanks to the Django Fellow, who is paid to manage the community. The last two or three releases have been on time because of the Fellow. The Fellow is funded via Django Software Foundation fundraising activities. If your company is deriving financial benefit from using Django, consider asking your company to sponsor the fellowship program, so that we can ensure that bugs are getting fixed, releases are happening on time, and security releases are being processed as a priority. (Disclaimer: core member).
- kawera 11y agoGood call, this is very important! It's baffling that such a huge project, used by thousands of companies including at least one billion dollar unicorn, have such a hard time finding money to fund only one single developer. As a solo owner and happy Django user, I've donated what I could and encouraged others to do so but would love to find a solution to entice larger businesses to donate regularly.
- hanniabu 11y agoWhat do you envision the solution looking like? A list of projects, with their updated runway, yearly budget, technology category and subcategory? Maybe create a watch list too and send notifications when the combination of their runway, yearly budget, and rate of donations reaches a critical point of becoming unsustainable. You can also have people give a range of what they'd be comfortable donating. When the project comes to a critical point, the first line of defense is to send notifications to larger businesses and as a project becomes more in danger the notifications get sent down the line to the people whom have smaller budgets.
- jsmeaton 11y agoThe Django Software Foundation has just hired a part time person to organise fundraising [0]. There is also discussion happening around the community about trying to find a sustainable way of funding open source projects and Django in particular. Part of the problem is that it's hard to get companies to "donate" money. If they can purchase something like "support" or something else tangible, or "sponsorship" out of their advertising budgets, there may be more opportunities of gaining funding. Thank you for donating though! Django gets a lot of their money from regular developers' pockets. I, personally, feel that bigger companies using Django to generate lots of revenue should be contributing a greater portion to support the stack that supports them. [0] https://www.djangoproject.com/weblog/2015/nov/23/introducing-dsfs-director-advancement/ https://www.djangoproject.com/weblog/2015/nov/23/introducing...
- sparkling 11y agoNot looking to start a fanboy-war here; but i would like to hear some opinions. If you were to start a new small to medium sized web app today, would choose Ruby on Rails or Django?
- ebbv 11y agoFor me this is the wrong question to start with. The right question is what language do you want to work in first. Then determine which framework for that language best suits your needs.
- ahmad19526 11y agoI would say if you anticipate any sort of data science and machine learning potential in your application, then you should choose Django (Python) because you'll be in the home turf for this sort of work and you won't have to deal with language context switching... But this is a big if and may not be worth considering.
- huac 11y agoIf your app has data of a large enough size for serious analysis, shouldn't you be building a data warehouse separately and performing analysis on that? (scientific) Python is definitely better at stats out of the box than Ruby is though.
- pbreit 11y agoI'm shocked, frankly, at how lousy both are out-of-the-box. I just don't get why a simple CRUD app (which many/most apps are) has to be so difficult. I had trouble figuring out how to do email login on Django and just gave up. At first, Rails seems like it's going to be a lot better. I don't care for generating files. Don't like TDD. And found the migrations very confusing (if I make a typo in a field name, I delete the whole project and start over). I can't believe this is the current state of web app development. I know everyone's moved on to Node and Angular, but, c'mon!
- jsmeaton 11y ago
- collinmanderson 11y agoThis is the second perfectly on-time major release in a row. Way to go team!