Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Installing guppy with pip3 issues

I am trying to install guppy. My program uses python3 so I must use pip3 exclusively. When I run:

pip3 install guppy

I get:

src/sets/sets.c:77:1: error: expected function body after function declarator
INITFUNC (void)
^
src/sets/sets.c:39:18: note: expanded from macro 'INITFUNC'
#define INITFUNC initsetsc
                 ^
1 error generated.
error: command 'clang' failed with exit status 1

I tried doing this, even thourgh it wasn't the same and exported gcc and g++:

➜  ~ export CC=gcc
➜  ~ export CXX=g++

Running again:

src/sets/sets.c:77:1: error: expected function body after function declarator
INITFUNC (void)
^
src/sets/sets.c:39:18: note: expanded from macro 'INITFUNC'
#define INITFUNC initsetsc
                 ^
1 error generated.
error: command 'gcc' failed with exit status 1

Most who had this issue used sudo apt-get python-dev or something of the like to resolve this issue, I couldn't find an equivalent for Mac. Is there a way to resolve this issue?

like image 488
Dair Avatar asked Aug 09 '16 20:08

Dair


People also ask

Should I install with pip or pip3?

You have to use pip3 for it to be installed on Python3. So to install packages in python3, you should use pip3. NOTE:- Its not necessary that pip will install in python 2.7, if python2 is absent then pip will do it in python3. The above statement was if you have both the version of python installed.

What does pip3 install do?

Install Pip3. pip3 is the official package manager and pip command for Python 3. It enables the installation and management of third party software packages with features and functionality not found in the Python standard library. Pip3 installs packages from PyPI (Python Package Index).

Does pip3 install globally?

If you're using sudo with pip3 command, package will install to /usr/local/bin/mysqlclient directory which will be accessed by all users(i.e. installing globally). Whereas, without sudo it will install to ~/. local/bin/mysqlclient directory and only access current user(i.e. installing locally).

How do I install pip3 on Windows 10?

I Installed pip and pip3 in my windows 10 system easily from the official Microsoft store. Search python3. 9 in Microsoft store. then, click on "Get" to install on you windows platform.


1 Answers

Unfortunately it seems that guppy library works only for Python 2.x. An alternative could be objgraph

like image 198
mic4ael Avatar answered Sep 22 '22 21:09

mic4ael