I just found kivy config.ini file and set log_enable = 0 no difference
On Thu, Feb 16, 2023 at 9:31 AM Glen Rubin <[email protected]> wrote: > Steve, > Thanks for responding! Prior to encountering this issue, I was not > initializing any logging. I am trying now to explicitly turn off kivy > logging in my main.py file but am still coming up against the same > problem. Here is what I just added to my main.py: > > from kivy.logger import Logger > from kivy.config import Config > Config.set('kivy', 'log_enable', False) > Config.set('graphics','width','360') > Config.set('graphics','height','760') > import os > os.environ["KIVY_NO_CONSOLELOG"] = "1" > os.environ["KIVY_NO_FILELOG"] = "1" > > > > On Thu, Feb 16, 2023 at 8:58 AM Steve Barnes <[email protected]> > wrote: > >> I have come across similar before. You probably have logger set to write >> to stdout &/or stderr, however, in the compiled application stdout, stderr >> = None, None hence the errors. The trick that I used was to check if they >> are currently None and if so either don’t initialise the logger or make >> sure that all logging is sent to a file. >> >> >> >> Hope that helps. >> >> >> >> Steve >> >> >> >> *From:* [email protected] <[email protected]> *On >> Behalf Of *Glen Rubin >> *Sent:* 16 February 2023 14:54 >> *To:* PyInstaller <[email protected]> >> *Subject:* [PyInstaller] application fails in no-console mode >> >> >> >> My 'compiled' application fails, but only on Windows when setting console >> option to False. >> >> At fail i get the error: >> >> >> >> Failed to execute script 'main' due to unhandled exception: maximum >> recursion depth exceeded >> >> >> >> with a very long traceback that looks like this: >> >> >> >> Traceback (most recent call last): >> File "logging\__init__.py", line 1103, in emit >> AttributeError: 'NoneType' object has no attribute 'write' >> >> During handling of the above exception, another exception occurred: >> >> Traceback (most recent call last): >> File "logging\__init__.py", line 1103, in emit >> AttributeError: 'NoneType' object has no attribute 'write' >> >> During handling of the above exception, another exception occurred: >> >> Traceback (most recent call last): >> File "logging\__init__.py", line 1103, in emit >> AttributeError: 'NoneType' object has no attribute 'write' >> >> During handling of the above exception, another exception occurred: >> >> Traceback (most recent call last): >> File "logging\__init__.py", line 1103, in emit >> AttributeError: 'NoneType' object has no attribute 'write' >> >> >> >> This repeats a few thousand times and then prints: >> >> >> Traceback (most recent call last): >> File "logging\__init__.py", line 1103, in emit >> AttributeError: 'NoneType' object has no attribute 'write' >> >> During handling of the above exception, another exception occurred: >> >> Traceback (most recent call last): >> File "kivy\logger.py", line 248, in emit >> File "kivy\logger.py", line 222, in _configure >> File "logging\__init__.py", line 1477, in info >> File "logging\__init__.py", line 1624, in _log >> File "logging\__init__.py", line 1634, in handle >> File "logging\__init__.py", line 1696, in callHandlers >> File "logging\__init__.py", line 968, in handle >> File "logging\__init__.py", line 1108, in emit >> File "logging\__init__.py", line 1021, in handleError >> File "kivy\logger.py", line 338, in write >> File "logging\__init__.py", line 1489, in warning >> File "logging\__init__.py", line 1624, in _log >> File "logging\__init__.py", line 1634, in handle >> File "logging\__init__.py", line 1696, in callHandlers >> File "logging\__init__.py", line 968, in handle >> File "logging\__init__.py", line 1108, in emit >> File "logging\__init__.py", line 1021, in handleError >> File "kivy\logger.py", line 338, in write >> File "logging\__init__.py", line 1489, in warning >> File "logging\__init__.py", line 1624, in _log >> File "logging\__init__.py", line 1634, in handle >> File "logging\__init__.py", line 1696, in callHandlers >> File "logging\__init__.py", line 968, in handle >> File "logging\__init__.py", line 1108, in emit >> File "logging\__init__.py", line 1021, in handleError >> File "kivy\logger.py", line 338, in write >> File "logging\__init__.py", line 1489, in warning >> File "logging\__init__.py", line 1624, in _log >> File "logging\__init__.py", line 1634, in handle >> File "logging\__init__.py", line 1696, in callHandlers >> File "logging\__init__.py", line 968, in handle >> File "logging\__init__.py", line 1108, in emit >> File "logging\__init__.py", line 1021, in handleError >> File "kivy\logger.py", line 338, in write >> File "logging\__init__.py", line 1489, in warning ... >> >> >> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "PyInstaller" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/pyinstaller/dfcf25c5-9da5-4802-88e4-fc72a2d8586en%40googlegroups.com >> <https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgroups.google.com%2Fd%2Fmsgid%2Fpyinstaller%2Fdfcf25c5-9da5-4802-88e4-fc72a2d8586en%2540googlegroups.com%3Futm_medium%3Demail%26utm_source%3Dfooter&data=05%7C01%7C%7C10f7ef70440d45ddb2d408db10316935%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638121576622707997%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=OBeKX8R97eBvE2eFr9KUrv%2FzR43iRVuXWsG5kg8ofao%3D&reserved=0> >> . >> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "PyInstaller" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/pyinstaller/-LpzPG4S8L0/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/pyinstaller/DU0P194MB18197302A991A9553CC82EB69BA09%40DU0P194MB1819.EURP194.PROD.OUTLOOK.COM >> <https://groups.google.com/d/msgid/pyinstaller/DU0P194MB18197302A991A9553CC82EB69BA09%40DU0P194MB1819.EURP194.PROD.OUTLOOK.COM?utm_medium=email&utm_source=footer> >> . >> > -- You received this message because you are subscribed to the Google Groups "PyInstaller" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pyinstaller/CABw5z-AeZU9o_a1iXmPEs_qnz%3DgvAycZO1W_FF-d43foShsGHQ%40mail.gmail.com.
