Live data from Hacker News

Lahja – A generic event bus implementation written in Python

github.com

51–60 of 74 posts

Re: Lahja – A generic event bus implementation written in Python

#51
post #6

Love to try this out some day, a shame that this isn't in Python 2. EDIT: Thanks HN, try working in an industry where every new project is in Python 2, and have no intention to move on, before saying "moeve to 3", it doesn't help at all.

https://pythonclock.org/ - 5 Months and 2 days to go. Do not do any new projects in Python 2. There is no technical reason for you to do so. If management is an issue, show them the facts. Also, Python 3.9 is now out which means there's been more than enough time to migrate - https://docs.python.org/3.9/whatsnew/3.9.html

Seriously though, why would a company want to start a months long project of moving from python 2 to 3, when their current setup works perfectly, and the project involves the horrifying boring chore of going through every single line of code and making simple changes, and hope that their tests still works, there are no edge cases that crop up due to minor changes in the new version, etc., etc., etc. Seems much more sensible to stick with something that works.

Re: Lahja – A generic event bus implementation written in Python

#52

Earlier quoted context omitted.

AFAIK, celery doesn't provide a message passing bus between main process and sub-processes.

Don't understand that clearly. Can't I put something in the queue in the main process and read it from subprocesses ?

Is that going to provide bi-directional communication between main and subprocesses while they are running? If it does, disregard what I wrote.

Re: Lahja – A generic event bus implementation written in Python

#53
post #27

Earlier quoted context omitted.

Python 2.7 is still maintained, and the last version came out in March IIRC, so there's that. Lots of big players still use Python 2 (Google being the most prominent), and untold smaller players. Besides, Windows XP and PHP are also in use, as are 50+ year old COBOL systems, so there's that. Unless you come in and do the port yourself, many systems are not getting ported anytime soon. RedHat and co will continue to r…

Where exactly does Google use python2.7?

One thing I know of off the top of my head (because I had to deal with it last week) is the gcloud suite of tools for GCP, which will only run with 2.7. Thankfully the various GCP libraries for interacting with the platform do work on Python 3.

Re: Lahja – A generic event bus implementation written in Python

#54
post #51

Earlier quoted context omitted.

https://pythonclock.org/ - 5 Months and 2 days to go. Do not do any new projects in Python 2. There is no technical reason for you to do so. If management is an issue, show them the facts. Also, Python 3.9 is now out which means there's been more than enough time to migrate - https://docs.python.org/3.9/whatsnew/3.9.html

Seriously though, why would a company want to start a months long project of moving from python 2 to 3, when their current setup works perfectly, and the project involves the horrifying boring chore of going through every single line of code and making simple changes, and hope that their tests still works, there are no edge cases that crop up due to minor changes in the new version, etc., etc., etc. Seems much more s…

Well, because you're developing against an unsupported runtime. No bug or security updates. If that's fine for you, feel free, otherwise get with the (supported) program.

If it's a new project, there are no excuses imho

Re: Lahja – A generic event bus implementation written in Python

#55

Earlier quoted context omitted.

Don't understand that clearly. Can't I put something in the queue in the main process and read it from subprocesses ?

Is that going to provide bi-directional communication between main and subprocesses while they are running? If it does, disregard what I wrote.

Sure. You can put results in an "output" queue (which is backed by Redis) that is read by the main application.

Incidentally this is how you do a notification on your UI .

Re: Lahja – A generic event bus implementation written in Python

#58
post #51

Earlier quoted context omitted.

Seriously though, why would a company want to start a months long project of moving from python 2 to 3, when their current setup works perfectly, and the project involves the horrifying boring chore of going through every single line of code and making simple changes, and hope that their tests still works, there are no edge cases that crop up due to minor changes in the new version, etc., etc., etc. Seems much more s…

Well, because you're developing against an unsupported runtime. No bug or security updates. If that's fine for you, feel free, otherwise get with the (supported) program. If it's a new project, there are no excuses imho

In addition I don't think you'd have to interrogate every line, depending on your codebase and upstream module support for Python 3. There are tools like:

http://python-future.org/automatic_conversion.html and https://python-modernize.readthedocs.io/en/latest/

Which should get you most of the way there. Look at https://docs.python.org/3/howto/pyporting.html for more info

Re: Lahja – A generic event bus implementation written in Python

#59
post #51

Earlier quoted context omitted.

https://pythonclock.org/ - 5 Months and 2 days to go. Do not do any new projects in Python 2. There is no technical reason for you to do so. If management is an issue, show them the facts. Also, Python 3.9 is now out which means there's been more than enough time to migrate - https://docs.python.org/3.9/whatsnew/3.9.html

Seriously though, why would a company want to start a months long project of moving from python 2 to 3, when their current setup works perfectly, and the project involves the horrifying boring chore of going through every single line of code and making simple changes, and hope that their tests still works, there are no edge cases that crop up due to minor changes in the new version, etc., etc., etc. Seems much more s…

The question at this point is: why haven’t you migrated yet?

Any new code written in the last 5 years should have been Python 3 compatible (and tested).

If you’re on Python 2 you’re on a dying platform. If your code is important plan accordingly... something many have failed to do.

Post reply on HN