[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]

Did people start using Python 3 yet?

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: 41
Thread images: 6

File: Python-logo-notext.svg.png (72KB, 1024x1024px) Image search: [Google]
Python-logo-notext.svg.png
72KB, 1024x1024px
Did people start using Python 3 yet?
>>
>>52537855
No nobody has ever used it.
>>
>>52537855

There are some people using it, but far and wide 2 is still king and that won't be changing any time soon.
>>
my compsci class uses it
>>
my devops team is strictly writing tools in python 3.

2 is going to be eol'd in 2020.
>>
>>52537855
The whole 2 vs 3 thing is such bullshit. I switched over to Java just to escape the autism that is the python community.
>>
>>52538429
>Java

learn a real programming language
>>
Actually I do. I know somedays it will become populist so I already started to work with in every new project
>>
>>52538474
Not him but please suggest one - a beginner at programming
>>
>>52538474
>trying to start shit about "real" programming languages in a fucking python thread of all places

Nice try.
>>
>>52538506
Python
>>
>>52537855
python 2 -> python 3
cosmetic changes
>>
File: 4chandown.png (44KB, 520x277px) Image search: [Google]
4chandown.png
44KB, 520x277px
>>52537855
I generally try to write code that builds and runs on both 2 and 3, but I don't always have the time, and whether it _actually_ works is largely dependent on how much of an effort I put into writing tests.
>>
>>52538474
>learn a real programming language
Java is easily as "real" as Python.

Runs important and performance critical stuff in the back-end of like every second really big commercial website, runs much of the show on the wildly successful Android, runs a lot of business software...
>>
>>52537855
Yes, unfortunately the mess that some use Python 2 and some use Python 3 without the ecosystem really fixing its shit is now a decade ongoing.

It is really ridiculous.
>>
File: handman.png (1MB, 1200x1000px) Image search: [Google]
handman.png
1MB, 1200x1000px
>>52538547
>shitposts over Java
>recommends Python instead
>>
>>52537855
using it right now
// check for 4k retina display
import faggot
print op is a faggot
>>
File: tsk.png (31KB, 219x200px) Image search: [Google]
tsk.png
31KB, 219x200px
>>52540984
>can't even basic python syntax properly
>>
File: Python2vsPython3.png (12KB, 635x363px) Image search: [Google]
Python2vsPython3.png
12KB, 635x363px
>>52537855
The print function meme aside.

I'd say probably the biggest hold out and probably the larger chunk of the userbase is from academia, so let's look at it from that perspective. There's basically no incentive to port billions of lines of code to Python 3 when:
>There are no real advantages.
>If there is, this is not being communicated to the academic community.
>No one else is doing it.
>Most academics who will be using 2.7 for the forseeable future don't even have a dual install.
>print musle memory is import for development, and this is actually a problem not just a meme since it's one of the first things people trying to switch find.
>They will have to pry 2.7 from my cold, dead hands.

REBEL AGAINST PYTHON 3, FORCE THEM TO END SUPPORT FOR 3 AND KEEP 2 MASTER RACE.
>>
>>52538429
>Implying it's a competition or matter of opinion
Python 3 is objectively better. Only thing keeping 2 alive is legacy code, which means it will probably be around forever.
>>
>>52541161
>Python 3 is objectively better.
According to it's own official wiki:
>It's slower
>Mostly takes away features of 2.7
>Doesn't add anything useful
>BUT IT'S THE FUTURE GUYZ WE SWEAR
>>
why doesn't (didn't? how many years since python3 now?) someone just make something like gofix for python code so that migration to python3 can be automated and painless?

https://blog.golang.org/introducing-gofix
>>
The reason people write python is because it is easy.
Rewriting it to v3 is too much for for people who didn't want to do the work in the first place
>>
>>52541290
There's plenty of software to port code to 3. The point is no one wants to use 3. It diverges from Python philosophy and is basically just developers jerking themselvs.
>>
>>52541290
There's a tool called 2to3 that can handle many details but not everything. If you don't have good test coverage who knows what will be broken afterwards.

And given how tied the stock Python C API is to the interpreter's implementation, I wouldn't be surprised at all if shitty enterprise C libraries failed to work in Python 3.
>>
>>52540957
I don't hate java but python is a lot easier and more enjoyable as a programming language
>>
>>52541290
Exists, not reliable enough. Still will require a lot of manual porting and testing, and all that usually for no tangible benefit.

