platform.ldp connection does not retrieve data (desktop.workspace does)

Options

Hello, I have correctly set up a configuration file and got started to lseg-data (I used to have my apps on eikon python library).

I am trying to fetch sample data for apple bid and ask price. When I do it with my workspace application open and use the desktop.workspace session (default) it works and returns data. When I do it with platform.ldp (does it matter if the workspace application is open?) it returns a null dataframe (no errors or warning).

Can you help me to understand why is that?

Best Answer

  • Jirapongse
    Jirapongse ✭✭✭✭✭
    edited July 9 Answer ✓

    The error indicates that the account doesn't have permission to access AAPL.O.

    [{"ID": 5, "Type": "Status", "Key": {"Service": "ELEKTRON_DD", "Name": "AAPL.O"}, "State": {"Stream": "Closed", "Data": "Suspect", "Code": "NotEntitled", "Text": "Access Denied: User req to PE(74)"}}]

    You may try a delayed RIC (/AAPL.O).

    df = ld.get_data(
    universe=['/AAPL.O'],
    fields=['BID', 'ASK']
    )

Answers

  • Hello @claudio_cirillo

    Do you have LDP credentials? LSEG Data Platform is a separate product and is not connected to Workspace. In addition, your account would need access to streaming prices within LDP to get the real time data for an instrument.

    I recommend to reach out to your LSEG account manager to check/get these additional products.

  • Jirapongse
    Jirapongse ✭✭✭✭✭

    @claudio_cirillo

    Typically, it could be a permission issue.

    You can enable the debug log in the LSEG Data Library for Python to verify what the problem is.

    config = ld.get_config()
    config.set_param("logs.transports.file.enabled", True)
    config.set_param("logs.transports.file.name", "lseg-data-lib.log")
    config.set_param("logs.level", "debug")

    Run the above code before opening a session. The lseg-data-lib.log file will be created in the current directory.

    Please remove the private information from the log file and then share it.

    We can check from the log file if it is a permission issue.

  • Thank you so much, these are the log.

    The code i was running is

    ld.open_session(name = 'platform.ldp')

    df = ld.get_data(
    universe=['AAPL.O'],
    fields=['BID', 'ASK']
    )

    ld.close_session()

    I have removed user id password and client id.

  • It worked, thank you very much for your help