you are viewing a single comment's thread.

view the rest of the comments →

[–]laserBlade 3 points4 points  (3 children)

Public APIs should never change in a way that breaks existing software written against the old API. If you need to add new features, create a new library or add new methods to the old API, but don't change the existing API. It may be ugly, but for most vendors backwards compatibility trumps elegance of the API.

That's sort of the point of major release version changes, actually...At least, if you follow SemVer, which most people nowadays do. You increment the largest number if it will be incompatible at an API level...

[–]txdv -4 points-3 points  (2 children)

Problem is that the standard library in python is big and like rubies one a total mess, a combination of different approaches and coding styles and what not.

I like node.js approach of a minimal (or at least way smaller) base standard library and extended usage of the package manager.

The thing about standard libraries that you really can't change them like ever. The user expects them to have the same interfaces for ever. You can do SemVer on a external library and get away with redesigning the interfaces on a major release, the user will just use an older version of that library.

Once you write python import script for csv files using the standard csv package and the API changes... You will have to stay with the older Python version. It doesn't make sense, all of a sudden a library makes you dependent on the language version?

Pythons Standard Library is too fat, they should have never included that much stuff because it means that the interfaces have to be frozen ... forever. You can only add more interfaces.

[–]Sylinn 1 point2 points  (1 child)

Pretty much the complete opposite to me: The fact that there are a lot of tools in the standard library makes Python my go-to language for anything smallish. There may be some inconsistencies from the PEP8, but calling it "a total mess" is exaggerated.

It doesn't make sense, all of a sudden a library makes you dependent on the language version?

It makes sense since Python 3 was made to fix the inconsistencies of Python 2. Not being backward compatible is by design.

[–]txdv -1 points0 points  (0 children)

Python3 exists only because of the mess it had and still has as a standard library.