py-xbrl icon indicating copy to clipboard operation
py-xbrl copied to clipboard

maximum recursion depth exceeded in __instancecheck__

Open keyboardcrimp opened this issue 1 year ago • 3 comments

Is there anyway to increase the recursion depth? I keep running into this issue, I don't mind if it takes a bit longer to process a file but I'd prefer for the action to finish rather than erroring out.

keyboardcrimp avatar Feb 28 '24 22:02 keyboardcrimp

Hey @keyboardcrimp, are you working on an XBRL Instance file you can share? Because it sounds like a bug, normally the XBRL document should not be so deep that there are any recursion depth issues.

manusimidt avatar Mar 03 '24 21:03 manusimidt

Hi @manusimidt thanks for getting back to me on this. Sure, so I'm trying to download and parse some balance sheets from companies house and having a fair number of them fail on recursion errors. If you want to replicate it there's a link here to download a zip containing a days worth of balance sheets:

https://download.companieshouse.gov.uk/Accounts_Bulk_Data-2024-02-24.zip

And here are all the ones I noted that failed on recursion:

  • Prod223_3641_06621976_20230331.html
  • Prod223_3641_09501942_20230531.html
  • Prod223_3641_07880367_20231231.html
  • Prod223_3641_08508187_20230831.html
  • Prod223_3641_07280283_20230630.html
  • Prod223_3641_13379535_20220531.html
  • Prod223_3641_11247470_20230531.html
  • Prod223_3641_11717742_20230630.html
  • Prod223_3641_12868138_20230831.html
  • Prod223_3641_08879337_20230226.html
  • Prod223_3641_10191827_20230531.html
  • Prod223_3641_11875762_20231231.html
  • Prod223_3641_SC254760_20230531.html
  • Prod223_3641_SC568075_20230630.html
  • Prod223_3641_00336234_20230930.html
  • Prod223_3641_00451065_20230531.html
  • Prod223_3641_01285001_20230831.html
  • Prod223_3641_01812016_20230930.html
  • Prod223_3641_01990954_20230528.html
  • Prod223_3641_02664682_20231231.html
  • Prod223_3641_05040510_20230930.html
  • Prod223_3641_13631774_20230930.html
  • Prod223_3641_13736358_20230331.html
  • Prod223_3641_05354013_20230831.html
  • Prod223_3641_05418038_20230831.html
  • Prod223_3641_05807304_20230531.html
  • Prod223_3641_06545400_20230930.html
  • Prod223_3641_08307376_20230531.html
  • Prod223_3641_08719309_20230331.html

keyboardcrimp avatar Mar 04 '24 09:03 keyboardcrimp

Hey @keyboardcrimp thanks for providing the filings. I will have a look into it.

manusimidt avatar Apr 04 '24 19:04 manusimidt

Fixed in #133 I tested it with Prod223_3641_11717742_20230630.html which now works without issues. Will release a new version containing this fix soon. Thanks @Sam-el0

manusimidt avatar May 15 '24 17:05 manusimidt