Python Forum
Unrelated new function causing existing working function to fail
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Unrelated new function causing existing working function to fail
#3
Ok, I've narrowed it down a little.

Firstly, passing through items rather than item was a typo when writing the forum post. The code itself does use item.
The brackets around the return statement were a bad coding habit of mine. They've now been removed.

Update.... I'm clinically dumb. I removed the error handling as you suggested, and got back

'function' object is not subscriptable
Worked back through and had a look at it, and I'd given FunctionB an identical name to a variable in FunctionA, hence the (in hindsight rather obvious) error. A quick fix thankfully!
Reply


Messages In This Thread
RE: Unrelated new function causing existing working function to fail - by Nick_G - Jan-27-2020, 07:21 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Excel isnt working properly after python function is started IchNar 0 54 4 hours ago
Last Post: IchNar
  The function of double underscore back and front in a class function name? Pedroski55 9 724 Feb-19-2024, 03:51 PM
Last Post: deanhystad
  Why does [root.destroy, exit()]) fail after pyinstaller? Rpi Edward_ 4 642 Oct-18-2023, 11:09 PM
Last Post: Edward_
Shocked kindly support with this dropna function not working gheevarpaulosejobs 2 692 Jul-24-2023, 03:41 PM
Last Post: deanhystad
  why does VS want to install seemingly unrelated products? db042190 3 666 Jun-12-2023, 02:47 PM
Last Post: deanhystad
  How to calculated how many fail in each site(s) in csv files SamLiu 4 1,321 Sep-26-2022, 06:28 AM
Last Post: SamLiu
Exclamation Function Not Working Alivegamer 7 1,894 Jul-19-2022, 01:03 PM
Last Post: deanhystad
  Imports that work with Python 3.8 fail with 3.9 and 3.10 4slam 1 2,612 Mar-11-2022, 01:50 PM
Last Post: snippsat
  try function working on PC but not raspberry pi AnotherSam 1 1,550 Oct-11-2021, 04:51 AM
Last Post: bowlofred
  Exit function from nested function based on user input Turtle 5 2,940 Oct-10-2021, 12:55 AM
Last Post: Turtle

Forum Jump:

User Panel Messages

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