<div dir="ltr">Awesome, thanks! <br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Oct 20, 2022 at 7:33 AM Phil Thompson <<a href="mailto:phil@riverbankcomputing.com">phil@riverbankcomputing.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">On 18/10/2022 22:52, Patrick Stinson wrote:<br>
> Phil,<br>
> <br>
> I found a bug in sipbuild-6.7.2.<br>
> <br>
> I got the following exception when running into errors in my custom sip<br>
> files while upgrading from PyQt5 to PyQt6. It looks like changing<br>
> OverloadFormatter(overload,<br>
> scope) to OverloadFormatter('any string', overload, scope) allows<br>
> exceptions to be printed.<br>
> <br>
> bash-5.2$ sip-build<br>
> Querying qmake about your Qt installation...<br>
> /Users/patrick/dev/lib/Qt/6.4.0/macos/bin/qmake -query<br>
> These bindings will be built: _pkdiagram.<br>
> Generating the _pkdiagram bindings...<br>
> sip-build: An internal error occurred...<br>
> Traceback (most recent call last):<br>
> File "/Users/patrick/dev/familydiagram/.venv/bin/sip-build", line 8, <br>
> in<br>
> <module><br>
> sys.exit(main())<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/tools/build.py",<br>
> line 37, in main<br>
> handle_exception(e)<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/exceptions.py",<br>
> line 81, in handle_exception<br>
> raise e<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/tools/build.py",<br>
> line 34, in main<br>
> project.build()<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/project.py",<br>
> line 244, in build<br>
> self.builder.build()<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/builder.py",<br>
> line 48, in build<br>
> self._generate_bindings()<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/builder.py",<br>
> line 277, in _generate_bindings<br>
> buildable = bindings.generate()<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/bindings.py",<br>
> line 171, in generate<br>
> resolve(spec)<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/generator/resolver/resolver.py",<br>
> line 98, in resolve<br>
> _resolve_module(spec, spec.modules[0], error_log)<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/generator/resolver/resolver.py",<br>
> line 231, in _resolve_module<br>
> _resolve_scope_overloads(spec, klass.overloads, error_log,<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/generator/resolver/resolver.py",<br>
> line 936, in _resolve_scope_overloads<br>
> _resolve_func_types(spec, overload.common.module, scope, overload,<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/generator/resolver/resolver.py",<br>
> line 1288, in _resolve_func_types<br>
> _resolve_py_signature_types(spec, mod, scope, overload, error_log)<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/generator/resolver/resolver.py",<br>
> line 1375, in _resolve_py_signature_types<br>
> _log_overload_error(error_log,<br>
> File<br>
> "/Users/patrick/dev/familydiagram/.venv/lib/python3.10/site-packages/sipbuild/generator/resolver/resolver.py",<br>
> line 2195, in _log_overload_error<br>
> formatter = OverloadFormatter(overload, scope)<br>
> TypeError: ScopedFormatter.__init__() missing 1 required positional<br>
> argument: 'scope'<br>
> <br>
> Cheers,<br>
> -Patrick<br>
<br>
Should be fixed in the next snapshot.<br>
<br>
Thanks,<br>
Phil<br>
</blockquote></div>