apache/arrow-adbc

glib fails to build with `No module named 'distutils.msvccompiler'`

Opened this issue · 6 comments

What happened?

The glib build seems to be failing on a few PRs with No module named 'distutils.msvccompiler'. From a tiny bit of reading it looks like this was removed in setuptools 74 (or maybe 75, since that was released a few days ago). Do we need to pin a version of that somewhere or use a different version of gobject-introspection?

Stack Trace

Traceback (most recent call last):
  File "/home/runner/miniconda3/envs/test/bin/g-ir-scanner", line 103, in <module>
    from giscanner.scannermain import scanner_main
  File "/home/runner/miniconda3/envs/test/lib/gobject-introspection/giscanner/scannermain.py", line 35, in <module>
    from giscanner.ast import Include, Namespace
  File "/home/runner/miniconda3/envs/test/lib/gobject-introspection/giscanner/ast.py", line 27, in <module>
    from .sourcescanner import CTYPE_TYPEDEF, CSYMBOL_TYPE_TYPEDEF
  File "/home/runner/miniconda3/envs/test/lib/gobject-introspection/giscanner/sourcescanner.py", line 25, in <module>
    from .ccompiler import CCompiler
  File "/home/runner/miniconda3/envs/test/lib/gobject-introspection/giscanner/ccompiler.py", line 29, in <module>
    from distutils.msvccompiler import MSVCCompiler
ModuleNotFoundError: No module named 'distutils.msvccompiler'

https://github.com/apache/arrow-adbc/actions/runs/10951989992/job/30410093912?pr=2157#step:10:73

How can we reproduce the bug?

No response

Environment/Setup

No response

kou commented

It seems that this was fixed in upstream: https://gitlab.gnome.org/GNOME/gobject-introspection/-/merge_requests/490
And 1.82.0 includes this.

conda-forge/gobject-introspection-feedstock#76 will fix this.

kou commented

Or can we use old distutils for now?

I'm OK waiting for the update; we could also pip install gobject-introspection for now?

kou commented

gobject-introspection isn't distributed via pip...

Ah...

Ok well it's probably easy enough to pin old distutils for the time being too