Python Forum
Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 20,279
» Latest member: ndx101
» Forum threads: 38,790
» Forum posts: 175,868

Full Statistics

Online Users
There are currently 57 online users.
» 1 Member(s) | 52 Guest(s)
Bing, Google, Applebot, kshahzad1985

Latest Threads
My goal to be hired worki...
Forum: News and Discussions
Last Post: mamta25
8 hours ago
» Replies: 4
» Views: 1,453
[SOLVED] [BeautifulSoup] ...
Forum: Web Scraping & Web Development
Last Post: Winfried
Yesterday, 02:10 PM
» Replies: 2
» Views: 98
How to Implement Real-Tim...
Forum: Web Scraping & Web Development
Last Post: ankitsharma32
Yesterday, 06:48 AM
» Replies: 0
» Views: 36
How to put my game loop i...
Forum: Game Development
Last Post: SledgeNE
Yesterday, 04:59 AM
» Replies: 11
» Views: 6,010
Help with running PvZ Fus...
Forum: Game Development
Last Post: SledgeNE
Yesterday, 04:46 AM
» Replies: 2
» Views: 4,284
Graph Interpolate Difficu...
Forum: General Coding Help
Last Post: deanhystad
Nov-19-2025, 08:34 PM
» Replies: 3
» Views: 308
link variable to exc bloc...
Forum: General Coding Help
Last Post: Gribouillis
Nov-19-2025, 05:03 AM
» Replies: 1
» Views: 152
PyQt6 QWidgets and system...
Forum: GUI
Last Post: Axel_Erfurt
Nov-18-2025, 06:47 PM
» Replies: 2
» Views: 216
best way to learn python
Forum: News and Discussions
Last Post: mamta25
Nov-18-2025, 04:13 PM
» Replies: 5
» Views: 3,117
[SOLVED] Access keys and ...
Forum: General Coding Help
Last Post: Winfried
Nov-17-2025, 11:47 AM
» Replies: 4
» Views: 261

 
  UnboundLocalError: local variable 'figure_perso' referenced before assignment
Posted by: mederic39 - Jun-11-2020, 12:11 PM - Forum: General Coding Help - Replies (2)

Hello,
I'm a French user (so my English is bad), and I make a "John Conway Life's Game".
I want to make a function that place where you want ..... More

Print this item

  Practice coding through hackathon!!
Posted by: TheOutcast - Jun-11-2020, 12:03 PM - Forum: News and Discussions - No Replies

I've been trying to practice my coding skills through hackathons and found one that helps protect users info and data. Anyone interested to join? htt..... More

Print this item

  Tkinter GUI gets very slow and stuck
Posted by: Omer - Jun-11-2020, 11:28 AM - Forum: GUI - Replies (15)

Hello,
I have created a Tkinter GUI script which monitor a PLC unit's I/O's in real time.
Therefore , i created a Modbus TCP/IP communication to the..... More

Print this item

  Keep getting, OperationalError: near "%": syntax error
Posted by: fholm11 - Jun-11-2020, 09:08 AM - Forum: General Coding Help - Replies (1)

I keep getting this error and i am not sure on how to fix it. It shouldn't be a formatting/brackets thing but at this point I wouldn't be surprised. T..... More

Print this item

  miscalculation on "100*e-6"
Posted by: cools0607 - Jun-11-2020, 07:54 AM - Forum: General Coding Help - Replies (4)

