Hello, I need help installing lseg python library

You'll find below the error message generated. It seems there is a problem with Numpy dependency. The version of Numpy is 2.1.2 .
----------------------------------------------------
PS C:\Users\VVMD250\OneDrive - LA POSTE GROUPE\PYTHON> pip install lseg-data
Requirement already satisfied: lseg-data in c:\users\vvmd250\appdata\local\programs\python\python313\lib\site-packages (2.0.0)
Collecting appdirs~=1.4.4 (from lseg-data)
Using cached appdirs-1.4.4-py2.py3-none-any.whl.metadata (9.0 kB)
Collecting pyee<=11.1.0,>=9.0.4 (from lseg-data)
Using cached pyee-11.1.0-py3-none-any.whl.metadata (2.8 kB)
Collecting httpx<0.27.0,>=0.18.0 (from lseg-data)
Using cached httpx-0.26.0-py3-none-any.whl.metadata (7.6 kB)
Collecting httpcore<1.1.0 (from lseg-data)
Using cached httpcore-1.0.6-py3-none-any.whl.metadata (21 kB)
Collecting numpy~=1.11 (from lseg-data)
Using cached numpy-1.26.4.tar.gz (15.8 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [21 lines of output]
+ C:\Users\VVMD250\AppData\Local\Programs\Python\Python313\python.exe C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05\vendored-meson\meson\meson.py setup C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05 C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05\.mesonpy-wf4x7hyg -Dbuildtype=release -Db_ndebug=if-release -Db_vscrt=md --native-file=C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05\.mesonpy-wf4x7hyg\meson-python-native-file.ini
The Meson build system
Version: 1.2.99
Source dir: C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05
Build dir: C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05\.mesonpy-wf4x7hyg
Build type: native build
Project name: NumPy
Project version: 1.26.4
WARNING: Failed to activate VS environment: Could not find C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe
..\meson.build:1:0: ERROR: Unknown compiler(s): [['icl'], ['cl'], ['cc'], ['gcc'], ['clang'], ['clang-cl'], ['pgcc']]
The following exception(s) were encountered:
Running `icl ""` gave "[WinError 2] Le fichier spécifié est introuvable"
Running `cl /?` gave "[WinError 2] Le fichier spécifié est introuvable"
Running `cc --version` gave "[WinError 2] Le fichier spécifié est introuvable"
Running `gcc --version` gave "[WinError 2] Le fichier spécifié est introuvable"
Running `clang --version` gave "[WinError 2] Le fichier spécifié est introuvable"
Running `clang-cl /?` gave "[WinError 2] Le fichier spécifié est introuvable"
Running `pgcc --version` gave "[WinError 2] Le fichier spécifié est introuvable"
A full log can be found at C:\Users\VVMD250\AppData\Local\Temp\pip-install-lrt1g0vb\numpy_fbc4ac54da0e4ffea961a3b75906ea05\.mesonpy-wf4x7hyg\meson-logs\meson-log.txt
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
PS C:\Users\VVMD250\OneDrive - LA POSTE GROUPE\PYTHON>
Best regards
Answers
-
Lseg data will try to install numpy version of 1.25.2. Please try installing that version of numpy manually before running pip install lseg.data.
Best regards,
0 -
Hello @julien.lebon-lafond01
I suggest you use the Python version 3.10 (download here) and use the Python virtual environment to avoid the library version conflict as mentioned by my colleague above.
You can create a new Python environment, then install and use the LSEG Data Library in that environment, so the installed libraries will not conflict with your main Python installation.
- Python Virtual Environments: A Primer
- Python Virtual Environment | Introduction
- Install packages in a virtual environment using pip and venv
This is the result from my Python 3.10.15 virtual environment:
(test_lseg) C:\Users\UserA>pip install lseg-data
Collecting lseg-data
Using cached lseg_data-2.0.0-py3-none-any.whl.metadata (10 kB)
Collecting appdirs~=1.4.4 (from lseg-data)
Using cached appdirs-1.4.4-py2.py3-none-any.whl.metadata (9.0 kB)
Collecting pyee<=11.1.0,>=9.0.4 (from lseg-data)
Using cached pyee-11.1.0-py3-none-any.whl.metadata (2.8 kB)
Collecting httpx<0.27.0,>=0.18.0 (from lseg-data)
Using cached httpx-0.26.0-py3-none-any.whl.metadata (7.6 kB)
Collecting httpcore<1.1.0 (from lseg-data)
Using cached httpcore-1.0.6-py3-none-any.whl.metadata (21 kB)
Collecting numpy~=1.11 (from lseg-data)
Using cached numpy-1.26.4-cp310-cp310-win_amd64.whl.metadata (61 kB)
....
Using cached exceptiongroup-1.2.2-py3-none-any.whl (16 kB)
Installing collected packages: pytz, pyhumps, appdirs, websocket-client, watchdog, urllib3, tzdata, typing-extensions, tenacity, sniffio, six, simplejson, numpy, MarkupSafe, idna, h11, exceptiongroup, charset-normalizer, certifi, scipy, requests, python-dateutil, pyee, jinja2, httpcore, anyio, pandas, httpx, lseg-data
Successfully installed MarkupSafe-3.0.2 anyio-4.6.2.post1 appdirs-1.4.4 certifi-2024.8.30 charset-normalizer-3.4.0 exceptiongroup-1.2.2 h11-0.14.0 httpcore-1.0.6 httpx-0.26.0 idna-3.10 jinja2-3.1.4 lseg-data-2.0.0 numpy-1.26.4 pandas-2.2.3 pyee-11.1.0 pyhumps-3.8.0 python-dateutil-2.9.0.post0 pytz-2024.2 requests-2.32.3 scipy-1.12.0 simplejson-3.19.3 six-1.16.0 sniffio-1.3.1 tenacity-8.5.0 typing-extensions-4.12.2 tzdata-2024.2 urllib3-2.2.3 watchdog-2.3.1 websocket-client-1.8.0
(test_lseg) C:\Users\UserA>0 -
You may try to use the following command.
pip install --no-cache-dir lseg-data
0 -
I have the same problem. I tried all advices above, but I always get the following error:
Collecting numpy~=1.11 (from lseg-data)
Using cached numpy-1.26.4.tar.gz (15.8 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [21 lines of output]
. . .
Project name: NumPy
Project version: 1.26.4
WARNING: Failed to activate VS environment: Could not parse vswhere.exe output..\meson.build:1:0: ERROR: Unknown compiler(s): [['icl'], ['cl'], ['cc'], ['gcc'], ['clang'], ['clang-cl'], ['pgcc']]
The following exception(s) were encountered:
Running `icl ""` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
Running `cl /?` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
Running `cc --version` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
Running `gcc --version` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
Running `clang --version` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
Running `clang-cl /?` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
Running `pgcc --version` gave "[WinError 2] Das System kann die angegebene Datei nicht finden"
I have installed the current version 3.13.1 of Python. I tried to install the numpy-version 1.25.2 before installing lseg-data - but that made no difference.
I am a beginner and currently at a loss!
Can somebody help me?0 -
Please try with Python version 3.11 instead.
0 -
Thank You! That's it! With Python 3.11 it works!
0
Categories
- All Categories
- 3 Polls
- 6 AHS
- 36 Alpha
- 166 App Studio
- 6 Block Chain
- 4 Bot Platform
- 18 Connected Risk APIs
- 47 Data Fusion
- 34 Data Model Discovery
- 684 Datastream
- 1.4K DSS
- 613 Eikon COM
- 5.2K Eikon Data APIs
- 10 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- 3 Trading API
- 2.9K Elektron
- 1.4K EMA
- 248 ETA
- 552 WebSocket API
- 37 FX Venues
- 14 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 23 Messenger Bot
- 3 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 60 Open Calais
- 275 Open PermID
- 44 Entity Search
- 2 Org ID
- 1 PAM
- PAM - Logging
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 22 RDMS
- 1.9K Refinitiv Data Platform
- 638 Refinitiv Data Platform Libraries
- 4 LSEG Due Diligence
- LSEG Due Diligence Portal API
- 4 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.2K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 12 World-Check Customer Risk Screener
- 1K World-Check One
- 46 World-Check One Zero Footprint
- 45 Side by Side Integration API
- 2 Test Space
- 3 Thomson One Smart
- 10 TR Knowledge Graph
- 151 Transactions
- 143 REDI API
- 1.8K TREP APIs
- 4 CAT
- 26 DACS Station
- 121 Open DACS
- 1.1K RFA
- 104 UPA
- 191 TREP Infrastructure
- 228 TRKD
- 915 TRTH
- 5 Velocity Analytics
- 9 Wealth Management Web Services
- 88 Workspace SDK
- 11 Element Framework
- 5 Grid
- 18 World-Check Data File
- 1 Yield Book Analytics
- 46 中文论坛