And if the answer to my question is yes, what books/tutorials/screencasts/courses to people recommend to get started with?
And if the answer to my question is yes, what books/tutorials/screencasts/courses to people recommend to get started with?
Django and Rails, like Python and Ruby, look more and more similar as time goes on. Not because they are becoming more similar, but because the web ecosystem around them has become a lot more diverse. If you want a break from Rails, learn Phoenix! Or Node, I guess.
Furthermore, with the advent of fat front-ends, the utility of both of these frameworks has gone down in absolute terms. When they first came out, front-end features like form generation and HTML templating were really important, but now they're arguably better to avoid. (That's why channels are so important to the future of Django.)
That said, I still like Django a lot and use it all the time. I don't want to discourage you from learning it. But I wouldn't do it because you're trying to make a leap from Rails.
I was personally a Rails guy, then switched to learning Django, but had the experience you note...both frameworks solved many problems which aren't as relevant in this age of SPAs. I suppose if you really liked Django's ORM it might be worth it, but doubt there's a huge amount of value to be gained. YMMV.
Why is that?
That's not to say you can't do (or shouldn't do) form rendering, processing, error/success handling, etc. on the client-side, but the server should always have the last word on the validity of what you send.
I found Two Scoops of Django[0] to be a great resource if you want to follow the best practices for a Django app. The authors are also very active in the community.
[0] https://docs.djangoproject.com/en/1.10/intro/tutorial01/
[1] https://www.twoscoopspress.com/products/two-scoops-of-django...
If you want to give it a try anyway, Two Scoops of Django is a wonderful book, by two warm contributors from the Python community. https://www.twoscoopspress.com/
As for books, I'd recommend Two Scoops of Django[1]. Between that and the tutorial you should be up to speed pretty quickly. Maybe read it and see if anything appeals to you about Django?
However, Django has a much better security track record, and Python is used in a lot of other fields so learning the language has broader benefits. For these reasons I absolutely recommend Django to newbies over Rails.
Now get off my lawn.
If you want to use in an effective manner your Python skills acquired in scientific programming to build web apps,...I would recommend Django.
That said, I feel like nowadays Rails and Django are more or less equally capable, so choosing one over the other might be a matter of language and ecosystem preference over anything else.
I have worked on a lot of projects that involve science related stuff and Django.
Directly in the web app backend was relevant mostly for GIS apps that could take large raster data, process it based on the user's wishes, apply the right projections, apply a colormap and return an image to be shown on a map. Python has great tools for that sort of thing and it doesn't have to take much longer than rendering a HTML template does.
Other than that, the CPU intensive science-related stuff usually ran in background tasks, with Celery or otherwise. But those would still need access to the database, so why not use the same Django models for the web backend and the background tasks.
I find that once Django is part of your Python code it tends to find its way to all parts of it, through the ORM, settings files, handy admin interfaces, management commands as scripts, and so on.