0
votes
0answers
8 views

py2exe with different parts of apps

Let's say I have 5 different python files: main.py, first.py, second.py, third.py, last.py Each of the files, after main.py, does something different through a button on main.py's screen. I know how ...
1
vote
1answer
22 views

Implement Python 3's round function in Python 2.7

I am using some old codes written in Python 3 in my Google-App-Engine project which is using Python 2.7. The different round() algorithms in Python 3 and Python 2 gives me a headache. Is there any ...
0
votes
1answer
12 views

UnicodeDecodeError: 'utf8' codec can't decode byte - Euro Symbol

I build a connection to the Google Finance API which gives me stock quotes. Everything is working fine until I switch to courses from Europe. These contain the € Symbol and I get following error: ...
0
votes
1answer
10 views

multiple download folders using Selenium Webdriver?

I'm using the Selenium webdriver (in Python) to automate the donwloading of thousands of files. I want the files to be saved in different folders. The following code works, but it requires quitting ...
0
votes
1answer
8 views

Does Tornado close connection at the end of request?

When I am working with Tornado and on the end of get/post request I have return statement or I don't have anu return at all ( no even self.write ) does it close connections ? (when I type into command ...
0
votes
1answer
20 views

ffmpeg cannot detect file while os can

Issue I'm trying to load images in a sub-directory with files named: .\images\image0.png .\images\image1.png .\images\image2.png .\images\image3.png ... etc ... .\images\image8.png ...
0
votes
1answer
42 views

Files in python are empty for no reason

I have tried to split up my world generation from my actual game, since I usually fail with it. But for some reason it keeps insisting the file is empty/ the variable gained from it is empty, and ...
1
vote
3answers
28 views

Labels Aren't Changing

I'm only going to post a snippet of my code, because essentially, it does the same thing. string = '' time_calc = Tk() time_calc.geometry('500x400') time_calc.title("Calculate A Time") ...
0
votes
6answers
51 views

Python execute code only if for loop did not begin iteration (with generator)?

The else block in a for/else clause gets executed if the iteration finishes but is not interrupted by break, so I read. Is there a language construct which would let me write something which executes ...
0
votes
0answers
19 views

Why am I getting this openopt index error?

First, the error: Traceback (most recent call last): File "tsp_solver.py", line 57, in <module> solvetTSP(inputData) NameError: name 'solvetTSP' is not defined new-host:tsp Jonathan$ ...
0
votes
1answer
55 views

A* pathfinding on 2D grid doesn't find optimal path

I am trying to implement the A* algorithm on a 2D square grid. However, it almost never finds an optimal path, and I just can't see why. The code is also suspiciously slow, even for python. I've ...
0
votes
2answers
29 views

Import statement doesn't work as expected with Python 3.3

I recently ported a django application from Python 2.7 to Python 3.3 with Django1.6b1. My import statements wouldn't work anymore for custom module imports (User, views...) and I had to add a dot ...
0
votes
0answers
15 views

How to connect to access (.mdb) database with pyodbc using latin-1 filename

I use this code to connect to my access (.mdb) database: # -*- coding: latin-1 -*- fileMDB = 'C:\\Python27\\OptimisateurLievre\\final\\Archives_PrevisionsESP_Août_2013.mdb' param = "Driver={Microsoft ...
-4
votes
1answer
41 views

maintaining order in json (python flask) [duplicate]

I made a sorted dictionary to pass through json to a javascript, however, it seems whenever I throw it into a json.dumps() it changes its order into alphabetical by keys. It is critical that I keep it ...
0
votes
1answer
26 views

Python reading unicode forlder and file names

I am new to Python. I am trying to input one path and use os.walk() to search all files, and want to return files' names and use os.path.getsize() to get file size, and then write them into csv file. ...

1 2 3 4 5 409
15 30 50 per page