Python Forum
If Python 2.x source code and applies a transform it into valid Python 3.x code.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
If Python 2.x source code and applies a transform it into valid Python 3.x code.
#1
I have changed between the versions, showing how to change from Python 2-style to Python 3.1-style.

I'm getting a SyntaxError on a file that was generated by the system itself Django/config/_init_.py.
Reply
#2
Please show offending code.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Trying to install the edk2-rk3399 code but the script fails due some python bug mariozio 2 1,919 Aug-17-2025, 10:25 PM
Last Post: mariozio
  How to package code for different python environments mayukun 2 1,195 Jul-17-2025, 11:36 AM
Last Post: snippsat
  Problem Converting Tradingview Indicator to Python code kralxs 2 4,600 Jun-27-2025, 07:29 AM
Last Post: wallneradam
  Mathematica code vs Python MiloChocolatito 1 1,706 May-28-2025, 06:27 PM
Last Post: Arush
  Error on import: SyntaxError: source code string cannot contain null bytes kirkwilliams2049 10 26,950 May-26-2025, 01:55 PM
Last Post: deanhystad
  smbus.SMBus i2c code which worked to v.3.7.3 does not on Python 3.11.2 NewbyTyro 2 1,082 May-12-2025, 03:51 PM
Last Post: NewbyTyro
  python code not running Azdaghost 1 828 Apr-22-2025, 08:44 PM
Last Post: deanhystad
  Identifying Valid and Invalid Phone Contact KiranKandavalli 3 1,424 Apr-03-2025, 07:12 PM
Last Post: deanhystad
  I am getting an IndentError on my python code in VS Code and i dont know why jcardenas1980 11 13,378 Mar-22-2025, 09:49 AM
Last Post: Pedroski55
  Transform 3 Columns into Single Column DaveG 9 4,904 Mar-19-2025, 03:46 AM
Last Post: robbert23

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020