Questions tagged as 'python'

1
answer

Error with app Flask Babel Python3 (Windows)

I'm following the article's tutorial link I came in part III and gave this error. I'm confused because the author has run run.py inside the Script folder of virtualenv. Being that it commands to create run.py in the root...
asked by 29.08.2015 / 02:22
1
answer

Doubt to transpose part of a table with Python

I need help to build a Python script that transposes part of a csv as in the example below: [[0A,0B,0C,0D,0E,0F] [01,02,03,04,05,06] [07,08,09,10,11,12] [13,14,15,16,17,18] [19,20,21,22,23,24]] in this: [[0A,0B,0C] [01,02,03] [01,02,04] [...
asked by 30.06.2015 / 18:30
2
answers

Modules in Python linux

I'm having some problems installing modules in my python on linux. I am currently using python 2.7.10, most of the modules I use the pip to install, however when I run python 2.7.10 and import my module it says it has not found, however if I use...
asked by 23.06.2015 / 22:06
2
answers

How to use Kivy with Python 3.4.3 on Mac

How can I use Kivy with Python 3.4.3 on OS X? Only works with Python 2.7     
asked by 31.05.2015 / 01:00
1
answer

Doubt: how to fix the UnicodeEncodeError in Python?

Since I changed the machine, I have the following problem with the Python interpreter: UnicodeEncodeError: 'ascii' codec can't encode character u'\xe7' in position 17: ordinal not in range(128) All strings you send and receive are transfo...
asked by 09.06.2015 / 15:02
1
answer

PSYCOPG2 - Paging

In the search for paging using psycopg2 I discovered the attributes cursor.itersize and cursor.arraysize , and the methods cursor.fetchmany () and cursor.scroll () I wanted to check with the staff here if my understanding is correct ab...
asked by 03.02.2016 / 21:51
1
answer

Problem handling text files with python

I'm trying to make a game of gallows, and for that, I'm picking up lists of words and putting them in .txt format for Python to use in the game. When picking up a list of names of people, there are some that come with parentheses after the n...
asked by 01.05.2015 / 17:47
1
answer

How to simulate a form action = POST with urllib2

I want to create a program that reads my college notes and displays on the screen, so I'm using urllib2 to receive the web page where my notes are presented and to receive I need to log in. code in which I'm trying to simulate the submit form...
asked by 14.04.2015 / 17:16
1
answer

ImportError Python Reportlab

Hello, I'm trying to import the following lib into my Python 2.7 project: from reportlab.lib.rparsexml import simpleparse Error:    ImportError: No module named reportlab.lib.rparsexml I have tried to install python-reportlab...
asked by 05.03.2015 / 20:24
1
answer

Entering data in mysql, commit () does not work

I wanted to insert into the Database definitely. But with this code I am not succeeding, the registry is saved but does not commit() : import MySQLdb def conn(): try: db = MySQLdb.connect(host="127.0.0.1",user="root",passwd="",db=...
asked by 04.03.2015 / 11:33