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

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 19,982
» Latest member: miriamwilliam
» Forum threads: 38,733
» Forum posts: 175,566

Full Statistics

Online Users
There are currently 44 online users.
» 0 Member(s) | 39 Guest(s)
Applebot, Bing, Google, AOL

Latest Threads
Parse Markdown / get the ...
Forum: General Coding Help
Last Post: Larz60+
2 hours ago
» Replies: 1
» Views: 78
Error: cannot mix str wit...
Forum: General Coding Help
Last Post: Joliekeva
11 hours ago
» Replies: 4
» Views: 2,018
Integer Factorization Too...
Forum: Code sharing
Last Post: buran
Yesterday, 07:43 AM
» Replies: 2
» Views: 426
My goal to be hired worki...
Forum: News and Discussions
Last Post: GnomeSweetGnome
Yesterday, 12:21 AM
» Replies: 2
» Views: 1,068
Unable to resolve FileNot...
Forum: General Coding Help
Last Post: noisefloor
Sep-29-2025, 05:45 PM
» Replies: 6
» Views: 1,126
Comparing 2 100GB Drives/...
Forum: General Coding Help
Last Post: snippsat
Sep-29-2025, 12:59 PM
» Replies: 8
» Views: 791
Select Python comment (#)...
Forum: General Coding Help
Last Post: tester_V
Sep-28-2025, 06:39 PM
» Replies: 7
» Views: 3,086
what does % stand for in ...
Forum: General Coding Help
Last Post: Gribouillis
Sep-27-2025, 06:49 PM
» Replies: 4
» Views: 2,532
My First App
Forum: Code Review
Last Post: carlbidwell
Sep-27-2025, 10:53 AM
» Replies: 8
» Views: 9,119
how to export a dictionar...
Forum: GUI
Last Post: noisefloor
Sep-26-2025, 05:13 PM
» Replies: 4
» Views: 1,576

 
  How to mock an object that is created during function call?
Posted by: Schlangenversteher - Jan-31-2020, 01:36 PM - Forum: General Coding Help - No Replies

Hello,

i tried to create a python test for a subprocess call. Below i created a minimalistic example.

[python]
# myModule.py
import subprocess..... More

Print this item

  connection string issue
Posted by: racone - Jan-31-2020, 12:47 PM - Forum: General Coding Help - Replies (2)

Hi I am new to programming
Have be using python and trying things out.
Now trying to connect to my mssql 2016 database

The issue is he use of the..... More

Print this item

  Can't install Phython
Posted by: Ricardo14 - Jan-31-2020, 12:01 PM - Forum: General Coding Help - Replies (1)

Hi there! How are you? Hope you're fine

I was trying to install Phython on my machine to run a script. I downloaded requests-2.22.0 and beautifulso..... More

Print this item

  Error SQLite objects created in a thread can only be used in that same thread.
Posted by: binhduonggttn - Jan-31-2020, 07:37 AM - Forum: General Coding Help - Replies (3)

My script used to migrate data from SQLite to Postgres in Python. I'm using threading module to speed up transfer tables but I got a error
[error]sqli..... More

Print this item

  Saving a mask as a png file in opencv
Posted by: DanTheMan - Jan-31-2020, 06:16 AM - Forum: General Coding Help - Replies (1)

Hi. I am trying to save as png file the mask generated by python when I run the object detection with HSV Color Space in opencv. I used cv2.imwriting ..... More

Print this item

  Windows Traffic
Posted by: rhey - Jan-31-2020, 05:36 AM - Forum: Networking - No Replies

Hi All,

I'm trying to identify if our developer successfully check Windows Network traffic. I don't know about the codes so please help me understa..... More

Print this item

  Code help please
Posted by: rhey - Jan-31-2020, 04:13 AM - Forum: General Coding Help - Replies (6)

Hello,

Please help.. I'm not a developer but I need to know if it still possible to fix this application.

The app is a bench-marking tool for te..... More

Print this item

  Doubt in Regex Lookaround
Posted by: fullstop - Jan-31-2020, 04:03 AM - Forum: General Coding Help - Replies (3)

Hi

I am trying to use lookbehind for a sample code as below

[python]
import re
txt = "love regex or hate regex, can't ignore regex"
pattern =..... More

Print this item

  T-shirts from Python Store
Posted by: gridsleep - Jan-30-2020, 10:52 PM - Forum: News and Discussions - Replies (4)

Just out of curiosity, why does it cost 33 Euro to ship two t-shirts from the Python store warehouse in Spain to New York? I hope that money is going ..... More

Print this item

  which is "better" (or more Pythonic)?
Posted by: Skaperen - Jan-30-2020, 10:22 PM - Forum: General Coding Help - Replies (7)

which is "better" (or more Pythonic)?

A.

elif a==120 or a==99:
    ...
B.
[python]
elif a in (120,99):
...
[/python..... More

Print this item

  SQLAlchemy - Program Name in SQL Workbench
Posted by: jim2007 - Jan-30-2020, 10:18 PM - Forum: General Coding Help - Replies (4)

Very new to Python, but older that I'd care to admit to programming ;-)

So I have been working with SQLAlchemy for the past few days and all has be..... More

Print this item

  Using Tkinter widgets on child window
Posted by: chewy1418 - Jan-30-2020, 09:37 PM - Forum: GUI - Replies (8)

Main/Root Window

My issue is in the TopLevel/Secondary Window. In that class, I have a ListBox which I can declare successfully and will app..... More

Print this item

  Using Python and scikitlearn, how to output the individual feature dependencies?
Posted by: warren8r - Jan-30-2020, 07:02 PM - Forum: Data Science - Replies (8)

Hello,
I am relatively new to Python and Machine Learning.
I have a basic dataset for insurance fraud and a script that generates the model and runs..... More

Print this item

  Czech IT specialists organize “hackathon” to give government online motorway vignette
Posted by: buran - Jan-30-2020, 05:57 PM - Forum: Bar - No Replies

https://www.radio.cz/en/section/curraffr...m-for-free
..... More

Print this item

  making a function that writes variables (is possible?)
Posted by: miker2808 - Jan-30-2020, 05:35 PM - Forum: General Coding Help - Replies (3)

Hello, I'm running dynamixel servos and I tried to convert few lines of code that read packet into a function to shorten the lines.
the lines were li..... More

Print this item

  Help, newbie here
Posted by: SufiyanSadiq - Jan-30-2020, 04:55 PM - Forum: General Coding Help - Replies (5)

hey i am new to python and i am having some issues with my code.[python]string = ''
length = 0
input_name = input("Enter your name: ")
length = len..... More

Print this item

  Can a table have both frequencies and percentages?
Posted by: larryb - Jan-30-2020, 04:16 PM - Forum: Data Science - Replies (2)

So my normal method for creating a table produces EITHER frequencies OR percentages.
I would really like to produce both frequencies AND percentages..... More

Print this item

  [GPX] Read all trkpt, and merge into single track?
Posted by: Winfried - Jan-30-2020, 04:08 PM - Forum: General Coding Help - No Replies

Hello,

I need to merge multiple tracks in multiple GPX files that all go in the same direction but aren't in the right order.

Before I figure ou..... More

Print this item

  Can I interpolate if I don't know the function I am dealing with?
Posted by: player1681 - Jan-30-2020, 01:15 PM - Forum: Data Science - Replies (2)

Hello everyone. I am working on the translation of some code from mathematica to python. In one line it is written ifuncEPSX = ..... More

Print this item

  Running linux command line apps...
Posted by: dbrdh - Jan-30-2020, 01:13 PM - Forum: General Coding Help - No Replies

Hi Herd,

Have done a bit of C/C++, Java, PHP, VB, Basic in the past and Python is new to me. I'm wanting to learn it as I have teamed a Raspberry Π 4..... More

Print this item

  Problem with an IF statement
Posted by: Ryan_Todd - Jan-30-2020, 10:42 AM - Forum: General Coding Help - Replies (13)

Hi Guys,

Still fairly new here, wondering why this loop is not working.. im trying to create a simple coin flip game. I know there is plenty of res..... More

Print this item

  csv file output
Posted by: rturus - Jan-30-2020, 10:16 AM - Forum: General Coding Help - Replies (7)

I have some problems:

I created a csv file

[python] with open('file.csv','a') as f:
thewriter=csv.writer(f)

thewriter.wri..... More


Attached Files

Thumbnail(s)
   
Print this item

  HELP TabError: inconsistent use of tabs and spaces in indentation
Posted by: blackjesus24 - Jan-30-2020, 09:34 AM - Forum: General Coding Help - Replies (2)

Hi there, i'm trying to print my code but it gives me this error:

[error] File "C:\Users\jay\Desktop\asd.py", line 6
print("Checking in passe..... More

Print this item

  multi login from excel list
Posted by: CIRMIND - Jan-30-2020, 09:15 AM - Forum: Web Scraping & Web Development - No Replies

I would like to access a site with 10 accounts. I would like to avoid creating 10 .py files. How can I solve this problem?
[python]import time
impor..... More

Print this item

  char == int
Posted by: Skaperen - Jan-30-2020, 08:54 AM - Forum: Bar - Replies (2)

in the language i was going to create, a single character was going to be equivalent to an int. having learned of better handling of Unicode, it coul..... More

Print this item

  How can I use concurrency to migrate database in Python?
Posted by: binhduonggttn - Jan-30-2020, 08:28 AM - Forum: General Coding Help - Replies (4)

I have a script used to migrate data from SQLite to Postgres. I just use a for loop to transfer tables one by one. Now, I want to experiment with tran..... More

Print this item

  web development with pytonik
Posted by: pytonik - Jan-30-2020, 07:10 AM - Forum: Web Scraping & Web Development - No Replies

how to develop web application using pytonik framework.. can anyone teach or work me through to use it. thank you

Print this item

  empty generator
Posted by: Skaperen - Jan-30-2020, 06:17 AM - Forum: General Coding Help - Replies (2)

coding a generator. but what if it has nothing to yield? just return? return anything in particular?

Print this item

  How to convert TransactSQL into Abstract Syntax Tree (AST) using Python?
Posted by: bajrangbs - Jan-30-2020, 04:32 AM - Forum: General Coding Help - Replies (2)

Can someone help me how I can convert a piece of T-SQL code into Abstract Syntax Tree(AST) using Python?

Print this item

  Bench marking tool
Posted by: rhey - Jan-30-2020, 01:53 AM - Forum: General Coding Help - Replies (4)

Hello,

I'm not a developer but I was here on a situation where the developer cannot fix the errors we encounter on his application. I'd like to kn..... More

Print this item

  multiple conditions
Posted by: Chandan - Jan-30-2020, 12:55 AM - Forum: General Coding Help - Replies (7)

Hi There,

I am trying to replicate one of the SAS functions in Python, not sure how to do it. It would be great if you guys can assist me with this..... More

Print this item

  Help finding example code please
Posted by: GaryKuipers - Jan-30-2020, 12:31 AM - Forum: GUI - Replies (5)

I am a python3 neophyte:

I would like to create a program that:
1) has a display (Tkinter? PyQT?) containing text fields and a button
2) can rec..... More

Print this item

  Taking a CSV output and using it for another function
Posted by: Gduffley - Jan-30-2020, 12:11 AM - Forum: General Coding Help - Replies (1)

I am looking to take the output of a CSV file and tie it into another function. All of this has to be done within the same python module. Can anyone..... More

Print this item

  uniterate
Posted by: Skaperen - Jan-29-2020, 11:27 PM - Forum: General Coding Help - Replies (1)

i have a big iteration loop like for item in myiterable: followed by a lot of indented code. in that loop body i test item for many ..... More

Print this item

  New to Python
Posted by: hcarcamo22 - Jan-29-2020, 10:53 PM - Forum: General Coding Help - Replies (2)

Hello,

I am starting on this coding experience just for fun, or mainly, because I want to learn how big data works.

Anyone can give me any advic..... More

Print this item

Forum stats
Latest posts
Topic Date, time  Author Last Sender Forum
  Parse Markdown / get the ... 2 hours ago SpongeB0B Larz60+ General Codin...
  Error: cannot mix str wit... 11 hours ago ngregistrations Joliekeva General Codin...
  Integer Factorization Too... Yesterday, 07:43 fosuwxb buran Code sharing
  My goal to be hired worki... Yesterday, 00:21 GnomeSweetGnome GnomeSweetGnome News and Disc...
  Unable to resolve FileNot... 09-29, 17:45 llarkin6 noisefloor General Codin...
  Comparing 2 100GB Drives/... 09-29, 12:59 tester_V snippsat General Codin...
  Select Python comment (#)... 09-28, 18:39 SpongeB0B tester_V General Codin...
  what does % stand for in ... 09-27, 18:49 arbiel Gribouillis General Codin...
  My First App 09-27, 10:53 BCopeland64 carlbidwell Code Review
  [Tkinter] how to export a... 09-26, 17:13 RonR noisefloor GUI
  Is the interpreter that c... 09-26, 13:17 helendamdam noisefloor General Codin...
Most views
  The best Prog... 577446
  Tutorial Requ... 500968
  Web Scraping ... 441077
  Newbie with P... 385144
  New Users Int... 369721
Most reputation
buran 581
snippsat 508
Larz60+ 452
Gribouillis 362
deanhystad 327
Most replies
  New Users Int... 451
  [book] Variou... 188
  CKEditor / Ri... 100
  moving from t... 95
  Free keys and... 91
Top posters
Larz60+ 12092
buran 8178
snippsat 7370
deanhystad 6897
metulburr 5151
Top referrers
Googlepro 23
metulburr 6
python 6
NonEntity 5
buran 3
Newest members
miriamwilliam Today
Davidkiplimo Today
Joliekeva Today
silversimon2 Yesterday
alissapena8 Yesterday

User Panel Messages

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