Bug #8475

Python3 Syntax errors

Added by Matthew Poletiek 6 months ago. Updated 4 months ago.

Status:New Start date:11/25/2020
Priority:Normal Due date:
Assignee:Matthew Poletiek % Done:

0%

Category:-
Target version:chirp-py3
Chirp Version:daily Platform:All
Model affected:(All models)

Description

Looks like the current py3 branch has 2 syntax errors. The first I discovered was in chirp/ui/mainapp.py on line 1140.

print query

needs to be
print(query)

Also, in chirp/drivers/vx6.py on line 874

except Exception, e:

needs to be
except (Exception, e):

After these changes were made py3 worked as I expected it to.

py3syntax.patch (1.1 kB) Matthew Poletiek, 11/25/2020 10:34 am

py3syntax.patch (1.1 kB) Matthew Poletiek, 12/14/2020 07:59 pm


Related issues

related to Bug #8545: Python 3 Syntax Errors in Driver Files New 12/10/2020

History

Updated by Matthew Poletiek 6 months ago

Created the following patch to fix this.

Updated by Matthew Poletiek 5 months ago

Better Patch

Updated by Matthew Poletiek 5 months ago

Updated patch with better syntax.

except (Exception, e): wasn't correct.

Correct answer is except Exception as e:

Updated by Bernhard Hailer 4 months ago

Matthew, has your patch been posted to the developer's mailing list, has it been accepted? Thanks.

Updated by Matthew Poletiek 4 months ago

Bernhard Hailer wrote:

Matthew, has your patch been posted to the developer's mailing list, has it been accepted? Thanks.

I haven't seen any movement on the py3 branch since February last year. I've made multiple posts to the dev list about this branch.

I've since forked this branch and have been working on my own repo here: https://github.com/mpoletiek/py3-CHIRP

Waiting until this February to make some irreversible changes to my own repo.

Also available in: Atom PDF