Comments (5)
Hi roybka,
I had the same problem and I solved today by installing the version 3.5.12, instead of the latest one.
pip3 install rpy2==3.5.12
Hope this can help,
Chiara
from rpy2.
@chiara111p111 Solved! thanks a lot.
I think I'll keep this open since the authors of the repo might want to fix it in the current version.
from rpy2.
Can you share the output of running
pip install -v -U rpy2
?
In particular, I am interested in the section that reports the R setup and the C libraries. It should start with
something like:
Building wheels for collected packages: rpy2
Running command Building wheel for rpy2 (pyproject.toml)
cffi mode is CFFI_MODE.ANY
Looking for R home with: R RHOME
R home found: /usr/local/packages/R/4.3/lib/R
R exec path: /usr/local/packages/R/4.3/lib/R/bin/R
(...)
from rpy2.
Voila
Collecting rpy2
Using cached rpy2-3.5.15.tar.gz (219 kB)
Running command pip subprocess to install build dependencies
Looking in indexes: http://nutrino:****@pypi.nutrino.co/simple
Ignoring packaging: markers 'platform_system == "Windows"' don't match your environment
Collecting setuptools>=61
Using cached setuptools-69.0.3-py3-none-any.whl.metadata (6.3 kB)
Collecting wheel
Using cached wheel-0.42.0-py3-none-any.whl.metadata (2.2 kB)
Collecting cffi>=1.15.0
Using cached cffi-1.16.0-cp39-cp39-macosx_11_0_arm64.whl.metadata (1.5 kB)
Collecting pycparser (from cffi>=1.15.0)
Using cached pycparser-2.21-py2.py3-none-any.whl (118 kB)
Using cached setuptools-69.0.3-py3-none-any.whl (819 kB)
Using cached wheel-0.42.0-py3-none-any.whl (65 kB)
Using cached cffi-1.16.0-cp39-cp39-macosx_11_0_arm64.whl (176 kB)
Installing collected packages: wheel, setuptools, pycparser, cffi
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
services-commons 0.2.24 requires requests==2.22.0, but you have requests 2.31.0 which is incompatible.
services-commons 0.2.24 requires typing-extensions==3.7.4.3, but you have typing-extensions 4.7.1 which is incompatible.
spacy-transformers 1.2.5 requires transformers<4.31.0,>=3.4.0, but you have transformers 4.36.2 which is incompatible.
tensorboard 2.9.1 requires protobuf<3.20,>=3.9.2, but you have protobuf 3.20.0 which is incompatible.
tensorboard 2.9.1 requires werkzeug>=1.0.1, but you have werkzeug 0.16.0 which is incompatible.
tensorflow-macos 2.9.2 requires protobuf<3.20,>=3.9.2, but you have protobuf 3.20.0 which is incompatible.
Successfully installed cffi-1.16.0 pycparser-2.21 setuptools-69.0.3 wheel-0.42.0
Installing build dependencies ... done
Running command Getting requirements to build wheel
ld: library not found for -lpcre2-8
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Traceback (most recent call last):
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/_distutils/unixccompiler.py", line 266, in link
self.spawn(linker + ld_args)
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/_distutils/ccompiler.py", line 1041, in spawn
spawn(cmd, dry_run=self.dry_run, **kwargs)
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/_distutils/spawn.py", line 70, in spawn
raise DistutilsExecError(
distutils.errors.DistutilsExecError: command '/usr/bin/clang' failed with exit code 1
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/amitr2/.pyenv/versions/miniforge3/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
main()
File "/Users/amitr2/.pyenv/versions/miniforge3/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/Users/amitr2/.pyenv/versions/miniforge3/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
return hook(config_settings)
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 325, in get_requires_for_build_wheel
return self._get_build_requires(config_settings, requirements=['wheel'])
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 295, in _get_build_requires
self.run_setup()
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 311, in run_setup
exec(code, locals())
File "", line 141, in
File "", line 121, in get_r_c_extension_status
File "", line 82, in get_c_extension_status
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/_distutils/ccompiler.py", line 781, in link_executable
self.link(
File "/private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-build-env-sv7c2bp8/overlay/lib/python3.9/site-packages/setuptools/_distutils/unixccompiler.py", line 268, in link
raise LinkError(msg)
distutils.errors.LinkError: command '/usr/bin/clang' failed with exit code 1
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
full command: /Users/amitr2/.pyenv/versions/miniforge3/bin/python3.9 /Users/amitr2/.pyenv/versions/miniforge3/lib/python3.9/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py get_requires_for_build_wheel /var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/tmp2dfufoy3
cwd: /private/var/folders/2n/ylg3knfx2px41qbz6z60yt_h0000gn/T/pip-install-fatz4r1t/rpy2_c5b2cc74f60241668a0c2f2bfd23e3a2
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
from rpy2.
The CI pipeline is now building "universal" binary on silicon, although with warnings.
See https://github.com/rpy2/rpy2/actions/runs/8106498299/job/22156525623#step:6:308 and following lines.
The library pcre2-8, that is missing on your system, is present there (but built for a different architecture).
from rpy2.
Related Issues (20)
- Support `.rx[row, col]` indexing for matrices and data frames HOT 1
- Allow assigning to rownames, colnames and dimnames for sparse matrices HOT 3
- Installation regression from 3.5.12 to 3.5.13 in Rocky 8 Linux with R 4.3.1 HOT 4
- cannot load library
- rpy2 tests fail with Python 3.13 (in alpha now) HOT 2
- Issues Integrating Library Functions with Python via rpy2 HOT 2
- rpy2 cannot properly call the DataFrame object within the S4Vectors package. HOT 2
- Issue converting R data frame to Pandas data frame HOT 1
- rpy2 cannot resolve the correct on Mac M1 HOT 1
- BoolVector to array conversion behaves unexpectedly HOT 3
- Installation on linux platform HOT 1
- NotImplementedError: Conversion rules for `rpy2.robjects` appear to be missing. Those rules are in a Python contextvars.ContextVar. This could be caused by multithreading code not passing context to the thread. HOT 2
- Not an rpy2 R object and unable to map it to one: 'value' HOT 2
- PEP 517 builds rpy2 fails to install on Windows HOT 2
- Error in Colab, rmagic and pandas 2.x HOT 2
- can't install rpy2 3.5.16 on Ubuntu 22.04.3 LTS HOT 16
- Unable to install rpy2 in centos7/rhel7 with R4.4.0 HOT 1
- vector complex test failed on riscv64 HOT 5
- Cannot import packages HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rpy2.