Live data from Hacker News

Most popular Python packages now support Python 3

py3readiness.org

141–150 of 166 posts

Re: Most popular Python packages now support Python 3

#141
post #115

Earlier quoted context omitted.

I'm currently using Go (and Python - we did go from Python 2 to Go, but later continued using Python 3) at work, but for all of the hoopla about it's concurrency, the reality is I'd rather have Rust's superior runtime safety and metaprogramming. A few things have impeded on Rust adoption at work: - Learning curve. Rust is not as bad for learning as C++, but any language with strong metaprogramming and unfamiliar or r…

I kind of like the idea of Rust, but I don't really have much belief in complex programming languages. C++ only has a large following because it piggy backed on C, which people already knew, then it gradually grew its complexity. It is quite a different challenge to get people to use an entirely new language with high complexity. Companies are going to be negative towards adopting a language with a steep learning cur…

I don't think that's why C++ is popular - I think that C++ started as "C with Classes" is what got it off the ground, but if it were just that it wouldn't be around today. Similarly, Objective C doesn't enjoy much adoption outside of it's creator's domain, despite the obviously more elegant integration of object oriented programming.

I think, rather, C++'s brand of metaprogramming ended up being a big deal. C++ template metaprogramming and now const_expr allow for doing a lot of work at compile time, allowing higher level constructs to compile away to virtually nothing.

That it's compatible with C definitely helps still though, since it means you can still use C libraries and APIs, including the APIs of most operating systems.

In C++ there were programming styles that were "memory safe," relying on a combination of stack based lifetime and 'smart' pointers. While in practice most C++ code is very far from memory safe, I'd say this alone vastly improved software quality over C for big projects.

Rust represents an opportunity to do all the things C++ did right in a fresh language that is actually memory safe and doesn't suffer from the syntax C++ has. To me it's no surprise it was developed by the same people who write browsers - these are people that "get" it when it comes to huge, mission critical codebases. The complexity of Rust isn't a bug, it's a feature.

Go's simplicity is it's biggest strength and weakness, in my opinion. Code generation isn't cutting it as a substition for good low cost abstractions. Don't you hate when you end up in scenarios where you wish things could be typesafe but you realize to get there you'd need to write a codegen? I.E. there's a typesafe GraphQL library for Rust, but the equivalent library in Go will drop you back to interface{} constantly.

I would implore people to try to look past the instinct that simple is better in some cases. There's a balance to strike that yields the best benefits of 'simple' and 'featureful' and I personally believe Rust is closer to it than Go or C++.

I will still be coming back to Go and look forward to Go 2.0, but it'll be hard to look past some of the shortcomings when I'm writing performance critical code and wish I had more safety and control.

