[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Find something wrong with this

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 97
Thread images: 13

File: django.png (8KB, 1200x418px) Image search: [Google]
django.png
8KB, 1200x418px
Find something wrong with this.

Pro-tip:You cant
>>
Bumping for based django
>>
>>60662430
Bad support for long polling.
>>
>>60662430
nigger tier naming
>>
>>60662430
Python is a horrible lanuage.
other than that it's pretty good
>>
>>60663348
How is it bad?

>easy to learn
>load of people use it
>if you need extra performance you can drop down to c
>>
>>60663402
>He thinks those are advantages.
>>
>>60663402
Too many shortcuts, weird concepts which break stuff for begginers and give them bad habits, Python 2 vs Python 3, virtualenv shitfuckfest, easy to learn yet hard to master.


I prefer Java and javascript.
>>
File: 59479681986132181.png (5KB, 247x204px) Image search: [Google]
59479681986132181.png
5KB, 247x204px
>>60662430
it was a good film but terrible movie
>>
>>60663402
0x20 vs 0x09
>>
>>60663467
delete this
>>
>>60662430
It's a backend web framework. So basically the problems with Django are the same problems every backend web framework has. It's not a proper webserver and will never be better than a tried and tested webserver like Apache or Nginx. It's a glorified HTTP(S) library for Python (why use Python for web backends anyway?) and it needlessly complicates itself to disguise that fact. The way the configuration is done in Python rather than in a config file like any sane piece of software is absurd.

And what I find a lot of people doing with stuff like this is using an actual webserver to handle static content and other things which a proper webserver handles, while passing requests along to their program (parsing HTTP twice, lol)

The right way to do backend web development is with a webserver module for scripting support (like Nginx's Perl module). Stop making glorified HTTP libs, you absolute barbarians.
>>
>>60662430
Weak concurrency and parallelism support compared to Elixir/Phoenix.
>>
>>60665116
>why use Python for web backends anyway?
Because web developers are retarded
>>
>>60662430
All the magic going on under the hood, yuck.
>>
>>60665116
Its not trying to be a web server, it has a basic one built into it but you can just run your django projects on an Apache sever.
>>
>>60665172
Its called being versatile
>>
>>60662430
you have to redeploy when you make a change, as oppose to other frameworks like Java-Spring Boot, or dare I say it - [spoiler]Node.JS[/spoiler]
>>
Best django tutorials, for any topic, and any level of expertise? Videos, books, interpretative dance, any medium, I don't care.
>>
>>60665631
The django eCommerce/digital marketplace project on udemy is great.
>>
>>60665116
Have you actually done any commercial web development? Your opinion sounds very armchair general, to be frank, because you do not mention the normally claimed advantages of using a full-stack web framework even to dismiss them. Maybe you are a sysadmin pissed at the developers you work with?
>>
>>60665331
What do you mean? If you mean live reloading, you can do it with Django. Also, Node.js doesn't do anything for deployment or live reloading out of the box.
>>
File: banana-coon.png (237KB, 900x633px) Image search: [Google]
banana-coon.png
237KB, 900x633px
anime + bananas > django

you know this to be true
>>
>>60666178
Yea it's live reloading. I see the package now. Wasn't there the last time I used Django.

I guess the only flaw is that it's still slower than Java??
>>
>>60666136
>sysadmin
You pegged me right lol. I used to do freelance web development but opportunities ran dry and I got tired of dealing with the BS. Started doing sysadmin work for a local contracting company (basically a web development team targeted at small businesses) in early 2016 and have been enjoying it much more (more time to work on my own (non-web) projects ;)

However, they're very much "web hippies" as the senior developers are also the management. It seems every few projects, they want to do something new, which is, of course, very impractical from my perspective, since that means having so many different frameworks and other shit installed on our limited infrastructure.
>>
File: 1481354.png (74KB, 400x400px) Image search: [Google]
1481354.png
74KB, 400x400px
>>60662430
this kills Django
>>
>>60666617
>purple jizz that no one uses will kill django
>>
>>60666617
One big advantage Django has over Phoenix is the built-in authentication. Is there a good auth library for Phoenix yet?
>>
>>60663450
>virtualenv shitfuckfest
Wait, what's wrong with virtualenv? I use it without issue.
>>
>>60666648
>he doesn't know how to write his own authentication
>>>/php/
>>
>>60666666
>>
>>60666683
You got it all wrong. It's the PHPfags who love to rewrite shit like authentication from scratch for every project, each time subtly broken but in a different way. Personally, I believe in libraries, and I have implemented authentication enough times to not want to do it again, especially not the social login integrations. In Django and Rails this is a solve problem.
>>
>>60666828
>he adds social logins to his sites
>>
It's slow as balls
>>
>>60666857
I do. And you will, too, if you do web development for clients. Or hey, you could be an autist and try to dissuade them from using social logins by screeching about privacy or what have you. Hope that you then never do A/B testing, though, because A/B testing usually shows that normies prefer social login.
>>
File: 17.jpg (738KB, 1461x897px) Image search: [Google]
17.jpg
738KB, 1461x897px
>>60662430
Db queries are not as versatile as SQL alchemy
Otherwise good
>>
>>60666648
https://github.com/smpallen99/coherence
>>
File: djangobtfo0.png (124KB, 764x981px) Image search: [Google]
djangobtfo0.png
124KB, 764x981px
>>60662430
>>
File: djangobtfo1.png (65KB, 873x490px) Image search: [Google]
djangobtfo1.png
65KB, 873x490px
>>60662430
2nd
>>
File: djangobtfo2.png (17KB, 723x265px) Image search: [Google]
djangobtfo2.png
17KB, 723x265px
>>60662430
3rd
>>
>>60670647
>>60670658
>>60670671
What am I looking at here? Don't see any problems.
>>
File: yxkhur1os7whhncgc3ga.png (15KB, 200x200px) Image search: [Google]
yxkhur1os7whhncgc3ga.png
15KB, 200x200px
*blocks your path*
>>
>>60671316
He admits to cross-posting on Reddit, and complains they don't play along.
>>
>>60671316
There is no problem, reddit is becoming a giant inflated safe-zone where each subreddit is a walled garden. Quite pathetic really. I had to migrate back to 4chan due to the obscene amount of censorship and banhammers
>>
>>60663402
it triggers autismos because in 15min you can write what would have taken 3 hours in C
>>
File: Meteorjs.png (11KB, 766x347px) Image search: [Google]
Meteorjs.png
11KB, 766x347px
>Can create android and iOS applications with the same code
>Does not enforce any retarded MVC paradigm and instead allows you to setup everything as you like

>It's automatically integrated with Mongo, so you don't even need to touch Mongoose it's as simple as

 const Collection = new Mongo.Collection("mongoCollection");

Collection.insert({data: "whatever"});




The biggest downside so far is that all the tutorials are outdated, but I finally figured it out.

Tell me /g/ why would you hate this? (aside from Javascript, but the language itself shall improve over time).
>>
>>60672099
>>60663402
This was a legit answer a decade ago, but today you can write the same thing in Go in 25 minutes and no longer have to drop down to C for the performance-sensitive bits. Go is even easier to learn in some ways because it's a smaller language. And if Crystal takes off, you'll be able to write the same thing as fast as in Python.
>>
>>60672132
I don't know why the rest of /g/ hates it, but here is why I don't use it.
1. Bad client performance. Meteor applications use a lot more CPU on the client than equivalent React/Mithril + plain JSON API/websocket applications. You don't want users closing the tab with your product to shut up their laptop's fan.
2. Mediocre server performance. I haven't tested it myself, so I am going by the blogs of people who had to scale it.
3. MVC is good for you, especially if you are a webdev noob, which is what you sound like. If you think MVC is retarded in general, not for some specific cases and not because you prefer MVP, MVVM or something, do more web development then read up why it was invented. It'll click.
4. Mongo is simply a bad database. It is less reliable than Postgres or MariaDB. Most data you will work with is naturally relational. Doing aggregation in your own code is a costly waste of resources.
5. The project looks like it's in decline.
I haven't looked research Meteor's iOS/Android support, but it seems that they use Cordova, which looks and feels pretty bad next to React Native or even Xamarin Forms.
>>
>>60672357
I had been coding with Rails and Laravel before, slowly I realized it was the MVC model driving me mad, because I spent more time figuring out where to put 5 FREAKING LINES OF CODE, rather than coding.

It may work well for large projects of say 40,000 lines of code, but it fucking drives me crazy as a solo developer, so no I started avoiding any MVC framework like the plague.
>>
>>60672440
Django does not have this problem
>>
>>60672440
>It may work well for large projects of say 40,000 lines
I'd say it's more like 5,000.

It sounds like the source of your problem may lie in how you use ActiveRecord, because it is easy to end up with tangled code with it. I am not the biggest fan of ActiveRecord, and fortunately there are many laternatives for the M in MVC. I'd look at how Phoenix does models. If you don't want to learn a new language, try DataMapper for Rails.
>>
>>60672440
It's not really MVC's fault. Either the frameworks you're using are confusing or you still don't get how to structure your code in an MVC application. If it's the former then you should switch to something non-shit, and if it's the latter, then you should read some fucking code until you get how it should be done.

Also figuring out a proper architecture is as important as writing code. It can be very time-consuming and hard to get at first, but gets better with experience. Neglecting this aspect inevitably leads to spaghetti overflow and ridiculous costs down the road, but this is really software engineering 101.
>>
>>60672139
This, fast and fast compiling languages are the answer, not "dropping down to C".
>>
>>60672596
I do not find it hard per se, it's just annoying and/or confusing as fuck.

Being able to choose the way I distribute my code in files feels quite honestly, great; and distributing among several files is something that will be done eventually as my project becomes bigger, not the other way around.

This does not mean that I do not have a set of folders for different files it's just that I dislike being forced to search through like 4 of them to change a variable or whatever.


I know the MVC principles make some sense, but overall it triggers me to do so in the ways several frameworks impose it on you and the time lost triggers me even harder.
>>
I've tried learning Django multiple times and I just can't get through the docs without thinking "why the fuck is it like this? this is so much easier and nicer with PHP or node". I even like flask better. Django isn't straightforward at all
>>
Expressa and react seem to fit all my needs. Right now I'm doing deployd and react but I'll probably be converting the deployd stuff to expressa soon. Not quite as large a support community yet but at least it supports postgres.
>>
>>60672917
You need to invest in Django upfront.
>>
>>60672440

>the MVC model driving me mad, because I spent more time figuring out where to put 5 FREAKING LINES OF CODE, rather than coding.

Could you give an example?
I can hardly imagine spending too many time thinking about where to put my code in Rails.

As a rule of thumb I'd always try to put everything in the controllers, either one of the 7 basic CRUD actions or you trigger a "before_action" or "after_action" function here.

If this doesn't work you put it in the model.

If this doesn't work you put it in the asset pipeline.
>>
I have a lot of prior php experience, especially with the old mvc framework called Codeingiter. I've created many 10k line projects, and a few 30-50k line projects. Mostly CRUD apps. I was a sysadmin with a CS background, I'm now a Linux systems engineer and devops derp.

Anyway recently I needed to create my first CRUD app in awhile and these days I mostly use Python and Ruby for systems stuff, and occasionally flask or Sinatra for small services, but for this I needed an mvc web framework.

I first went with django. Did the tutorial, started working on my app, but I just didn't find it intuitive at all. Especially the touting it was making me rage at having to define every single route with nothing being automatic,m. Maybe I needed some libraries to handle this but I said fuck it and went to rails.

I did the excellent rails tutorial. I hadn't used rails since like 2006 so it was way different than I remembered. Old rails actually taught me about normalized database design but now it does everything for you. I started working on my app and felt so much more productive than with django. It was intuitive. All the basic stuff is automatic, so you take an interitive approach where you use the automatic stuff until you need more customization. It's much more in line with how I like to work.

I can't say django sucks because I'm not qualified to say so, having not really used it, but I feel it's not intuitive and I don't really like how it works. Keep in mind django was a CMS created by some newspaper IT staff, and wasn't meant to be a web application framework.
>>
>>60666372
Java is pretty fast BTW.
>>
>>60662430
As someone who spent a couple of years with Django, I must say it's ok and all, but the problems begin to appear as your project gets bigger:

1. The default template rendering engine is very very slow and limited as shit. You must replace with Jinja2 from the project beginning

2. The ORM is very nice and clean if you have simple tasks, once you begin to fetch complex queries, it becomes harder than plain SQL itself.
There is no direct way to replace it with SQLAlchemy

3. It's slower compared to Node and the Golang
>>
File: ss-2017-05-31-12-20-54.png (192KB, 943x549px) Image search: [Google]
ss-2017-05-31-12-20-54.png
192KB, 943x549px
>>60666372
it's faster than php and rails
>>
>>60673066
Luckily they added native support for Jinja2 in Django 1.8.

As for the Django ORM it is more limited than SQLAlchemy but it is much easier to use if it matches your use case. For example transactions mostly just work with Django ORM while with SQLAlchemy you have to be much more careful and really know what you're doing. No real answer which is better though since they have very different goals.

I don' think the speed is that much of a problem if Instagram and Disqus can live with Django just fine.
>>
>>60673345

There are lies, bloody lies and benchmarks..

Passenger server is up to 4x faster than Unicorn. Also for a simple "whoa, check my 10,000 pings" app you wouldn't use Rails, but something like Sinatra or Cuba..

That's like comparing an eight-wheeler with a motorcycle: yes the motorcycle is faster, but that doesn't mean it's always the right choice.


Rails and Django are pretty similar, it boils down to wether you like Python and prefer having everything as explicit as possible, or you like Ruby and prefere some magic words that automate the boring parts for you.


PHP is always a good choice, since it's everywhere, but we all know it's not the most beautiful, clean or sane language out there...
>>
>>60662430
png is not optimized
>>
>>60672941
>You need to invest in Django upfront

There is no advantage to investing in Django. Nodejs+Express will utterly wipe the floor with Django is support, speed, and consistency.

Django isn't actually good for anything. There is no reason to use it, unless you have legacy codebases or are an autist and have to write everything in Python.
>>
>>60662430

I would really appreciate django having some reference applications to use as example in order to explain various topics.
>>
>>60674695
>There is no advantage to investing in Django
There is. For one thing, if you're working on multiple projects you will get a level of consistency between the projects that you would have to work on enforce yourself with a microframework like Flask or Express. There are other advantages that you could learn about if you did just a little research and read various developers' evaluations of it. I won't name them, however, because I'd rather people who don't do research not use Django.
>>
>>60663402
>if you need extra performance you can drop down to c

are you retarded
>>
>>60666967
I hope you're kidding. it is morally wrong to implement social logins

just dont
>>
>>60675023
>Compile c library for one task
>call it from python
are you fucking retarded
>>
>>60675038
Do you program for a living?
>>
>>60675051
>defends Python by saying C is much faster

okay homie
>>
>>60672139
Also Nim, which has a similar syntax to python
>>
>>60675110
Some task reguire fast language but most of the stuff can be done in python. Python / C makes good combination.
dumb nigger
>>
>>60662430
>Find something wrong with this.
https://github.com/django/django/pull/2692
>>
>>60675190
Nothing special. Developers can't afford to speak truth to power, so they merge.
>>
>>60675190
that settles it - I'm not using Django
>>
>>60675190
>Before the flood of white male HN dwellers truly kicks off and obliterates all reasonable discussion, I'd like to thank the Django team for taking the time to do this.
Fucking white males always obliterating reasonable discussion.
>>
>>60672132
It's good for small internal applications.
>>
>>60662749
Don't long poll, anon. That's so 2008
>>
>>60675295

I really like this girl:
>https://github.com/django/django/pull/2692#issuecomment-44517216

>I find it particularly notable that the vast majority of the pro-"primary/replica" arguments are subjective and general, while most of the pro-"master/slave" arguments are more objective, practical, include coherent reasoning, and are more grown-up. Is one side loaded with guilt and fear, while the other side stays logical and practical?


I also think it's really condecending towards BDSM couples that are in a happy "master/slave" relationship..

Check your goddamn priviledge!!
>>
>>60674695
>>60674992
Every code base will eventually become a legacy code base. Have fun maintaining that Nodejs+Express project over the years. Django on the other hand has LTS releases and a set schedule when next releases come which is super nice when you have multiple projects in maintenance mode. After 1.4 I've been riding only LTS releases for comfy stability.

Not all that cutting edge but I'm reserving that for the front end.
>>
>>60676556
>Have fun maintaining that Nodejs+Express project over the years

You know there is something called a package.json for every single project? This contains all the legacies, scripts, etc. that you need for a project. NPM is currently the best package manager out there. Not to mention there are LTS versions of both Node and Express.

Maintaining a Nodejs+Express application will be light-years more comfortable than a legacy Go codebase, when you realize that you can't just 'go get' anymore because everything will break. There is no idiomatic way to handle vendoring, in a language that prides itself on being as idiomatic as possible.

Maintaining Python code is already stupid as fuck, because of how they broke the language from 2 -> 3, then back-ported most of the features to 2 anyway. So you still have plenty of people writing 2.X.
>>
>>60663402
Forced indentation that how.. That's retard tier.. Might as well learn Basic, it's a more mature and robust language and for extra performance you can "drop down" to assembler. Pro Tip.. Python IS Basic without the closing tags (endif, loop etc..) and with forced indentation. Just learn Basic and Assembler.
>>
django just wants to be rails.
It's like a nigger trying to be a white person.
>>
>>60663467
of course you press tab, but let the editor insert spaces, why would you want to press spacebar?
Also, Google is retarded, they use 2 spaces for indentation.
>>
99% of the machine learning community uses Python. There is nothing better on the market.
GIL though...
>>
>>60675038
>I hope you're kidding. it is morally wrong to implement social logins

This. I bet he's the kind of faggot that would help code an designed to exterminate all human beings if he was paid to.
>>
File: IMG_0023.jpg (167KB, 957x1518px) Image search: [Google]
IMG_0023.jpg
167KB, 957x1518px
>>60678959
pay, ass or servo mmm?
they said they don't want money maybe if i plugin the computer for like a week everything done
>>
>>60679217
another question. what exactly is all this? is it like a big brother without the participants consent? did anyone ever got caught by thes same malware before.

inb4 no replies as always.
>>
>>60678915
Though I guess it's not exclusive to use one or the other, you should probably give some of that percentage to Scala because of Spark & MLib.

These have been growing extremely rapidly.
>>
File: play_full_color.png (20KB, 2154x1125px) Image search: [Google]
play_full_color.png
20KB, 2154x1125px
>>60662430
Django seemed better than Rails to me the last time I tried, and an overall pretty well managed software project.

I guess I mainly just don't like Python very much. It's not a particularly strict language in a bunch of ways, and I generally prefer strict-er rather than getting blindsided by some random crash because of a string error on logging code because of an OS default codepage mismatch or such.

That the default Python is pretty slow is of course another flaw.

But I'm still glad Python and Django exist and get better over time. Maybe I'll eventually find a reason to use them. Or not.
>>
>uses the slowest interpreted language for the web
>has to shard hundreds of severs to cope

Aaah~ the life of a P Y T H O N I S T A
>>
>>60677662

Ahahahaha..

Funny because it's true.
>>
>>60676720
>There is no idiomatic way to handle vendoring
This is no longer the case. https://stackoverflow.com/a/37238226/
>>
>>60678959
>exterminate all human beings if he was paid to
No, because that would mean exterminating me and the people I care about, hence making the pay useless.
Thread posts: 97
Thread images: 13


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.