Besides most Python deployments never had preparations in build tooling and the environment (often Windows on many semi-unmaintained boxes) to handle this change sanely either.

So really, Python2->Python3 remains a mess after like a decade despite being utterly undramatic in scope as compared to what other ecosystems pulled off in months (no they didn't migrate all software entirely either, but the still actively developed libraries people relied on and everything like that DID migrate there, and the rest kinda branched off to legacy support).
>>
>>52541471
Try Kotlin, Ceylon or Scala.

Well, they can't really replace Python as sysadmin scripting language and middleware between C or C++ programs.

But they're have some fairly big advantages for just programming software.
>>
>>52541471
Somehow Java feels like it's _just_ high level enough to suffer from it in terms of performance, while still being as stiff as a system programming language and having less flexibility than most of those too.

It's not all bad; Java tools tend to have really strong code intel and refactoring features because the nature of the language makes it easy to understand what some token at a given position means. Working on an Android project for a while was almost refreshing because the code completion actually worked all the time and errors were pointed out before compilation.

But if I wanted to throw something together quickly and not wade through boilerplate and project wizards, I'd definitely start with Python.
>>
>>52541142
mainly because of retarded shit like debian shipping 2.7 by default
>>
>>52541581
Java is very fast for a gc'd language.

And the strictness tends to be a good thing since it catches a lot of errors already at compile-time.
>>
>>52541142
The print function is actually very nice, since it allows for optional parameters that can turn off newlines or print to a different stream.
Which was always a bit awkward in Python 2.
>>
File: akka-logo-cloud.png (42KB, 940x200px) Image search: [Google]
akka-logo-cloud.png
42KB, 940x200px
>>52541581
>Somehow Java feels like it's _just_ high level enough to suffer from it in terms of performance
Wrong impression.

Performance is generally no big problem, most of the big website deployments actually run performance critical stuff on the JVM (Java and Scala).

> while still being as stiff as a system programming language and having less flexibility than most of those too
Depends very much on what you're doing. But C++ got less stiff quicker than Java did recently, yes.

But Python? It's not really more flexible. It's kinda even more constrained to its own niches in smaller non-system programs... unless you want performance issues and lots of issues with code maintenance over time and so on.

> But if I wanted to throw something together quickly and not wade through boilerplate and project wizards, I'd definitely start with Python.
Java minus boilerplate? Learn Scala / Kotlin / Ceylon.
>>
>>52541613
Why is Debian so based?
>>
>>52541613
Every decent distro does that.
Slackware 14.1 also uses 2.7 by default.
>>
>>52541634
Indeed it is. Though if you somehow get to the point where the VM just doesn't cooperate and you have to start pooling objects or something to keep the heap and collection pauses under control, one starts to wonder if this was the right tool for the job. Somebody at my last workplace had basically run and documented -Xcthulhuftagn=12347M guessing games for a living before.

>And the strictness tends to be a good thing since it catches a lot of errors already at compile-time.
Or even before that, which is _very_ nice coming from Python and C.

>>52541683
I've been meaning to check out Scala anyways, maybe I'll do just that.
>>
>>52541773
>Or even before that, which is _very_ nice coming from Python and C.
That depends on the IDE, I think Clion can catch compiler errors/warning while you type too.
Compiler integration is getting a lot better thanks to clang (gcc purposely tries to be hard to integrate with anything else - fuck you rms)
>>
>>52537855
Most pythonistas are highly superstitious, so no.
>>
>>52541831
Yeah, I think Xcode does something like this too. It's nice but probably much harder for an IDE to get right because of the preprocessor and everything; having a real compiler frontend probably helps.

I think I saw some discussion on the gcc mailing list about how its frontends should be better at exporting symbols, but they're so afraid of someone taking the syntax tree and dumping it into a closed backend it's not likely to go anywhere.
>>
>>52541679
If you're using print for anything else other than
 print 'TEST'
or
 print [VAR]
you should probably be using something else.

>it allows for optional parameters that can turn off newlines
Except you could place the string in a single entry tuple and get the same effect with the statement.
>>
>>52541935
>Except you could place the string in a single entry tuple and get the same effect with the statement.
What?
print ("Bla",)

just prints out the tuple with trailing new line
Thread posts: 41
Thread images: 6


[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.