AstuteSource / chasten

:dizzy: Chasten Uses XML and XPATH to Check a Python Program's AST for Specified Patterns!
https://pypi.org/project/chasten/
GNU General Public License v2.0
7 stars 8 forks source link

Installing Chasten for MacOS #44

Closed rodriguez03 closed 10 months ago

rodriguez03 commented 12 months ago

We could write in the issues that here are several ways to install chasten. Anyone is welcome to contribute more ways

pip failed to build package:
    pysqlite3

Some possibly relevant errors from pip install:
    error: subprocess-exited-with-error
    src/connection.c:1385:10: error: implicit declaration of function 'sqlite3_enable_load_extension' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
    src/connection.c:1409:10: error: implicit declaration of function 'sqlite3_load_extension' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
    error: command '/usr/bin/clang' failed with exit code 1

or another error looks like:

failed to building wheels for pysqlite3
Jaclynpqc commented 12 months ago

Here are the ways I've tried to install pysqlite3 on MacOS but failed. Maybe they will work for you. The aim of this issue is to provide a comprehensive guide for troubleshooting 'pysqlite3' installation issues on macOS.

1. Guidance from Discord (Claire's Instruction) @churd01 Attempted to follow installation instructions provided by Claire in Developer Development community, details of which can be viewed here: https://discord.com/channels/1145161007459745852/1146079356402278521/1146576453161467904 Outcome: when I run this command, the Error indicates 'Permission Denied ln -s /usr/local/opt/sqlite/bin/sqlite3 /usr/local/bin/

2. Pip Install Attempt Command: pip install pysqlite3 Outcome: Error message as follows ERROR: Failed building wheel for pysqlite3 Running setup.py clean for pysqlite3 Failed to build pysqlite3 ERROR: Could not build wheels for pysqlite3, which is required to install pyproject.toml-based projects Actions Taken:

3. Virtual Environment Setup Command: Created a Python venv using python -m venv myenv and activated using ource myenv/bin/activate Outcome: Within the virtual environment, repeated the attempt to pip install pysqlite3, resulting the same error.

At the moment, I'm trying to remove pysqlite3 package from dependencies and make sure that Chasten is installed and run correctly. You can check out the issue here: https://github.com/AstuteSource/chasten/issues/46

Suggestions @rodriguez03 suggested overriding pysqlite3 in the Developer Development Discord group. You can read more details about her suggestion here: https://discord.com/channels/1145161007459745852/1145801720811765800/1149054131126943895

gkapfham commented 12 months ago

Briefly, here are some points to consider in regards to this issue:

gkapfham commented 11 months ago

What is the status of this issue @Jaclynpqc and @rodriguez03?

boulais01 commented 11 months ago

Is this resolved with the recent merging of pysqlite3-removal-test-branch?

rodriguez03 commented 10 months ago

Most of our colleagues with Mac OS have gotten chasten to work