vlachoudis / bCNC

GRBL CNC command sender, autoleveler and g-code editor
GNU General Public License v2.0
1.54k stars 528 forks source link

Break compatibility with python 2 #1719

Open m1ch opened 2 years ago

m1ch commented 2 years ago

Python 2 is EOL for some time now. I propose to remove all code fragments that are necessary for the compatibility with python 2.

e.g:

try:
    import Tkinter
except ImportError:
    import tkinter

Also relates to #1480

bosd commented 2 years ago

It has been discussed a couple of times before. Somehwere around last year, the decision has been made to still support python2.

We are a year later now, I would also like to propose to drop the support of python2. Maybe a release can be made of the current repo, as the last python2 compatible version. In that way it will always be accessible for those who need it.

Then we can continue development and improve the code for python3.

tatarize commented 1 year ago

https://github.com/vlachoudis/bCNC/commit/6905d8ea64c5f9e6fe78a587e18558db98506bcf

After this PR support for py2 is should probably be officially dead.

I noticed that my addition to svg_elements.py now included fstrings. This means functionally they are Python 3.6+ only. I generally had a couple cases of 2/3 compat code.