[Debian-astro-maintainers] Bug#1082130: sunpy FTBFS with Python 3.13

Stefano Rivera stefanor at debian.org
Wed Sep 18 17:52:07 BST 2024


Source: sunpy
Version: 6.0.2-1
Severity: serious
Tags: ftbfs
Justification: FTBFS
User: debian-python at lists.debian.org
Usertags: python3.13

This package failed build from source when test-built against a version of
python3-defaults that includes 3.13 as a supported version.

To reproduce this issue, build against python3-defaults (python3-all-dev etc.)
from Debian experimental.

What's new in Python 3.13:
https://docs.python.org/3.13/whatsnew/3.13.html

Presumably <sys/time.h> -> <time.h> will fix this.

Log snippet:

creating build/temp.linux-aarch64-cpython-313/sunpy/io/src
creating build/temp.linux-aarch64-cpython-313/sunpy/io/src/ana
aarch64-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/lib/python3/dist-packages/numpy/core/include -I/usr/include/python3.13 -c sunpy/io/src/ana/_pyana.c -o build/temp.linux-aarch64-cpython-313/sunpy/io/src/ana/_pyana.o -std=c99 -O3 -w
sunpy/io/src/ana/_pyana.c: In function ‘pyana_fzwrite’:
sunpy/io/src/ana/_pyana.c:286:19: error: implicit declaration of function ‘gmtime’ [-Wimplicit-function-declaration]
  286 |         tm_time = gmtime(&(tv_time->tv_sec));
      |                   ^~~~~~
sunpy/io/src/ana/_pyana.c:22:1: note: ‘gmtime’ is defined in header ‘<time.h>’; this is probably fixable by adding ‘#include <time.h>’
   21 | #include "anarw.h"
  +++ |+#include <time.h>
   22 | 
sunpy/io/src/ana/_pyana.c:286:17: error: assignment to ‘struct tm *’ from ‘int’ makes pointer from integer without a cast [-Wint-conversion]
  286 |         tm_time = gmtime(&(tv_time->tv_sec));
      |                 ^
sunpy/io/src/ana/_pyana.c:290:20: error: invalid use of undefined type ‘struct tm’
  290 |             tm_time->tm_hour, tm_time->tm_min, tm_time->tm_sec, (long) (tv_time->tv_usec/1000));
      |                    ^~
sunpy/io/src/ana/_pyana.c:290:38: error: invalid use of undefined type ‘struct tm’
  290 |             tm_time->tm_hour, tm_time->tm_min, tm_time->tm_sec, (long) (tv_time->tv_usec/1000));
      |                                      ^~
sunpy/io/src/ana/_pyana.c:290:55: error: invalid use of undefined type ‘struct tm’
  290 |             tm_time->tm_hour, tm_time->tm_min, tm_time->tm_sec, (long) (tv_time->tv_usec/1000));
      |                                                       ^~
error: command '/usr/bin/aarch64-linux-gnu-gcc' failed with exit code 1
E: pybuild pybuild:389: build: plugin distutils failed with: exit code=1: /usr/bin/python3.13 setup.py build 


If required, the full build log is available here (for the next 30 days):
https://debusine.debian.net/artifact/776134/

This bug has been filed at "normal" severity, as we haven't started the
transition to add 3.13 as a supported version, yet. This will be raised to RC
as soon as that happens, hopefully well before trixie.

Thanks,

Stefano



More information about the Debian-astro-maintainers mailing list