-
Notifications
You must be signed in to change notification settings - Fork 709
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
call stack is not deep enough (Cython) #88
Comments
Hi @djsakisd. This is not related to the recursion limit, but to You may play with the logger.opt(depth=-1).info("Working?") On my side, I will try to reproduce the error, I actually never tested Cython, so I'm not too surprised there is some incompatibilities dealing with stack frames. |
Hi @Delgan it works that way ! Is there any way to make this permanent in the script for all the logger.info or i need to set this each time ? Because i tried this : Gives error, but : Thanks again for helping me... |
@djsakisd As I will investigate this issue, hopefully you will not even need this workaround in the next version. 👍 |
After playing a little with Cython, I realize this is not as easy to fix as I would thought. Cython does not insert any kind of strack frame in its compiled code. As Loguru (and logging more generally) heavily relies on frames objects, this produces weird and inherently wrong results. While compiling with Unfortunately, there is not much I can do about this. I don't like wrapping For now, the proposed solution is for Cython users to add I will label this issue as "wontfix" but I leave it open in case Cython implements some kind of workaround in the future. |
I met this issue recently. I'm trying to migrate our logging code to use It was not very clear at first place, we have some other C library cowork together, and the issue was happening when C library calling back our Python callback. I thought it was something wrong with the C library we are using so it didn't call at all. Extracting out a small piece of code and running through whole build flow made the error obvious. I'm not quite sure what's the best way to solve this issue. But I think we can at least adding some info to readme for now, like a FAQ or known issue section. |
Hey @wdv4758h. It maybe lacks visibility, but there is a link at the end of the Readme leading to a Resources page. There, one can find a paragraph concerning interoperability with Cython. I prefer not to add such section directly to the Readme to keep it short and readable. Maybe could I rename the "Resources" link to something like "FAQ & Troubleshooting", to make it more explicit? |
@Delgan oh, my bad, thanks for pointing out Yes, renaming it sounds good. I probably thought that's related talk videos or blog posts. I should have looked those pages, my bad. |
@wdv4758h Yeah, no problem, it's just a proof that I need to improve the visibility of these pages. ;) |
This one caught me with the following pattern: import atexit
from loguru import logger
logger.info('Hi!')
atexit.register(logger.info, 'Bye!')
logger.info('Doing stuff...') 2022-07-06 11:50:55.989 | INFO | __main__:<module>:6 - Hi!
2022-07-06 11:50:55.989 | INFO | __main__:<module>:8 - Doing stuff...
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/home/hannes/work/repos/loguru/loguru/_logger.py", line 1974, in info
__self._log("INFO", None, False, __self._options, __message, args, kwargs)
File "/home/hannes/work/repos/loguru/loguru/_logger.py", line 1852, in _log
frame = get_frame(depth + 2)
ValueError: call stack is not deep enough
|
@astromancer Thanks for the report, I moved this to a new ticker: #680 |
Is there any progress? More info of the error :
|
@kouyalong Are you using Cython? If yes, there is unfortunately no possible solution that I know of. |
Hi, I'm using Cython and loguru works but I can't manage (disable) logging: from loguru import logger
logger.disable(<module_name>) the above code works for source distribution and doesn't work with the binary (Cythonized) distribution. Compiled with Has anyone experienced this behavior? |
@senysenyseny16 Sorry for the late reply. I answered you on the ticket you opened: #875 (comment) |
This comment was marked as off-topic.
This comment was marked as off-topic.
Finally fixed after all these years. See #1240. The Instead of raising a |
Bumps [loguru](https://github.com/Delgan/loguru) from 0.7.2 to 0.7.3. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/Delgan/loguru/releases">loguru's releases</a>.</em></p> <blockquote> <h2>0.7.3</h2> <ul> <li>Fix Cython incompatibility caused by the absence of underlying stack frames, which resulted in a <code>ValueError</code> during logging (<a href="https://redirect.github.com/Delgan/loguru/issues/88">#88</a>).</li> <li>Fix possible <code>RuntimeError</code> when removing all handlers with <code>logger.remove()</code> due to thread-safety issue (<a href="https://redirect.github.com/Delgan/loguru/issues/1183">#1183</a>, thanks <a href="https://github.com/jeremyk"><code>@jeremyk</code></a>).</li> <li>Fix <code>diagnose=True</code> option of exception formatting not working as expected with Python 3.13 (<a href="https://redirect.github.com/Delgan/loguru/issues/1235">#1235</a>, thanks <a href="https://github.com/etianen"><code>@etianen</code></a>).</li> <li>Fix non-standard level names not fully compatible with <code>logging.Formatter()</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/1231">#1231</a>, thanks <a href="https://github.com/yechielb2000"><code>@yechielb2000</code></a>).</li> <li>Fix inability to display a literal <code>"\"</code> immediately before color markups (<a href="https://redirect.github.com/Delgan/loguru/issues/988">#988</a>).</li> <li>Fix possible infinite recursion when an exception is raised from a <code>__repr__</code> method decorated with <code>logger.catch()</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/1044">#1044</a>).</li> <li>Improve performance of <code>datetime</code> formatting while logging messages (<a href="https://redirect.github.com/Delgan/loguru/issues/1201">#1201</a>, thanks <a href="https://github.com/trim21"><code>@trim21</code></a>).</li> <li>Reduce startup time in the presence of installed but unused <code>IPython</code> third-party library (<a href="https://redirect.github.com/Delgan/loguru/issues/1001">#1001</a>, thanks <a href="https://github.com/zakstucke"><code>@zakstucke</code></a>).</li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/Delgan/loguru/blob/master/CHANGELOG.rst">loguru's changelog</a>.</em></p> <blockquote> <h1><code>0.7.3</code>_ (2024-12-06)</h1> <ul> <li>Fix Cython incompatibility caused by the absence of underlying stack frames, which resulted in a <code>ValueError</code> during logging (<code>[#88](Delgan/loguru#88) <https://github.com/Delgan/loguru/issues/88></code>_).</li> <li>Fix possible <code>RuntimeError</code> when removing all handlers with <code>logger.remove()</code> due to thread-safety issue (<code>[#1183](Delgan/loguru#1183) <https://github.com/Delgan/loguru/issues/1183></code><em>, thanks <code>@jeremyk <https://github.com/jeremyk></code></em>).</li> <li>Fix <code>diagnose=True</code> option of exception formatting not working as expected with Python 3.13 (<code>[#1235](Delgan/loguru#1235) <https://github.com/Delgan/loguru/issues/1235></code><em>, thanks <code>@etianen <https://github.com/etianen></code></em>).</li> <li>Fix non-standard level names not fully compatible with <code>logging.Formatter()</code> (<code>[#1231](Delgan/loguru#1231) <https://github.com/Delgan/loguru/issues/1231></code><em>, thanks <code>@yechielb2000 <https://github.com/yechielb2000></code></em>).</li> <li>Fix inability to display a literal <code>"\"</code> immediately before color markups (<code>[#988](Delgan/loguru#988) <https://github.com/Delgan/loguru/issues/988></code>_).</li> <li>Fix possible infinite recursion when an exception is raised from a <code>__repr__</code> method decorated with <code>logger.catch()</code> (<code>[#1044](Delgan/loguru#1044) <https://github.com/Delgan/loguru/issues/1044></code>_).</li> <li>Improve performance of <code>datetime</code> formatting while logging messages (<code>[#1201](Delgan/loguru#1201) <https://github.com/Delgan/loguru/issues/1201></code><em>, thanks <code>@trim21 <https://github.com/trim21></code></em>).</li> <li>Reduce startup time in the presence of installed but unused <code>IPython</code> third-party library (<code>[#1001](Delgan/loguru#1001) <https://github.com/Delgan/loguru/issues/1001></code><em>, thanks <code>@zakstucke <https://github.com/zakstucke></code></em>).</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/Delgan/loguru/commit/ae3bfd1b85b6b4a3db535f69b975687c79498be4"><code>ae3bfd1</code></a> Bump version to 0.7.3</li> <li><a href="https://github.com/Delgan/loguru/commit/ccca3566cc00c22eed8659705e45386fa2101b5d"><code>ccca356</code></a> Replace "notifiers" (seems unmaintained) with "apprise" in docs (<a href="https://redirect.github.com/Delgan/loguru/issues/1251">#1251</a>)</li> <li><a href="https://github.com/Delgan/loguru/commit/a372814bf79d47628e66ca9a91072f53fba032f8"><code>a372814</code></a> Configure "trusted publishing" in Github workflow</li> <li><a href="https://github.com/Delgan/loguru/commit/633016db07e5dff63bc05dd3c4d5aa81b6190700"><code>633016d</code></a> Use tox to define the "release" command</li> <li><a href="https://github.com/Delgan/loguru/commit/ef12cbbaf54fb2e64ca66b0a90675cdf9e8a522f"><code>ef12cbb</code></a> Convert README from RST to MD (fix PyPI packaging)</li> <li><a href="https://github.com/Delgan/loguru/commit/cb3314a5af107ad175a9bafa11b1b79670e3067a"><code>cb3314a</code></a> Add Github action to verify packaging</li> <li><a href="https://github.com/Delgan/loguru/commit/6161a13b79e1a3a29e922926b44f26edbcc3c06a"><code>6161a13</code></a> Complete the "Troubleshooting" docs with more examples</li> <li><a href="https://github.com/Delgan/loguru/commit/7f5001fe46393627ced287bba2c4064442c3fd25"><code>7f5001f</code></a> Simplify the example of dynamic handler level</li> <li><a href="https://github.com/Delgan/loguru/commit/2e0cd7bb5105461057c56aefb225da569882ad29"><code>2e0cd7b</code></a> Move "Introduction to logging" docs to a new section</li> <li><a href="https://github.com/Delgan/loguru/commit/72b93d1a24d1491ce7ba752fe36c14f9570a5d63"><code>72b93d1</code></a> Correct outdated instructions for reporting a vulnerability</li> <li>Additional commits viewable in <a href="https://github.com/Delgan/loguru/compare/0.7.2...0.7.3">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=loguru&package-manager=pip&previous-version=0.7.2&new-version=0.7.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details>
[//]: # (dependabot-start)⚠️ **Dependabot is rebasing this PR**⚠️ Rebasing might not happen immediately, so don't worry if this takes some time. Note: if you make any changes to this PR yourself, they will take precedence over the rebase. --- [//]: # (dependabot-end) Bumps [loguru](https://github.com/Delgan/loguru) from 0.6.0 to 0.7.3. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/Delgan/loguru/releases">loguru's releases</a>.</em></p> <blockquote> <h2>0.7.3</h2> <ul> <li>Fix Cython incompatibility caused by the absence of underlying stack frames, which resulted in a <code>ValueError</code> during logging (<a href="https://redirect.github.com/Delgan/loguru/issues/88">#88</a>).</li> <li>Fix possible <code>RuntimeError</code> when removing all handlers with <code>logger.remove()</code> due to thread-safety issue (<a href="https://redirect.github.com/Delgan/loguru/issues/1183">#1183</a>, thanks <a href="https://github.com/jeremyk"><code>@jeremyk</code></a>).</li> <li>Fix <code>diagnose=True</code> option of exception formatting not working as expected with Python 3.13 (<a href="https://redirect.github.com/Delgan/loguru/issues/1235">#1235</a>, thanks <a href="https://github.com/etianen"><code>@etianen</code></a>).</li> <li>Fix non-standard level names not fully compatible with <code>logging.Formatter()</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/1231">#1231</a>, thanks <a href="https://github.com/yechielb2000"><code>@yechielb2000</code></a>).</li> <li>Fix inability to display a literal <code>"\"</code> immediately before color markups (<a href="https://redirect.github.com/Delgan/loguru/issues/988">#988</a>).</li> <li>Fix possible infinite recursion when an exception is raised from a <code>__repr__</code> method decorated with <code>logger.catch()</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/1044">#1044</a>).</li> <li>Improve performance of <code>datetime</code> formatting while logging messages (<a href="https://redirect.github.com/Delgan/loguru/issues/1201">#1201</a>, thanks <a href="https://github.com/trim21"><code>@trim21</code></a>).</li> <li>Reduce startup time in the presence of installed but unused <code>IPython</code> third-party library (<a href="https://redirect.github.com/Delgan/loguru/issues/1001">#1001</a>, thanks <a href="https://github.com/zakstucke"><code>@zakstucke</code></a>).</li> </ul> <h2>0.7.2</h2> <ul> <li>Add support for formatting of <code>ExceptionGroup</code> errors (<a href="https://redirect.github.com/Delgan/loguru/issues/805">#805</a>).</li> <li>Fix possible <code>RuntimeError</code> when using <code>multiprocessing.set_start_method()</code> after importing the <code>logger</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/974">#974</a>).</li> <li>Fix formatting of possible <code>__notes__</code> attached to an <code>Exception</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/980">#980</a>).</li> </ul> <h2>0.7.1</h2> <ul> <li>Add a new <code>context</code> optional argument to <code>logger.add()</code> specifying <code>multiprocessing</code> context (like <code>"spawn"</code> or <code>"fork"</code>) to be used internally instead of the default one (<a href="https://redirect.github.com/Delgan/loguru/issues/851">#851</a>).</li> <li>Add support for true colors on Windows using ANSI/VT console when available (<a href="https://redirect.github.com/Delgan/loguru/issues/934">#934</a>, thanks <a href="https://github.com/tunaflsh"><code>@tunaflsh</code></a>).</li> <li>Fix possible deadlock when calling <code>logger.complete()</code> with concurrent logging of an asynchronous sink (<a href="https://redirect.github.com/Delgan/loguru/issues/906">#906</a>).</li> <li>Fix file possibly rotating too early or too late when re-starting an application around midnight (<a href="https://redirect.github.com/Delgan/loguru/issues/894">#894</a>).</li> <li>Fix inverted <code>"<hide>"</code> and <code>"<strike>"</code> color tags (<a href="https://redirect.github.com/Delgan/loguru/issues/943">#943</a>, thanks <a href="https://github.com/tunaflsh"><code>@tunaflsh</code></a>).</li> <li>Fix possible untraceable errors raised when logging non-unpicklable <code>Exception</code> instances while using <code>enqueue=True</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/329">#329</a>).</li> <li>Fix possible errors raised when logging non-picklable <code>Exception</code> instances while using <code>enqueue=True</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/342">#342</a>, thanks <a href="https://github.com/ncoudene"><code>@ncoudene</code></a>).</li> <li>Fix missing seconds and microseconds when formatting timezone offset that requires such accuracy (<a href="https://redirect.github.com/Delgan/loguru/issues/961">#961</a>).</li> <li>Raise <code>ValueError</code> if an attempt to use nanosecond precision for time formatting is detected (<a href="https://redirect.github.com/Delgan/loguru/issues/855">#855</a>).</li> </ul> <h2>0.7.0</h2> <ul> <li>Update <code>InterceptHandler</code> recipe to make it compatible with Python 3.11 (<a href="https://redirect.github.com/Delgan/loguru/issues/654">#654</a>).</li> <li>Add a new <code>watch</code> optional argument to file sinks in order to automatically re-create possibly deleted or changed file (<a href="https://redirect.github.com/Delgan/loguru/issues/471">#471</a>).</li> <li>Make <code>patch()</code> calls cumulative instead of overriding the possibly existing patching function (<a href="https://redirect.github.com/Delgan/loguru/issues/462">#462</a>).</li> <li>Make sinks added with <code>enqueue=True</code> and <code>catch=False</code> still process logged messages in case of internal exception (<a href="https://redirect.github.com/Delgan/loguru/issues/833">#833</a>).</li> <li>Avoid possible deadlocks caused by re-using the logger inside a sink, a signal handler or a <code>__del__</code> method. Since the logger is not re-entrant, such misuse will be detected and will now generate a <code>RuntimeError</code> (<a href="https://redirect.github.com/Delgan/loguru/issues/712">#712</a>, thanks <a href="https://github.com/jacksmith15"><code>@jacksmith15</code></a>).</li> <li>Fix file sink rotation using an aware <code>datetime.time</code> for which the timezone was ignored (<a href="https://redirect.github.com/Delgan/loguru/issues/697">#697</a>).</li> <li>Fix logs colorization not automatically enabled for Jupyter Notebook and Google Colab (<a href="https://redirect.github.com/Delgan/loguru/issues/494">#494</a>).</li> <li>Fix logs colorization not automatically enabled for Github Actions and others CI platforms (<a href="https://redirect.github.com/Delgan/loguru/issues/604">#604</a>).</li> <li>Fix <code>logger.complete()</code> possibly hanging forever when <code>enqueue=True</code> and <code>catch=False</code> if internal thread killed due to <code>Exception</code> raised by sink (<a href="https://redirect.github.com/Delgan/loguru/issues/647">#647</a>).</li> <li>Fix incompatibility with <code>freezegun</code> library used to simulate time (<a href="https://redirect.github.com/Delgan/loguru/issues/600">#600</a>).</li> <li>Raise exception if <code>logger.catch()</code> is used to wrap a class instead of a function to avoid unexpected behavior (<a href="https://redirect.github.com/Delgan/loguru/issues/623">#623</a>).</li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/Delgan/loguru/blob/master/CHANGELOG.rst">loguru's changelog</a>.</em></p> <blockquote> <h1><code>0.7.3</code>_ (2024-12-06)</h1> <ul> <li>Fix Cython incompatibility caused by the absence of underlying stack frames, which resulted in a <code>ValueError</code> during logging (<code>[#88](Delgan/loguru#88) <https://github.com/Delgan/loguru/issues/88></code>_).</li> <li>Fix possible <code>RuntimeError</code> when removing all handlers with <code>logger.remove()</code> due to thread-safety issue (<code>[#1183](Delgan/loguru#1183) <https://github.com/Delgan/loguru/issues/1183></code><em>, thanks <code>@jeremyk <https://github.com/jeremyk></code></em>).</li> <li>Fix <code>diagnose=True</code> option of exception formatting not working as expected with Python 3.13 (<code>[#1235](Delgan/loguru#1235) <https://github.com/Delgan/loguru/issues/1235></code><em>, thanks <code>@etianen <https://github.com/etianen></code></em>).</li> <li>Fix non-standard level names not fully compatible with <code>logging.Formatter()</code> (<code>[#1231](Delgan/loguru#1231) <https://github.com/Delgan/loguru/issues/1231></code><em>, thanks <code>@yechielb2000 <https://github.com/yechielb2000></code></em>).</li> <li>Fix inability to display a literal <code>"\"</code> immediately before color markups (<code>[#988](Delgan/loguru#988) <https://github.com/Delgan/loguru/issues/988></code>_).</li> <li>Fix possible infinite recursion when an exception is raised from a <code>__repr__</code> method decorated with <code>logger.catch()</code> (<code>[#1044](Delgan/loguru#1044) <https://github.com/Delgan/loguru/issues/1044></code>_).</li> <li>Improve performance of <code>datetime</code> formatting while logging messages (<code>[#1201](Delgan/loguru#1201) <https://github.com/Delgan/loguru/issues/1201></code><em>, thanks <code>@trim21 <https://github.com/trim21></code></em>).</li> <li>Reduce startup time in the presence of installed but unused <code>IPython</code> third-party library (<code>[#1001](Delgan/loguru#1001) <https://github.com/Delgan/loguru/issues/1001></code><em>, thanks <code>@zakstucke <https://github.com/zakstucke></code></em>).</li> </ul> <h1><code>0.7.2</code>_ (2023-09-11)</h1> <ul> <li>Add support for formatting of <code>ExceptionGroup</code> errors (<code>[#805](Delgan/loguru#805) <https://github.com/Delgan/loguru/issues/805></code>_).</li> <li>Fix possible <code>RuntimeError</code> when using <code>multiprocessing.set_start_method()</code> after importing the <code>logger</code> (<code>[#974](Delgan/loguru#974) <https://github.com/Delgan/loguru/issues/974></code>_).</li> <li>Fix formatting of possible <code>__notes__</code> attached to an <code>Exception</code> (<code>[#980](Delgan/loguru#980) <https://github.com/Delgan/loguru/issues/980></code>_).</li> </ul> <h1><code>0.7.1</code>_ (2023-09-04)</h1> <ul> <li>Add a new <code>context</code> optional argument to <code>logger.add()</code> specifying <code>multiprocessing</code> context (like <code>"spawn"</code> or <code>"fork"</code>) to be used internally instead of the default one (<code>[#851](Delgan/loguru#851) <https://github.com/Delgan/loguru/issues/851></code>_).</li> <li>Add support for true colors on Windows using ANSI/VT console when available (<code>[#934](Delgan/loguru#934) <https://github.com/Delgan/loguru/issues/934></code><em>, thanks <code>@tunaflsh <https://github.com/tunaflsh></code></em>).</li> <li>Fix possible deadlock when calling <code>logger.complete()</code> with concurrent logging of an asynchronous sink (<code>[#906](Delgan/loguru#906) <https://github.com/Delgan/loguru/issues/906></code>_).</li> <li>Fix file possibly rotating too early or too late when re-starting an application around midnight (<code>[#894](Delgan/loguru#894) <https://github.com/Delgan/loguru/issues/894></code>_).</li> <li>Fix inverted <code>"<hide>"</code> and <code>"<strike>"</code> color tags (<code>[#943](Delgan/loguru#943) <https://github.com/Delgan/loguru/pull/943></code><em>, thanks <code>@tunaflsh <https://github.com/tunaflsh></code></em>).</li> <li>Fix possible untraceable errors raised when logging non-unpicklable <code>Exception</code> instances while using <code>enqueue=True</code> (<code>[#329](Delgan/loguru#329) <https://github.com/Delgan/loguru/issues/329></code>_).</li> <li>Fix possible errors raised when logging non-picklable <code>Exception</code> instances while using <code>enqueue=True</code> (<code>[#342](Delgan/loguru#342) <https://github.com/Delgan/loguru/issues/342></code><em>, thanks <code>@ncoudene <https://github.com/ncoudene></code></em>).</li> <li>Fix missing seconds and microseconds when formatting timezone offset that requires such accuracy (<code>[#961](Delgan/loguru#961) <https://github.com/Delgan/loguru/issues/961></code>_).</li> <li>Raise <code>ValueError</code> if an attempt to use nanosecond precision for time formatting is detected (<code>[#855](Delgan/loguru#855) <https://github.com/Delgan/loguru/issues/855></code>_).</li> </ul> <h1><code>0.7.0</code>_ (2023-04-10)</h1> <ul> <li>Update <code>InterceptHandler</code> recipe to make it compatible with Python 3.11 (<code>[#654](Delgan/loguru#654) <https://github.com/Delgan/loguru/issues/654></code>_).</li> <li>Add a new <code>watch</code> optional argument to file sinks in order to automatically re-create possibly deleted or changed file (<code>[#471](Delgan/loguru#471) <https://github.com/Delgan/loguru/issues/471></code>_).</li> <li>Make <code>patch()</code> calls cumulative instead of overriding the possibly existing patching function (<code>[#462](Delgan/loguru#462) <https://github.com/Delgan/loguru/issues/462></code>_).</li> <li>Make sinks added with <code>enqueue=True</code> and <code>catch=False</code> still process logged messages in case of internal exception (<code>[#833](Delgan/loguru#833) <https://github.com/Delgan/loguru/issues/833></code>_).</li> <li>Avoid possible deadlocks caused by re-using the logger inside a sink, a signal handler or a <code>__del__</code> method. Since the logger is not re-entrant, such misuse will be detected and will now generate a <code>RuntimeError</code> (<code>[#712](Delgan/loguru#712) <https://github.com/Delgan/loguru/issues/712></code><em>, thanks <code>@jacksmith15 <https://github.com/jacksmith15></code></em>).</li> <li>Fix file sink rotation using an aware <code>datetime.time</code> for which the timezone was ignored (<code>[#697](Delgan/loguru#697) <https://github.com/Delgan/loguru/issues/697></code>_).</li> <li>Fix logs colorization not automatically enabled for Jupyter Notebook and Google Colab (<code>[#494](Delgan/loguru#494) <https://github.com/Delgan/loguru/issues/494></code>_).</li> <li>Fix logs colorization not automatically enabled for Github Actions and others CI platforms (<code>[#604](Delgan/loguru#604) <https://github.com/Delgan/loguru/issues/604></code>_).</li> <li>Fix <code>logger.complete()</code> possibly hanging forever when <code>enqueue=True</code> and <code>catch=False</code> if internal thread killed due to <code>Exception</code> raised by sink (<code>[#647](Delgan/loguru#647) <https://github.com/Delgan/loguru/issues/647></code>_).</li> <li>Fix incompatibility with <code>freezegun</code> library used to simulate time (<code>[#600](Delgan/loguru#600) <https://github.com/Delgan/loguru/issues/600></code>_).</li> <li>Raise exception if <code>logger.catch()</code> is used to wrap a class instead of a function to avoid unexpected behavior (<code>[#623](Delgan/loguru#623) <https://github.com/Delgan/loguru/issues/623></code>_).</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/Delgan/loguru/commit/ae3bfd1b85b6b4a3db535f69b975687c79498be4"><code>ae3bfd1</code></a> Bump version to 0.7.3</li> <li><a href="https://github.com/Delgan/loguru/commit/ccca3566cc00c22eed8659705e45386fa2101b5d"><code>ccca356</code></a> Replace "notifiers" (seems unmaintained) with "apprise" in docs (<a href="https://redirect.github.com/Delgan/loguru/issues/1251">#1251</a>)</li> <li><a href="https://github.com/Delgan/loguru/commit/a372814bf79d47628e66ca9a91072f53fba032f8"><code>a372814</code></a> Configure "trusted publishing" in Github workflow</li> <li><a href="https://github.com/Delgan/loguru/commit/633016db07e5dff63bc05dd3c4d5aa81b6190700"><code>633016d</code></a> Use tox to define the "release" command</li> <li><a href="https://github.com/Delgan/loguru/commit/ef12cbbaf54fb2e64ca66b0a90675cdf9e8a522f"><code>ef12cbb</code></a> Convert README from RST to MD (fix PyPI packaging)</li> <li><a href="https://github.com/Delgan/loguru/commit/cb3314a5af107ad175a9bafa11b1b79670e3067a"><code>cb3314a</code></a> Add Github action to verify packaging</li> <li><a href="https://github.com/Delgan/loguru/commit/6161a13b79e1a3a29e922926b44f26edbcc3c06a"><code>6161a13</code></a> Complete the "Troubleshooting" docs with more examples</li> <li><a href="https://github.com/Delgan/loguru/commit/7f5001fe46393627ced287bba2c4064442c3fd25"><code>7f5001f</code></a> Simplify the example of dynamic handler level</li> <li><a href="https://github.com/Delgan/loguru/commit/2e0cd7bb5105461057c56aefb225da569882ad29"><code>2e0cd7b</code></a> Move "Introduction to logging" docs to a new section</li> <li><a href="https://github.com/Delgan/loguru/commit/72b93d1a24d1491ce7ba752fe36c14f9570a5d63"><code>72b93d1</code></a> Correct outdated instructions for reporting a vulnerability</li> <li>Additional commits viewable in <a href="https://github.com/Delgan/loguru/compare/0.6.0...0.7.3">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=loguru&package-manager=pip&previous-version=0.6.0&new-version=0.7.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Hi @Delgan
When using loguru 0.2.5 inside python script it works as expected, but when i compile this file to an executable using Cython i get this error and program terminates :
call stack is not deep enough
More info of the error :
Do you have any idea why ?
I tried increasing the execution depth limit inside the script that i import loguru by using sys.setrecursionlimit(3000) but still issue remains..
OS: raspbian stretch lite
Cython-0.29.7
The text was updated successfully, but these errors were encountered: