Skip to content
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

Exception handling incompatibility with different compiler versions #78

Closed
1 task done
ktlim opened this issue Mar 8, 2022 · 5 comments
Closed
1 task done
Labels

Comments

@ktlim
Copy link

ktlim commented Mar 8, 2022

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

We observed a failure, on linux-64 only, to invoke a pybind11 exception translator when it was built with g++ 9.4 and the exception-throwing code was built with g++ 10.3.

The attached file gives a small example. If the handler and example files are built (using the given shell scripts) with the same g++ version, when running example.py everything works properly (the output includes "In translator"). But if the handler is built with g++ 9.4 and the example is built with g++ 10.3, it fails (the output does not contain that string). It also fails when built the other way, with the handler under 10.3 and the example under 9.4.

This may be related to #77

minexample.txt

Installed packages

# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       1_gnu    conda-forge
binutils_impl_linux-64    2.36.1               h193b22a_2    conda-forge
bzip2                     1.0.8                h7f98852_4    conda-forge
ca-certificates           2021.10.8            ha878542_0    conda-forge
gcc                       9.4.0                h192d537_6    conda-forge
gcc_impl_linux-64         9.4.0               h03d3576_13    conda-forge
gxx                       9.4.0                h192d537_6    conda-forge
gxx_impl_linux-64         9.4.0               h03d3576_13    conda-forge
kernel-headers_linux-64   2.6.32              he073ed8_15    conda-forge
ld_impl_linux-64          2.36.1               hea4e1c9_2    conda-forge
libffi                    3.4.2                h7f98852_5    conda-forge
libgcc-devel_linux-64     9.4.0               hd854feb_13    conda-forge
libgcc-ng                 11.2.0              h1d223b6_13    conda-forge
libgomp                   11.2.0              h1d223b6_13    conda-forge
libnsl                    2.0.0                h7f98852_0    conda-forge
libsanitizer              9.4.0               h79bfe98_13    conda-forge
libstdcxx-devel_linux-64  9.4.0               hd854feb_13    conda-forge
libstdcxx-ng              11.2.0              he4da1e4_13    conda-forge
libuuid                   2.32.1            h7f98852_1000    conda-forge
libzlib                   1.2.11            h36c2ea0_1013    conda-forge
ncurses                   6.3                  h9c3ff4c_0    conda-forge
openssl                   3.0.0                h7f98852_2    conda-forge
pip                       22.0.4             pyhd8ed1ab_0    conda-forge
pybind11                  2.9.1           py310h91b1402_0    conda-forge
pybind11-global           2.9.1           py310h91b1402_0    conda-forge
python                    3.10.2          hc74c709_3_cpython    conda-forge
python_abi                3.10                    2_cp310    conda-forge
readline                  8.1                  h46c0cb4_0    conda-forge
setuptools                60.9.3          py310hff52083_0    conda-forge
sqlite                    3.37.0               h9cd32fc_0    conda-forge
sysroot_linux-64          2.12                he073ed8_15    conda-forge
tk                        8.6.12               h27826a3_0    conda-forge
tzdata                    2021e                he74cb21_0    conda-forge
wheel                     0.37.1             pyhd8ed1ab_0    conda-forge
xz                        5.2.5                h516909a_1    conda-forge
zlib                      1.2.11            h36c2ea0_1013    conda-forge

and

# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       1_gnu    conda-forge
binutils_impl_linux-64    2.36.1               h193b22a_2    conda-forge
bzip2                     1.0.8                h7f98852_4    conda-forge
ca-certificates           2021.10.8            ha878542_0    conda-forge
gcc                       10.3.0               he2824d0_6    conda-forge
gcc_impl_linux-64         10.3.0              hf2f2afa_13    conda-forge
gxx                       10.3.0               he2824d0_6    conda-forge
gxx_impl_linux-64         10.3.0              hf2f2afa_13    conda-forge
kernel-headers_linux-64   2.6.32              he073ed8_15    conda-forge
ld_impl_linux-64          2.36.1               hea4e1c9_2    conda-forge
libffi                    3.4.2                h7f98852_5    conda-forge
libgcc-devel_linux-64     10.3.0              he6cfe16_13    conda-forge
libgcc-ng                 11.2.0              h1d223b6_13    conda-forge
libgomp                   11.2.0              h1d223b6_13    conda-forge
libnsl                    2.0.0                h7f98852_0    conda-forge
libsanitizer              10.3.0              h26c7422_13    conda-forge
libstdcxx-devel_linux-64  10.3.0              he6cfe16_13    conda-forge
libstdcxx-ng              11.2.0              he4da1e4_13    conda-forge
libuuid                   2.32.1            h7f98852_1000    conda-forge
libzlib                   1.2.11            h36c2ea0_1013    conda-forge
ncurses                   6.3                  h9c3ff4c_0    conda-forge
openssl                   3.0.0                h7f98852_2    conda-forge
pip                       22.0.4             pyhd8ed1ab_0    conda-forge
pybind11                  2.9.1           py310h91b1402_0    conda-forge
pybind11-global           2.9.1           py310h91b1402_0    conda-forge
python                    3.10.2          hc74c709_3_cpython    conda-forge
python_abi                3.10                    2_cp310    conda-forge
readline                  8.1                  h46c0cb4_0    conda-forge
setuptools                60.9.3          py310hff52083_0    conda-forge
sqlite                    3.37.0               h9cd32fc_0    conda-forge
sysroot_linux-64          2.12                he073ed8_15    conda-forge
tk                        8.6.12               h27826a3_0    conda-forge
tzdata                    2021e                he74cb21_0    conda-forge
wheel                     0.37.1             pyhd8ed1ab_0    conda-forge
xz                        5.2.5                h516909a_1    conda-forge
zlib                      1.2.11            h36c2ea0_1013    conda-forge

Environment info

active environment : min94
    active env location : /home/ktlim/.conda/envs/min94
            shell level : 2
       user config file : /home/ktlim/.condarc
 populated config files : /home/ktlim/.condarc
          conda version : 4.11.0
    conda-build version : not installed
         python version : 3.8.5.final.0
       virtual packages : __linux=3.10.0=0
                          __glibc=2.17=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /software/lsstsw/stack_20220215/conda/miniconda3-py38_4.9.2  (read only)
      conda av data dir : /software/lsstsw/stack_20220215/conda/miniconda3-py38_4.9.2/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
                          https://conda.anaconda.org/intel/linux-64
                          https://conda.anaconda.org/intel/noarch
                          https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /software/lsstsw/stack_20220215/conda/miniconda3-py38_4.9.2/pkgs
                          /home/ktlim/.conda/pkgs
       envs directories : /home/ktlim/.conda/envs
                          /software/lsstsw/stack_20220215/conda/miniconda3-py38_4.9.2/envs
               platform : linux-64
             user-agent : conda/4.11.0 requests/2.24.0 CPython/3.8.5 Linux/3.10.0-1160.49.1.el7.x86_64 centos/7.9.2009 glibc/2.17
                UID:GID : 49831:202
             netrc file : None
           offline mode : False

and

     active environment : min103
    active env location : /home/ktlim/stack2/conda/envs/min103
            shell level : 3
       user config file : /home/ktlim/.condarc
 populated config files : /home/ktlim/stack2/conda/.condarc
                          /home/ktlim/.condarc
          conda version : 4.11.0
    conda-build version : not installed
         python version : 3.9.10.final.0
       virtual packages : __linux=3.10.0=0
                          __glibc=2.17=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /home/ktlim/stack2/conda  (writable)
      conda av data dir : /home/ktlim/stack2/conda/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
                          https://conda.anaconda.org/intel/linux-64
                          https://conda.anaconda.org/intel/noarch
                          https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /home/ktlim/stack2/conda/pkgs
                          /home/ktlim/.conda/pkgs
       envs directories : /home/ktlim/stack2/conda/envs
                          /home/ktlim/.conda/envs
               platform : linux-64
             user-agent : conda/4.11.0 requests/2.27.1 CPython/3.9.10 Linux/3.10.0-1160.49.1.el7.x86_64 centos/7.9.2009 glibc/2.17
                UID:GID : 49831:202
             netrc file : None
           offline mode : False
@ktlim ktlim added the bug label Mar 8, 2022
@ktlim
Copy link
Author

ktlim commented Mar 8, 2022

I was told to ping @isuruf on this...

@ktlim
Copy link
Author

ktlim commented Mar 8, 2022

Oops, slight typo in the attached file. Let me try that again:
minexample.txt
(and fixed the link in the initial comment)

@isuruf
Copy link
Member

isuruf commented Mar 8, 2022

It's the same as #77. Can you post your reproducer there and close this issue?

@isuruf
Copy link
Member

isuruf commented Mar 8, 2022

I mean post at #77

@ktlim
Copy link
Author

ktlim commented Mar 8, 2022

Posted code at #77.

@ktlim ktlim closed this as completed Mar 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants