Monday, April 29, 2024
2
rated 0 times [  2] [ 0]  / answers: 1 / hits: 561  / 2 Years ago, fri, december 10, 2021, 10:04:19

since Ubuntu 12.10 ships only Python 3 by default, I wanted to ask, what steps should be taken to get my »Quickly« application ready for python 3?



I already know about 2to3, but I don't know how to start quickly's quickly run command with python 3 support or how to run my applicaton without quickly. Actually right now I use quickly merely to start my application, because I could'nt figure out how to run a quickly application without quickly run.



I appreciate every answer!


More From » application-development

 Answers
7

Port Quickly Python 2.7 to Python 3.x



I am not sure if it was there before I upgraded to Ubuntu 12.10 but now is a bin/<programname> Folder inside the quickly-template code. E.g. <programname>/bin/<programname>. It's the entry point from where the quickly app is started!



In this file it's simple to change the python version: Modifying the first line is enough, e.g. change it from



#!/usr/bin/python


to



#!/usr/bin/python3


and your quickly application is running with python 3! Of course, you'll still have to modify all the project files to work with python 3 instead of python 2.7. I went the manual route and fixed all upcoming bugs, however, tools like 2to3 could potentially aid you.



How to start a quickly application without quickly?



Well it's as simple as running python bin/<programname from your application's folder (the same python file you need to modify for python 3 compatibility).


[#34753] Saturday, December 11, 2021, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
darpose

Total Points: 424
Total Questions: 99
Total Answers: 121

Location: Jersey
Member since Fri, Oct 1, 2021
3 Years ago
;