Questions tagged as 'python-3.x'

1
answer

Error installing Ubuntu Ubuntu 16.04 "dpkg: error processing archive /var/cache/apt/archives/apport_2.20.1-0ubuntu2.15_all.deb"

I have an application made in Django that is now in production mode in ubuntu server 16.04 and I need to generate its SSL Certificate so that users can access through HTTPS, for this I have guided myself with this tutorial: link After...
asked by 04.01.2018 / 02:01
1
answer

Infinite loop in Python

I am currently working on a project where I need to loop an infinite loop to a python code so that the data I'm asking for from a .json database is updated every so often. p> The code is as follows: from RPLCD import CharLCD import json...
asked by 21.03.2018 / 00:27
1
answer

python - re-dimension element with a random number

I want to re-dimension the frame that I create, the idea is to take a random number to pass it as value height() , this must be done in a certain cycle in this case 100 times with a value update time each second time.sleep(1) , this...
asked by 18.03.2018 / 05:26
1
answer

Print a column of a csv

I have a csv file several columns. I simplify it in the following case with two. ID texto 1 Los niños comen sardinas 2 Los pájaros vuelan alto porque tienen alas 3 Érase una vez la vida 4 Un 67% de los adultos vive en l...
asked by 03.11.2017 / 17:53
1
answer

Use stylesheet in a qtablewidget to send properties of a cell

I'm trying to change the color of the text and background of an item in a qtablewidget with this code: tabla.item(0,0).setStyleSheet("QTableWidget::item {border: 1px solid red;}") Where table refers to a QTableWidget. However, it does no...
asked by 13.09.2018 / 07:34
2
answers

Iterate list and return PYTHON index

Good, as an example in a list with a cycle for example. And the for variable will return the index of the list in that iteration instead of the element. An example here goes. array_1=["1","2","3"] for i in array_1: print(i) I know that...
asked by 30.06.2017 / 03:36
1
answer

Utility of "" .join ()

I would like to know the usefulness and functionality of this method (actually I do not know if it is a method) ".".join . I have seen it in several examples and forums but its concept has not yet become clear to me. If you could give me a...
asked by 24.09.2017 / 19:41
2
answers

data entry with (input) in 3x python

I have this class code that runs without any problem, I want to do the data entry using input function and then visualize it with print or return , but I could not do it, it is unconfigured when I try. I would appreciate g...
asked by 26.05.2017 / 18:16
1
answer

Search within a pdf with Python

I read an encrypted Pdf and when looking for the list below it tells me that it does not find anything, it seems to me that my regular expression is wrong import PyPDF2 import re file = open('imagen.pdf', 'rb') pdfreader = PyPDF2.PdfFileReade...
asked by 30.05.2017 / 18:51
1
answer

Use input () within a for cycle (Python)

I am trying to create a matrix in which the user enters the number of rows, columns and each term: colum=int(input('Cantidad de columnas: ')) fil=int(input('Cantidad de filas: ')) matriz=[[str(input('[',i,',',j,']-esimo termino: ')) for i in r...
asked by 30.03.2017 / 16:15