I am trying to make a calculation: 100*e-6, but got wrong answer: 9.999999999999999e-05.
I also tried: [color=#C0392B]100*0.00..... More

Print this item

  Serial Port data readout
Posted by: macellan85 - Jun-11-2020, 07:48 AM - Forum: GUI - Replies (3)

Hello,

I have designed a python serial link reader using tkinter and having some problem. The system is constructed on an arduino + tkinter reader..... More

Print this item

  CGI: Error 500
Posted by: PeterLinux - Jun-11-2020, 05:27 AM - Forum: Web Scraping & Web Development - Replies (2)

Hello, I'm new to Apache/LAMPP and CGI.

I tried the example CGI script from here:
https://wiki.python.org/moin/CgiScripts

But in my browser (at http..... More

Print this item

  Is there a simplified way to achieve this
Posted by: Andrewbf - Jun-11-2020, 05:24 AM - Forum: General Coding Help - Replies (1)

Hi guys,
Wondering if there is a better way to achieve this? In an ideal world the level value would count down -1000 to -6000 over 2 seconds.
I'm a..... More

Print this item

  Deque to string in Python 3
Posted by: anthares - Jun-11-2020, 05:07 AM - Forum: General Coding Help - Replies (4)

Hi everyone,

Fairly new to Python here and dealing with some legacy code.

n Python2 I was able to do something similar to:

[python]frames = d..... More

Print this item

  Exercism not working
Posted by: pav1983 - Jun-11-2020, 03:45 AM - Forum: Bar - Replies (2)

Hello,

I'm extremely frustrated. I am trying to use Exercism because it's free and offers free mentoring. I already installed it on my computer. T..... More

Print this item

  How do you find the length of an element of a list?
Posted by: pav1983 - Jun-11-2020, 03:16 AM - Forum: Homework - Replies (13)

How do list the length of each string in a list?

Here is the question.

"[i]Create a function that takes a list of words and transforms it into a lis..... More

Print this item

  Making a login page
Posted by: card51shor - Jun-11-2020, 03:02 AM - Forum: Homework - Replies (41)

Hey guys I'm working on a log in page and I'm getting an error that it's a tuple value but I am just trying to get one value. Does anyone see the err..... More

Print this item

  Generate Test data (.csv) using Pandas
Posted by: Ashley - Jun-11-2020, 02:45 AM - Forum: Data Science - Replies (5)

I want to generate the test data in (.csv format) using Python.
Below is my script using pandas but I'm stuck at randomly generating test data for a ..... More

Print this item

  NameError: name 'print_string' is not defined
Posted by: jamie_01 - Jun-11-2020, 02:40 AM - Forum: Homework - Replies (2)

[python]
def ground_shipping_cost(weight):
if (weight <= 2): # 2 pounds or less
price = 1.50
elif (weight > 2) or (weight <= 6):
price = 3..... More

Print this item

  Help with stripping special char and spaces
Posted by: mumstead - Jun-10-2020, 09:16 PM - Forum: Homework - Replies (7)

Hi,
New to coding in my first class. Catching on but have no clue how to attack this problem I have now.
I am tasked with The user should be promp..... More

Print this item

  bulk update in elasticsearch
Posted by: pythonlearner1 - Jun-10-2020, 08:05 PM - Forum: General Coding Help - Replies (1)

I am trying to update bulk document to elasticsearch

I am able to update this one by one document

following code works

[python]
elastic_..... More

Print this item

  ValueError: invalid literal for int() with base 10:
Posted by: omega_elite - Jun-10-2020, 07:56 PM - Forum: General Coding Help - Replies (5)

Hi

I am new to python and am playing with some code that I got on an online course but am getting this error "ValueError: invalid literal for int(..... More

Print this item

  Matlab to Python -- Parallel Computing
Posted by: zistambo - Jun-10-2020, 04:45 PM - Forum: General Coding Help - Replies (1)

Hello All,

I am new to Python programming, and I can probably write a for-loop in Python, but not much else.

I would like to test the performance of..... More

Print this item

  Is this code pythonic
Posted by: Emekadavid - Jun-10-2020, 02:42 PM - Forum: Homework - Replies (2)

As a beginner, I aim to write pythonic code because that would get me motivated into doing python the pythonic way. I was doing this challenge on 2d l..... More

Print this item

  Python changed array shape without telling me
Posted by: BrendanGolledge - Jun-10-2020, 02:11 PM - Forum: Data Science - Replies (3)

I was trying to write some simple code to practice using the linear regression in sklearn. For God knows what reason, LinearRegression.fit(x,y) expec..... More

Print this item

  My code which adds fibonacci numbers to a list adds too many terms.
Posted by: STBK - Jun-10-2020, 01:58 PM - Forum: General Coding Help - Replies (7)

Hi, I am new to programming and am self-learning, using projecteuler as a source of questions. I am trying to create a program which generates the fib..... More

Print this item

  Tkinter Tic Tac Toe updated
Posted by: menator01 - Jun-10-2020, 01:49 PM - Forum: Code sharing - Replies (3)

Here is the 2nd go.
Hope you enjoy.
As always, I welcome feedback.

[python]
#! /usr/bin/env python3
'''Tkinter TIC TAC TOE'''

# Do the impor..... More

Print this item

  Appending object to array
Posted by: Busby - Jun-10-2020, 01:43 PM - Forum: General Coding Help - Replies (2)

I'm trying to append objects to an array with the following code

[python] model_array = [model 1, model 2, model 3]
json_array = []
m..... More

Print this item

  Find only the rows containing null values
Posted by: Bhavika - Jun-10-2020, 01:06 PM - Forum: General Coding Help - Replies (2)

In a given dataset, I want to print the rows which have null value but with their actual values and not any bool values.
For example, if the dataset ..... More

Print this item

  Package delivery app, what is the best database to use
Posted by: Mainer - Jun-10-2020, 11:49 AM - Forum: News and Discussions - Replies (1)

In dire need of an app to manage 200+ packages on a 600+ box postal route
Need a local file dB to enter 600 box #’s of the route along with road name..... More

Print this item

  tkinter tic tac toe
Posted by: menator01 - Jun-10-2020, 10:44 AM - Forum: News and Discussions - Replies (8)

Just wanted to share the updated graphics view that I'm working on for the simple tic tac toe game I did.
What it looks like on my ubuntu. Since tkin..... More

Print this item

  Matplotlib figsize and centering issue on canvas
Posted by: deffonotsean - Jun-10-2020, 10:31 AM - Forum: GUI - No Replies

I'm trying to center a Matplotlib chart in a GUI using Tkinter. The issue is I can't seem to center the figure in the center of the canvas (as you can..... More

Print this item

  square root of 5 input numbers
Posted by: mrityunjoy - Jun-10-2020, 10:15 AM - Forum: General Coding Help - Replies (1)

Hi,

I have written the below piece of code, but output is showing list every time based on number of input. My expectation is to publish final list..... More

Print this item

  using python with QGIS to disseminate CSV data on a polygon
Posted by: wissam1974 - Jun-10-2020, 10:13 AM - Forum: General Coding Help - No Replies

Hi all,
i am a newbie programmer on QGIS with python.

i am working on QGIS version 3.12.3-București having a python interface prompt to write pyth..... More

Print this item

  PUT http query return <Response [500]>
Posted by: rndoma - Jun-10-2020, 09:41 AM - Forum: Web Scraping & Web Development - Replies (7)

I need to send a Json from a file to a server. The server doesn't allow to send bulk Json, juste one by one. I put my json in a file and I have to sen..... More

Print this item

  StopIteration exception when mock PostgreSQL connection in several tests
Posted by: igor87z - Jun-10-2020, 07:21 AM - Forum: General Coding Help - Replies (1)

Hi
I mock connect to Postgresql(psycopg2) in two tests

[python]from unittest.mock import patch, MagicMock

with patch('psycopg2.pool.ThreadedCon..... More

Print this item

  [Socket] Can a server be accessible from devices not in the same network?
Posted by: SheeppOSU - Jun-10-2020, 05:53 AM - Forum: Networking - Replies (2)

I assume that it has to do with the port and host of the Socket server, and if so, then what host and port can I choose so that devices not just in a ..... More

Print this item

  regular expression
Posted by: pramod - Jun-10-2020, 03:36 AM - Forum: Data Science - Replies (6)

HI i have question on regular expression
i am trying to match the text using re.search

example: [b]original text = '[SYS_1] system application [EN..... More

Print this item

  Pip question
Posted by: millpond - Jun-10-2020, 01:44 AM - Forum: Homework - Replies (1)

Not homework but n00b enough for it to be.

Working with Debian Buster, loaded with system python and Pypi packages. Slowly updating it via Pypi as ..... More

Print this item

  Error When Writing to SQL Table
Posted by: skaailet - Jun-09-2020, 11:13 PM - Forum: General Coding Help - Replies (1)

Im getting an error "the machine refuses it" when running my script to write to a table
[python]
from pylogix import PLC
import sys
sys.path.appen..... More

Print this item

Forum stats
Latest posts
Topic Date, time  Author Last Sender Forum
  My goal to be hired worki... 8 hours ago GnomeSweetGnome mamta25 News and Disc...
  [SOLVED] [BeautifulSoup] ... Yesterday, 14:10 Winfried Winfried Web Scraping ...
  How to Implement Real-Tim... Yesterday, 06:48 ankitsharma32 ankitsharma32 Web Scraping ...
  How to put my game loop i... Yesterday, 04:59 temlotresid6 SledgeNE Game Developm...
  Help with running PvZ Fus... Yesterday, 04:46 Barber532 SledgeNE Game Developm...
  Graph Interpolate Difficu... 11-19, 20:34 Tuurbo46 deanhystad General Codin...
  link variable to exc bloc... 11-19, 05:03 Astrobert Gribouillis General Codin...
  PyQt6 QWidgets and system... 11-18, 18:47 stevecoh1 Axel_Erfurt GUI
  best way to learn python 11-18, 16:13 dutch mamta25 News and Disc...
  [SOLVED] Access keys and ... 11-17, 11:47 Winfried Winfried General Codin...
  PermissionError: [Errno 1... 11-17, 08:44 Tuurbo46 Tuurbo46 GUI
Most views
  The best Prog... 579194
  Tutorial Requ... 511941
  Web Scraping ... 442144
  Newbie with P... 386225
  New Users Int... 379169
Most reputation
buran 581
snippsat 511
Larz60+ 452
Gribouillis 362
deanhystad 328
Most replies
  New Users Int... 452
  [book] Variou... 188
  CKEditor / Ri... 100
  moving from t... 95
  Free keys and... 91
Top posters
Larz60+ 12109
buran 8196
snippsat 7389
deanhystad 6915
metulburr 5151
Top referrers
Googlepro 23
python 6
metulburr 6
NonEntity 5
buran 3
Newest members
ndx101 Today
OtiliaBecker Today
NAGASOWMYAGUNDU Yesterday
shipa1autotransport Yesterday
eastnoob 11-19

User Panel Messages

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