×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

import PyIndi results in segmentation fault (core dumped)

  • Posts: 9
  • Thank you received: 0
Hello, I am copying this from the github issue opened up with the same subject. Any help would be appreciated. Thanks in advance.

I tried the walkthrough on pip website since it is the recommended method for Ubuntu users.
This includes installing all prerequisites calling: `sudo apt-get install python-setuptools python-dev libindi-dev swig`
Then I get a _successful_ install of <strong>pyindi-client-0.2.6</strong> using _pip3_ calling: <code>sudo -H pip3 install pyindi-client</code>
But as soon as I try to import <strong>PyIndi</strong> the python instance crashes with the message: segmentation fault (core dumped)
I tried reinstalling the dependencies, but no luck.
Also, I checked the package calling: `pip3 check pyindi-client` and I got the response _No broken requirements found_
Then, after reading the stackoverflow question: [python tracing a segmentation fault](stackoverflow.com/a/2664232/6474744) I tried to get to the root of the problem using **gdb** by calling:
$ mkdir db-pyindi
$ cd db-pyindi
$ echo "import PyIndi" > import-pyindi.py
$ gdb python3
GNU gdb (Ubuntu 8.1-0ubuntu3.2) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from python3...(no debugging symbols found)...done.
(gdb) run import-pyindi.py
Starting program: /usr/bin/python3 import-pyindi.py
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
 
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff54232b9 in GlobalError::PushToStack() ()
   from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.5.0
(gdb) backtrace
#0  0x00007ffff54232b9 in GlobalError::PushToStack() ()
   from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.5.0
#1  0x00007ffff54a6fc2 in pkgInitConfig(Configuration&) ()
   from /usr/lib/x86_64-linux-gnu/libapt-pkg.so.5.0
#2  0x00007ffff5d41ed8 in ?? ()
   from /usr/lib/python3/dist-packages/apt_pkg.cpython-36m-x86_64-linux-gnu.so
Warning: Spoiler!

After hours of search, this was as far as I could go right now. Any help would be appreciated.
Last edit: 3 years 1 month ago by Pedram. Reason: Improved formatting
3 years 2 months ago #66390

Please Log in or Create an account to join the conversation.

  • Posts: 9
  • Thank you received: 0
It looks like I had to delete previous libraries **manually**. A simple reinstall did not work for me. Maybe that is because all indi-related libraries were not removed automatically.
3 years 1 month ago #66678

Please Log in or Create an account to join the conversation.

Time to create page: 1.007 seconds