(Sidenote: I have a performance critical piece of code at my work written in Go, and it ends up using a ton of memory as a property of the GC. Go's low latency GC is cool, but there are definitely trade offs.)

(Sidenote 2: I wasn't enticed by Swift enough to give it a try, so I have no comments to make on Swift. I'm sure it's fine. It doesn't seem to be what I'm looking for.)

Re: Most popular Python packages now support Python 3

#142
post #8

Clicking around, those that don't seem to be: 1. Obsolete. Either explicitly so (e.g. Google API) or abandoned, without even a minor/patch release (initools, 2010) or in some cases a code commit (e.g. pathtools, 2012) for five years or more. I suspect that they will never be Py3, the community will just move on to alternatives. 2. Working hard to bring support (e.g. ansible). 3. Part of the graphite ecosystem. If the…

[deleted]

Re: Most popular Python packages now support Python 3

#143

Earlier quoted context omitted.

Open source doesn't mean the source must be publicly available for everyone to read. :)

That's exactly what I thought open source meant. How can a source be open if not everyone can read it? I didn't get your comment.

Open source can mean that the source is available on request, or is available after purchasing a licence. It doesn't have to be publicly available to be open source, though in practice it pretty much always is.

Re: Most popular Python packages now support Python 3

#144
post #24
post #12

Earlier quoted context omitted.

As much as a I like Go in general, there are two pythonic things that, IMO, really should go into the next major revision. 1: sets; in this day and age, not having sets as native, stdlib-provided data types is simply unacceptable.[ß] 2: The ease of python's "in" keyword; being able to test for a key in a map (or set!) without any indirection is crucial ß: granted, IIRC python moved sets into native stdlib types only…

Sets don't need to be native in languages that are both fast and have a proper type system. For example, rust and OCaml have a standard set in their stdlib, but it's not builtin. Of course, go lacking generics makes it impossible to implement a decent set type in it.

I wouldn't hold up OCaml as an example of how to structure your standard library, the lack of standardisation in its standard library is one of the remaining weak points of an otherwise excellent language. For those that don't know, there are multiple standard libraries for OCaml, each with different trade-offs, leading to unnecessary fragmentation.

Re: Most popular Python packages now support Python 3

#145
post #3

Nice work everyone! I’d be curious to see what a “Python 2 deprecation” page would look like (although deprecating Python 2 support shouldn’t be the goal of course)

Based on having worked for 3 corporations using python I can tell you it's not going to happen by 2020. Python 2.7 will live on in big companies for a couple more decades. I will end my career before python 3 is adopted. It's more likely that by that time some other scripting language will be more popular.

Re: Most popular Python packages now support Python 3

#146
post #85

Earlier quoted context omitted.

You're claiming to know the future of Python better than "Python people" know the future of Python. Python has changed incompatibly once in 26 years, and never plans to do it again, yet you're making it sound like an ongoing pattern. What language are you going to run to that has that kind of track record?

30 years later, scheme is still scheme. A different report has come out, and some compilers choose to implement it. But the language hasn't changed. See my point?

If you read the original Scheme report, you'll notice that it's full of example programs, zero of which run on modern Schemes. They're full of operators that Scheme doesn't have anymore, like BLOCK, PROGN, CATCH, ASET, -$, *$, //$, EVALUATE!UNINTERRUPTIBLY, START!PROCESS, etc.

Re: Most popular Python packages now support Python 3

#147
post #24

Earlier quoted context omitted.

Sets don't need to be native in languages that are both fast and have a proper type system. For example, rust and OCaml have a standard set in their stdlib, but it's not builtin. Of course, go lacking generics makes it impossible to implement a decent set type in it.

I wouldn't hold up OCaml as an example of how to structure your standard library, the lack of standardisation in its standard library is one of the remaining weak points of an otherwise excellent language. For those that don't know, there are multiple standard libraries for OCaml, each with different trade-offs, leading to unnecessary fragmentation.

Agreed, some things are still missing (in particular my pet peeve, iterators; also unicode strings). But for what it provides, OCaml's stdlib is reasonably well designed and performs well.

Re: Most popular Python packages now support Python 3

#148

I would like to know if fellow HNers who regularly code in Python are using f-strings and type hints in your production code or otherwise. I often find myself inclined to use type hinting.

Love the f strings but I sometimes don't use them if I'm worried that the code won't necessarily be run in Python 3.6. Unless it's a self contained docker container - I'm wary of using the f strings everywhere just due to compatibility issues.

Side note: Languages like Ruby have had this for a long time. Better late than never, Python!

Re: Most popular Python packages now support Python 3

#149
post #134

Earlier quoted context omitted.

In addition, Fabric doesn't support Python 3. The feedback I've gotten back on when Python 3 will be supported and how much of the legacy fabric API's will be supported is even more limited. There is a fork with Python 3 support: https://github.com/mathiasertl/fabric/ If you use fabtools, I maintain a fork of it for fabric3: https://github.com/develtech/fabtools/tree/fabric3

I use your fork, thank you for your work!

[deleted]

Re: Most popular Python packages now support Python 3

#150
post #8

Clicking around, those that don't seem to be: 1. Obsolete. Either explicitly so (e.g. Google API) or abandoned, without even a minor/patch release (initools, 2010) or in some cases a code commit (e.g. pathtools, 2012) for five years or more. I suspect that they will never be Py3, the community will just move on to alternatives. 2. Working hard to bring support (e.g. ansible). 3. Part of the graphite ecosystem. If the…

In addition, Fabric doesn't support Python 3. The feedback I've gotten back on when Python 3 will be supported and how much of the legacy fabric API's will be supported is even more limited. There is a fork with Python 3 support: https://github.com/mathiasertl/fabric/ If you use fabtools, I maintain a fork of it for fabric3: https://github.com/develtech/fabtools/tree/fabric3

Yeah, the fabric3 fork works really well.

Also, the fabric author has been making a lot of progress on Fabric 2, which works on Python 3.

https://github.com/fabric/fabric/tree/v2

Post reply on HN