{ "cells": [ { "cell_type": "markdown", "id": "a5efb768", "metadata": {}, "source": [ " \n", "Dividend-Data\n", "----\n", "\n", "Timeframe: 2010 - 2021\n", "

\n", "\n", "**Content Overview**\n", " - Install and load libaries, set-up connection to Eikon\n", " - Prepare data (extract rics, retrieve data, prepare dataframe)\n", " - Generate graphs (distribution of DPS by NAICS-Sector)\n", " - Appendix (useful code snippets)\n", " " ] }, { "cell_type": "markdown", "id": "538ad375", "metadata": {}, "source": [ "### *Install and load libaries*" ] }, { "cell_type": "code", "execution_count": 9, "id": "b7154ca1", "metadata": { "code_folding": [] }, "outputs": [], "source": [ "# %%capture\n", "# import sys\n", "# !{sys.executable} -m pip install eikon;" ] }, { "cell_type": "code", "execution_count": 10, "id": "c42cf2eb", "metadata": {}, "outputs": [], "source": [ "# eikon connection\n", "import eikon as ek\n", "ek.set_app_key('')" ### ] }, { "cell_type": "code", "execution_count": 11, "id": "cc9a4268", "metadata": { "code_folding": [] }, "outputs": [], "source": [ "# load libraries\n", "import numpy as np\n", "import pandas as pd\n", "import datetime as datetime" ] }, { "cell_type": "markdown", "id": "af723786", "metadata": {}, "source": [ "### *Data retrieval and data preparation*" ] }, { "cell_type": "code", "execution_count": 12, "id": "dc65fac7", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "\n" ] }, { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
InstrumentConstituent RICConstituent Name
0.STOXXBOUY.PABOUYGUES ORD
1.STOXXAMPF.MIAMPLIFON SPA ORD
2.STOXXGETP.PAGETLINK ORD
3.STOXXHRGV.LHARGREAVES LS ORD
4.STOXXINGA.ASING GROEP ORD
............
595.STOXXANDR.VIANDRITZ ORD
596.STOXXMBGn.DEMERCEDES-BENZ GROUP AG ORD
597.STOXXNG.LNATIONAL GRID ORD
598.STOXXSWECb.STSWECO ORD
599.STOXXENI.MIENI ORD
\n", "

600 rows × 3 columns

\n", "
" ], "text/plain": [ " Instrument Constituent RIC Constituent Name\n", "0 .STOXX BOUY.PA BOUYGUES ORD\n", "1 .STOXX AMPF.MI AMPLIFON SPA ORD\n", "2 .STOXX GETP.PA GETLINK ORD\n", "3 .STOXX HRGV.L HARGREAVES LS ORD\n", "4 .STOXX INGA.AS ING GROEP ORD\n", ".. ... ... ...\n", "595 .STOXX ANDR.VI ANDRITZ ORD\n", "596 .STOXX MBGn.DE MERCEDES-BENZ GROUP AG ORD\n", "597 .STOXX NG.L NATIONAL GRID ORD\n", "598 .STOXX SWECb.ST SWECO ORD\n", "599 .STOXX ENI.MI ENI ORD\n", "\n", "[600 rows x 3 columns]" ] }, "execution_count": 12, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# retrieve constituents\n", "x = ek.get_data('.STOXX', ['TR.IndexConstituentRIC','TR.IndexConstituentName'])[0]\n", "print(type(x))\n", "x" ] }, { "cell_type": "code", "execution_count": 13, "id": "897fa921", "metadata": { "code_folding": [] }, "outputs": [], "source": [ "# extract rics\n", "rics = x.iloc[:,1]\n", "rics = rics.tolist()" ] }, { "cell_type": "code", "execution_count": 14, "id": "92d566c4", "metadata": { "scrolled": true }, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
InstrumentDividend Announcement DateDividend Record DateGross Dividend AmountDividend TypeDividend Payment TypeDividend CurrencyDividend Announcement DateDividend Ex DateDividend Pay DateDividend Event StatusNotesDividend FrequencySource Of Funds
0BOUY.PA2010-03-022010-05-061.6FinalCash DividendEUR2010-03-022010-05-042010-05-07ApprovedAGM 29 April 2010.Annual dividendRegular profit
1BOUY.PA2011-03-012011-05-031.6FinalCash DividendEUR2011-03-012011-04-292011-05-04ApprovedAGM 21 April 2011.Annual dividendRegular profit
2BOUY.PA2012-02-282012-05-031.6FinalCash DividendEUR2012-02-282012-04-302012-05-04ApprovedAGM 26 April 2012.Annual dividendRegular profit
3BOUY.PA2013-02-272013-05-031.6FinalCash DividendEUR2013-02-272013-04-302013-05-06ApprovedAGM 25 April 2013.Annual dividendRegular profit
4BOUY.PA2014-02-262014-05-021.6FinalCash and Stock AlternativeEUR2014-02-262014-05-052014-06-04ApprovedThe dividend can be paid in cash or in shares....Annual dividendRegular profit
5BOUY.PA2015-02-252015-04-291.6FinalCash DividendEUR2015-02-252015-04-282015-04-30Approved<NA>Annual dividendRegular profit
6BOUY.PA2016-02-242016-04-271.6FinalCash DividendEUR2016-02-242016-04-262016-04-28Approved<NA>Annual dividendRegular profit
7BOUY.PA2017-02-232017-05-041.6FinalCash DividendEUR2017-02-232017-05-032017-05-05Approved<NA>Annual dividendRegular profit
8BOUY.PA2018-02-222018-05-031.7FinalCash DividendEUR2018-02-222018-05-022018-05-04Approved<NA>Annual dividendRegular profit
9BOUY.PA2019-02-212019-05-021.7FinalCash DividendEUR2019-02-212019-04-302019-05-03Approved<NA>Annual dividendRegular profit
\n", "
" ], "text/plain": [ " Instrument Dividend Announcement Date Dividend Record Date \\\n", "0 BOUY.PA 2010-03-02 2010-05-06 \n", "1 BOUY.PA 2011-03-01 2011-05-03 \n", "2 BOUY.PA 2012-02-28 2012-05-03 \n", "3 BOUY.PA 2013-02-27 2013-05-03 \n", "4 BOUY.PA 2014-02-26 2014-05-02 \n", "5 BOUY.PA 2015-02-25 2015-04-29 \n", "6 BOUY.PA 2016-02-24 2016-04-27 \n", "7 BOUY.PA 2017-02-23 2017-05-04 \n", "8 BOUY.PA 2018-02-22 2018-05-03 \n", "9 BOUY.PA 2019-02-21 2019-05-02 \n", "\n", " Gross Dividend Amount Dividend Type Dividend Payment Type \\\n", "0 1.6 Final Cash Dividend \n", "1 1.6 Final Cash Dividend \n", "2 1.6 Final Cash Dividend \n", "3 1.6 Final Cash Dividend \n", "4 1.6 Final Cash and Stock Alternative \n", "5 1.6 Final Cash Dividend \n", "6 1.6 Final Cash Dividend \n", "7 1.6 Final Cash Dividend \n", "8 1.7 Final Cash Dividend \n", "9 1.7 Final Cash Dividend \n", "\n", " Dividend Currency Dividend Announcement Date Dividend Ex Date \\\n", "0 EUR 2010-03-02 2010-05-04 \n", "1 EUR 2011-03-01 2011-04-29 \n", "2 EUR 2012-02-28 2012-04-30 \n", "3 EUR 2013-02-27 2013-04-30 \n", "4 EUR 2014-02-26 2014-05-05 \n", "5 EUR 2015-02-25 2015-04-28 \n", "6 EUR 2016-02-24 2016-04-26 \n", "7 EUR 2017-02-23 2017-05-03 \n", "8 EUR 2018-02-22 2018-05-02 \n", "9 EUR 2019-02-21 2019-04-30 \n", "\n", " Dividend Pay Date Dividend Event Status \\\n", "0 2010-05-07 Approved \n", "1 2011-05-04 Approved \n", "2 2012-05-04 Approved \n", "3 2013-05-06 Approved \n", "4 2014-06-04 Approved \n", "5 2015-04-30 Approved \n", "6 2016-04-28 Approved \n", "7 2017-05-05 Approved \n", "8 2018-05-04 Approved \n", "9 2019-05-03 Approved \n", "\n", " Notes Dividend Frequency \\\n", "0 AGM 29 April 2010. Annual dividend \n", "1 AGM 21 April 2011. Annual dividend \n", "2 AGM 26 April 2012. Annual dividend \n", "3 AGM 25 April 2013. Annual dividend \n", "4 The dividend can be paid in cash or in shares.... Annual dividend \n", "5 Annual dividend \n", "6 Annual dividend \n", "7 Annual dividend \n", "8 Annual dividend \n", "9 Annual dividend \n", "\n", " Source Of Funds \n", "0 Regular profit \n", "1 Regular profit \n", "2 Regular profit \n", "3 Regular profit \n", "4 Regular profit \n", "5 Regular profit \n", "6 Regular profit \n", "7 Regular profit \n", "8 Regular profit \n", "9 Regular profit " ] }, "execution_count": 14, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# dividend data\n", "df = ek.get_data(rics,\n", " ['TR.DivAnnouncementDate',\n", " 'TR.DivRecordDate',\n", " 'TR.DivUnadjustedGross',\n", " 'TR.DivType',\n", " 'TR.DivPaymentType',\n", " 'TR.DivCurr',\n", " 'TR.DivAnnouncementDate',\n", " 'TR.DivExDate',\n", " 'TR.DivPayDate',\n", " 'TR.DivEventStatus',\n", " 'TR.DivNotes',\n", " 'TR.DividendFrequency',\n", " 'TR.DivSourceOfFunds'],\n", " {\n", " \"SDate\":\"2010-01-01\",\"EDate\":\"2022-09-27\",\n", " })[0]\n", "df.to_excel('stoxx_dividends_data.xlsx', sheet_name='sheet1', index=False)\n", "df.head(10)" ] }, { "cell_type": "code", "execution_count": 15, "id": "64d9fc06", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
InstrumentCompany Common NameIncorp. Region CodeISINNAICS Sector NameNAICS Industry Group NameNAICS Industry Group CodeIssuer RatingDate
0BOUY.PABouygues SAFRAFR0000120503ConstructionHighway, Street, and Bridge Construction2373A32011-08-31T00:00:00Z
1BOUY.PAFR0011121888<NA>A32012-02-09T00:00:00Z
2BOUY.PAFR0000120503<NA>Baa12014-03-05T00:00:00Z
3BOUY.PA<NA>Baa12014-03-05T00:00:00Z
4BOUY.PA<NA>A32016-02-29T00:00:00Z
5BOUY.PA<NA>BB-2016-02-29T00:00:00Z
6BOUY.PA<NA>A22016-12-05T00:00:00Z
7BOUY.PA<NA>BB2017-04-17T00:00:00Z
8BOUY.PA<NA>A12018-01-04T00:00:00Z
9BOUY.PA<NA>BB+2018-01-04T00:00:00Z
\n", "
" ], "text/plain": [ " Instrument Company Common Name Incorp. Region Code ISIN \\\n", "0 BOUY.PA Bouygues SA FRA FR0000120503 \n", "1 BOUY.PA FR0011121888 \n", "2 BOUY.PA FR0000120503 \n", "3 BOUY.PA \n", "4 BOUY.PA \n", "5 BOUY.PA \n", "6 BOUY.PA \n", "7 BOUY.PA \n", "8 BOUY.PA \n", "9 BOUY.PA \n", "\n", " NAICS Sector Name NAICS Industry Group Name \\\n", "0 Construction Highway, Street, and Bridge Construction \n", "1 \n", "2 \n", "3 \n", "4 \n", "5 \n", "6 \n", "7 \n", "8 \n", "9 \n", "\n", " NAICS Industry Group Code Issuer Rating Date \n", "0 2373 A3 2011-08-31T00:00:00Z \n", "1 A3 2012-02-09T00:00:00Z \n", "2 Baa1 2014-03-05T00:00:00Z \n", "3 Baa1 2014-03-05T00:00:00Z \n", "4 A3 2016-02-29T00:00:00Z \n", "5 BB- 2016-02-29T00:00:00Z \n", "6 A2 2016-12-05T00:00:00Z \n", "7 BB 2017-04-17T00:00:00Z \n", "8 A1 2018-01-04T00:00:00Z \n", "9 BB+ 2018-01-04T00:00:00Z " ] }, "execution_count": 15, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# meta-information\n", "df = ek.get_data(\n", " #'BAWG.VI',\n", " rics,\n", " ['TR.CommonName',\n", " 'TR.CompanyIncorpRegion',\n", " 'TR.ISIN',\n", " 'TR.NAICSSector',\n", " 'TR.NAICSIndustryGroup',\n", " 'TR.NAICSIndustryGroupCode',\n", " 'TR.IssuerRating',\n", " 'TR.IssuerRating.Date'],\n", " {\n", " \"SDate\":\"2010-01-01\",\"EDate\":\"2022-09-27\",\n", " })[0]\n", "\n", "df.to_excel('stoxx_meta_data.xlsx', sheet_name='sheet1', index=False)\n", "df.head(10)\n" ] }, { "cell_type": "code", "execution_count": 16, "id": "1ac36ee0", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
InstrumentRevenueTotal Operating ExpenseEBITEBITDANet Income Before TaxesNet Income After TaxesCash and Short Term InvestmentsTotal Assets, ReportedTotal LiabilitiesNet Debt Incl. Pref.Stock & Min.InterestTotal EquityCompany Market CapFree Cash Flow
0BAWG.VI<NA><NA><NA><NA><NA><NA><NA><NA><NA><NA><NA><NA><NA>
1BAWG.VI<NA><NA>220100000274600000220100000221800000<NA>36402000000.033999000000.0<NA>2403000000.0<NA>229300000
2BAWG.VI<NA><NA>345200000411200000345200000336400000<NA>34651000000.032246000000.0<NA>2405000000.0<NA>355400000
3BAWG.VI<NA><NA>448200000480800000448200000417900000<NA>35515000000.032756000000.0<NA>2759000000.0<NA>396500000
4BAWG.VI<NA><NA>460700000509700000460700000473600000<NA>39761000000.036638000000.0<NA>3123000000.0<NA>159600000
5BAWG.VI<NA><NA>500400000581400000500400000449200000<NA>46056000000.042480000000.0<NA>3576000000.0<NA>412200000
6BAWG.VI<NA><NA>572700000630700000572700000436500000<NA>44698000000.040694000000.0<NA>4004000000.0<NA>374500000
7BAWG.VI<NA><NA>604300000677500000604300000459300000<NA>45648000000.041835000000.0<NA>3813000000.0<NA>250500000
8BAWG.VI<NA><NA>469900000550900000369900000284500000<NA>53122000000.048772000000.0<NA>4350000000.0<NA>344500000
9BAWG.VI<NA><NA>658600000727100000600400000480000000<NA>56325000000.051952000000.0<NA>4373000000.0<NA>46500000
\n", "
" ], "text/plain": [ " Instrument Revenue Total Operating Expense EBIT EBITDA \\\n", "0 BAWG.VI \n", "1 BAWG.VI 220100000 274600000 \n", "2 BAWG.VI 345200000 411200000 \n", "3 BAWG.VI 448200000 480800000 \n", "4 BAWG.VI 460700000 509700000 \n", "5 BAWG.VI 500400000 581400000 \n", "6 BAWG.VI 572700000 630700000 \n", "7 BAWG.VI 604300000 677500000 \n", "8 BAWG.VI 469900000 550900000 \n", "9 BAWG.VI 658600000 727100000 \n", "\n", " Net Income Before Taxes Net Income After Taxes \\\n", "0 \n", "1 220100000 221800000 \n", "2 345200000 336400000 \n", "3 448200000 417900000 \n", "4 460700000 473600000 \n", "5 500400000 449200000 \n", "6 572700000 436500000 \n", "7 604300000 459300000 \n", "8 369900000 284500000 \n", "9 600400000 480000000 \n", "\n", " Cash and Short Term Investments Total Assets, Reported Total Liabilities \\\n", "0 \n", "1 36402000000.0 33999000000.0 \n", "2 34651000000.0 32246000000.0 \n", "3 35515000000.0 32756000000.0 \n", "4 39761000000.0 36638000000.0 \n", "5 46056000000.0 42480000000.0 \n", "6 44698000000.0 40694000000.0 \n", "7 45648000000.0 41835000000.0 \n", "8 53122000000.0 48772000000.0 \n", "9 56325000000.0 51952000000.0 \n", "\n", " Net Debt Incl. Pref.Stock & Min.Interest Total Equity Company Market Cap \\\n", "0 \n", "1 2403000000.0 \n", "2 2405000000.0 \n", "3 2759000000.0 \n", "4 3123000000.0 \n", "5 3576000000.0 \n", "6 4004000000.0 \n", "7 3813000000.0 \n", "8 4350000000.0 \n", "9 4373000000.0 \n", "\n", " Free Cash Flow \n", "0 \n", "1 229300000 \n", "2 355400000 \n", "3 396500000 \n", "4 159600000 \n", "5 412200000 \n", "6 374500000 \n", "7 250500000 \n", "8 344500000 \n", "9 46500000 " ] }, "execution_count": 16, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# financial data\n", "df = ek.get_data(\n", " 'BAWG.VI',\n", " #rics,\n", " ['TR.Revenue',\n", " 'TR.TotalOperatingExpense',\n", " 'TR.EBIT',\n", " 'TR.EBITDA',\n", " 'TR.NetIncomeBeforeTaxes',\n", " 'TR.NetIncomeAfterTaxes',\n", " 'TR.CashAndSTInvestments',\n", " 'TR.TotalAssetsReported',\n", " 'TR.TotalLiabilities',\n", " 'TR.NetDebt',\n", " 'TR.TotalEquity',\n", " 'TR.CompanyMarketCap',\n", " 'TR.Beta',\n", " 'TR.FreeCashFlow'],\n", " {\n", " \"SDate\":\"2010-01-01\",\"EDate\":\"2022-09-27\",\n", " })[0]\n", "df.to_excel('stoxx_financial_data.xlsx', sheet_name='sheet1', index=False)\n", "df.head(10)\n" ] }, { "cell_type": "code", "execution_count": 17, "id": "abe16e1f", "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "2022-03-24 09:55:46,697 P[9824] [MainThread 16772] HTTP TimeoutException: TimeoutException on HTTP request: ReadTimeout('').\n" ] }, { "ename": "EikonError", "evalue": "Error code 408 | HTTP TimeoutException: TimeoutException on HTTP request: ReadTimeout('').", "output_type": "error", "traceback": [ "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m", "\u001b[1;31mReadTimeout\u001b[0m Traceback (most recent call last)", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_transports\\default.py\u001b[0m in \u001b[0;36mmap_httpcore_exceptions\u001b[1;34m()\u001b[0m\n\u001b[0;32m 60\u001b[0m \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m---> 61\u001b[1;33m \u001b[1;32myield\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 62\u001b[0m \u001b[1;32mexcept\u001b[0m \u001b[0mException\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0mexc\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_transports\\default.py\u001b[0m in \u001b[0;36mhandle_async_request\u001b[1;34m(self, method, url, headers, stream, extensions)\u001b[0m\n\u001b[0;32m 280\u001b[0m \u001b[0mextensions\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 281\u001b[1;33m \u001b[1;33m)\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_pool\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mhandle_async_request\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 282\u001b[0m \u001b[0mmethod\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mmethod\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpcore\\_async\\connection_pool.py\u001b[0m in \u001b[0;36mhandle_async_request\u001b[1;34m(self, method, url, headers, stream, extensions)\u001b[0m\n\u001b[0;32m 236\u001b[0m \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 237\u001b[1;33m response = await connection.handle_async_request(\n\u001b[0m\u001b[0;32m 238\u001b[0m \u001b[0mmethod\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0murl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mheaders\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mheaders\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mstream\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mstream\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mextensions\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mextensions\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpcore\\_async\\connection.py\u001b[0m in \u001b[0;36mhandle_async_request\u001b[1;34m(self, method, url, headers, stream, extensions)\u001b[0m\n\u001b[0;32m 147\u001b[0m )\n\u001b[1;32m--> 148\u001b[1;33m return await self.connection.handle_async_request(\n\u001b[0m\u001b[0;32m 149\u001b[0m \u001b[0mmethod\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0murl\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mheaders\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mstream\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mextensions\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpcore\\_async\\http11.py\u001b[0m in \u001b[0;36mhandle_async_request\u001b[1;34m(self, method, url, headers, stream, extensions)\u001b[0m\n\u001b[0;32m 127\u001b[0m \u001b[0mheaders\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 128\u001b[1;33m ) = await self._receive_response(timeout)\n\u001b[0m\u001b[0;32m 129\u001b[0m response_stream = AsyncIteratorByteStream(\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpcore\\_async\\http11.py\u001b[0m in \u001b[0;36m_receive_response\u001b[1;34m(self, timeout)\u001b[0m\n\u001b[0;32m 188\u001b[0m \u001b[1;32mwhile\u001b[0m \u001b[1;32mTrue\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 189\u001b[1;33m \u001b[0mevent\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_receive_event\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mtimeout\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 190\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0misinstance\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mevent\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mh11\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mResponse\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpcore\\_async\\http11.py\u001b[0m in \u001b[0;36m_receive_event\u001b[1;34m(self, timeout)\u001b[0m\n\u001b[0;32m 224\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mevent\u001b[0m \u001b[1;32mis\u001b[0m \u001b[0mh11\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mNEED_DATA\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 225\u001b[1;33m \u001b[0mdata\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msocket\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mread\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mREAD_NUM_BYTES\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mtimeout\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 226\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpcore\\_backends\\anyio.py\u001b[0m in \u001b[0;36mread\u001b[1;34m(self, n, timeout)\u001b[0m\n\u001b[0;32m 62\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mstream\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0maclose\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m---> 63\u001b[1;33m \u001b[1;32mraise\u001b[0m \u001b[0mReadTimeout\u001b[0m \u001b[1;32mfrom\u001b[0m \u001b[1;32mNone\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 64\u001b[0m \u001b[1;32mexcept\u001b[0m \u001b[0mBrokenResourceError\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0mexc\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;31mReadTimeout\u001b[0m: ", "\nThe above exception was the direct cause of the following exception:\n", "\u001b[1;31mReadTimeout\u001b[0m Traceback (most recent call last)", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\streaming_session\\session.py\u001b[0m in \u001b[0;36mhttp_request_async\u001b[1;34m(self, url, method, headers, data, params, json, closure, auth, loop, **kwargs)\u001b[0m\n\u001b[0;32m 636\u001b[0m \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 637\u001b[1;33m \u001b[0m_request_response\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_http_session\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msend\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0m_http_request\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;33m**\u001b[0m\u001b[0mkwargs\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 638\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mlog\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;36m1\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34mf'HTTP request response {_request_response.status_code}: {_request_response.text}'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_client.py\u001b[0m in \u001b[0;36msend\u001b[1;34m(self, request, stream, auth, allow_redirects, timeout)\u001b[0m\n\u001b[0;32m 1585\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m-> 1586\u001b[1;33m response = await self._send_handling_auth(\n\u001b[0m\u001b[0;32m 1587\u001b[0m \u001b[0mrequest\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_client.py\u001b[0m in \u001b[0;36m_send_handling_auth\u001b[1;34m(self, request, auth, timeout, allow_redirects, history)\u001b[0m\n\u001b[0;32m 1615\u001b[0m \u001b[1;32mwhile\u001b[0m \u001b[1;32mTrue\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m-> 1616\u001b[1;33m response = await self._send_handling_redirects(\n\u001b[0m\u001b[0;32m 1617\u001b[0m \u001b[0mrequest\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_client.py\u001b[0m in \u001b[0;36m_send_handling_redirects\u001b[1;34m(self, request, timeout, allow_redirects, history)\u001b[0m\n\u001b[0;32m 1654\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m-> 1655\u001b[1;33m \u001b[0mresponse\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_send_single_request\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mrequest\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mtimeout\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 1656\u001b[0m \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_client.py\u001b[0m in \u001b[0;36m_send_single_request\u001b[1;34m(self, request, timeout)\u001b[0m\n\u001b[0;32m 1698\u001b[0m \u001b[0mextensions\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m-> 1699\u001b[1;33m \u001b[1;33m)\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mawait\u001b[0m \u001b[0mtransport\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mhandle_async_request\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 1700\u001b[0m \u001b[0mrequest\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mmethod\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mencode\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_transports\\default.py\u001b[0m in \u001b[0;36mhandle_async_request\u001b[1;34m(self, method, url, headers, stream, extensions)\u001b[0m\n\u001b[0;32m 275\u001b[0m \u001b[1;32mwith\u001b[0m \u001b[0mmap_httpcore_exceptions\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 276\u001b[1;33m (\n\u001b[0m\u001b[0;32m 277\u001b[0m \u001b[0mstatus_code\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\contextlib.py\u001b[0m in \u001b[0;36m__exit__\u001b[1;34m(self, type, value, traceback)\u001b[0m\n\u001b[0;32m 130\u001b[0m \u001b[1;32mtry\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 131\u001b[1;33m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mgen\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mthrow\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mtype\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mvalue\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mtraceback\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 132\u001b[0m \u001b[1;32mexcept\u001b[0m \u001b[0mStopIteration\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0mexc\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\httpx\\_transports\\default.py\u001b[0m in \u001b[0;36mmap_httpcore_exceptions\u001b[1;34m()\u001b[0m\n\u001b[0;32m 77\u001b[0m \u001b[0mmessage\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mstr\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mexc\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m---> 78\u001b[1;33m \u001b[1;32mraise\u001b[0m \u001b[0mmapped_exc\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mmessage\u001b[0m\u001b[1;33m)\u001b[0m \u001b[1;32mfrom\u001b[0m \u001b[0mexc\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 79\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;31mReadTimeout\u001b[0m: ", "\nDuring handling of the above exception, another exception occurred:\n", "\u001b[1;31mTimeoutException\u001b[0m Traceback (most recent call last)", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\json_requests.py\u001b[0m in \u001b[0;36msend_json_request\u001b[1;34m(entity, payload, debug)\u001b[0m\n\u001b[0;32m 113\u001b[0m \u001b[0mlogger\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mdebug\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'Send ticket request:{}'\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mformat\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mticket_request\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 114\u001b[1;33m \u001b[0mresponse\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mprofile\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msend_request\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mjson\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mticket_request\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mtimeout\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;36m15.0\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m15.0\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 115\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\Profile.py\u001b[0m in \u001b[0;36msend_request\u001b[1;34m(self, json, timeout)\u001b[0m\n\u001b[0;32m 356\u001b[0m \u001b[1;32mdef\u001b[0m \u001b[0msend_request\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mjson\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mtimeout\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;32mNone\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 357\u001b[1;33m response = self._desktop_session.http_request(url=self.get_url(),\n\u001b[0m\u001b[0;32m 358\u001b[0m \u001b[0mmethod\u001b[0m\u001b[1;33m=\u001b[0m\u001b[1;34m\"POST\"\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\streaming_session\\session.py\u001b[0m in \u001b[0;36mhttp_request\u001b[1;34m(self, url, method, headers, data, params, json, auth, loop, **kwargs)\u001b[0m\n\u001b[0;32m 653\u001b[0m \u001b[0mloop\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_loop\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 654\u001b[1;33m response = loop.run_until_complete(self.http_request_async(url, method, headers, data,\n\u001b[0m\u001b[0;32m 655\u001b[0m params, json, auth, **kwargs))\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\nest_asyncio.py\u001b[0m in \u001b[0;36mrun_until_complete\u001b[1;34m(self, future)\u001b[0m\n\u001b[0;32m 69\u001b[0m 'Event loop stopped before Future completed.')\n\u001b[1;32m---> 70\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0mf\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mresult\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 71\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\asyncio\\futures.py\u001b[0m in \u001b[0;36mresult\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 177\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_exception\u001b[0m \u001b[1;32mis\u001b[0m \u001b[1;32mnot\u001b[0m \u001b[1;32mNone\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 178\u001b[1;33m \u001b[1;32mraise\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_exception\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 179\u001b[0m \u001b[1;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_result\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\asyncio\\tasks.py\u001b[0m in \u001b[0;36m__step\u001b[1;34m(***failed resolving arguments***)\u001b[0m\n\u001b[0;32m 279\u001b[0m \u001b[1;31m# don't have `__iter__` and `__next__` methods.\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 280\u001b[1;33m \u001b[0mresult\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mcoro\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msend\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;32mNone\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 281\u001b[0m \u001b[1;32melse\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\streaming_session\\session.py\u001b[0m in \u001b[0;36mhttp_request_async\u001b[1;34m(self, url, method, headers, data, params, json, closure, auth, loop, **kwargs)\u001b[0m\n\u001b[0;32m 641\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mlog\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;36m1\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34mf'TimeoutException on HTTP request: {t!r}'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 642\u001b[1;33m \u001b[1;32mraise\u001b[0m \u001b[0mhttpx\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mTimeoutException\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34mf'TimeoutException on HTTP request: {t!r}'\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mrequest\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0m_http_request\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 643\u001b[0m \u001b[1;32mexcept\u001b[0m \u001b[0mException\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0me\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;31mTimeoutException\u001b[0m: TimeoutException on HTTP request: ReadTimeout('')", "\nDuring handling of the above exception, another exception occurred:\n", "\u001b[1;31mEikonError\u001b[0m Traceback (most recent call last)", "\u001b[1;32m~\\AppData\\Local\\Temp/ipykernel_9824/2784228984.py\u001b[0m in \u001b[0;36m\u001b[1;34m\u001b[0m\n\u001b[0;32m 1\u001b[0m \u001b[1;31m# matched datasets\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 2\u001b[0m \u001b[1;31m# dividend data\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m----> 3\u001b[1;33m df = ek.get_data(rics,\n\u001b[0m\u001b[0;32m 4\u001b[0m ['TR.DivAnnouncementDate',\n\u001b[0;32m 5\u001b[0m \u001b[1;34m'TR.DivRecordDate'\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\data_grid.py\u001b[0m in \u001b[0;36mget_data\u001b[1;34m(instruments, fields, parameters, field_name, raw_output, debug)\u001b[0m\n\u001b[0;32m 188\u001b[0m \u001b[0mpayload\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;33m{\u001b[0m\u001b[1;34m'requests'\u001b[0m\u001b[1;33m:\u001b[0m \u001b[1;33m[\u001b[0m\u001b[0mpayload\u001b[0m\u001b[1;33m]\u001b[0m\u001b[1;33m}\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 189\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 190\u001b[1;33m \u001b[0mresult\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0meikon\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mjson_requests\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msend_json_request\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0m_endpoint\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mpayload\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mdebug\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mdebug\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 191\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 192\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mresult\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mget\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'responses'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;32mc:\\specprof\\python\\lib\\site-packages\\eikon\\json_requests.py\u001b[0m in \u001b[0;36msend_json_request\u001b[1;34m(entity, payload, debug)\u001b[0m\n\u001b[0;32m 129\u001b[0m \u001b[0merror_msg\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;34mf'HTTP TimeoutException: {timeout_exception}.'\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 130\u001b[0m \u001b[0mlogger\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0merror\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0merror_msg\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 131\u001b[1;33m \u001b[1;32mraise\u001b[0m \u001b[0mEikonError\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;36m408\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0merror_msg\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 132\u001b[0m \u001b[1;32mexcept\u001b[0m \u001b[0mEikonError\u001b[0m \u001b[1;32mas\u001b[0m \u001b[0meikon_err\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 133\u001b[0m \u001b[0mlogger\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0merror\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34mf\"HTTP request failed: {type(eikon_err).__name__}-{eikon_err.message}\"\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", "\u001b[1;31mEikonError\u001b[0m: Error code 408 | HTTP TimeoutException: TimeoutException on HTTP request: ReadTimeout('')." ] } ], "source": [ "# matched datasets (not working at the moment)\n", "# dividend data\n", "df = ek.get_data(rics,\n", " ['TR.DivAnnouncementDate',\n", " 'TR.DivRecordDate',\n", " 'TR.DivUnadjustedGross',\n", " 'TR.DivType',\n", " 'TR.DivPaymentType',\n", " 'TR.DivCurr',\n", " 'TR.DivAnnouncementDate',\n", " 'TR.DivExDate',\n", " 'TR.DivPayDate',\n", " 'TR.DivEventStatus',\n", " 'TR.DivNotes',\n", " 'TR.DividendFrequency',\n", " 'TR.DivSourceOfFunds',\n", " 'TR.CommonName',\n", " 'TR.CompanyIncorpRegion',\n", " 'TR.ISIN',\n", " 'TR.NAICSSector',\n", " 'TR.NAICSIndustryGroup',\n", " 'TR.NAICSIndustryGroupCode',\n", " 'TR.IssuerRating',\n", " 'TR.IssuerRating.Date',\n", " 'TR.Revenue',\n", " 'TR.TotalOperatingExpense',\n", " 'TR.EBIT',\n", " 'TR.EBITDA',\n", " 'TR.NetIncomeBeforeTaxes',\n", " 'TR.NetIncomeAfterTaxes',\n", " 'TR.CashAndSTInvestments',\n", " 'TR.TotalAssetsReported',\n", " 'TR.TotalLiabilities',\n", " 'TR.NetDebt',\n", " 'TR.TotalEquity',\n", " 'TR.CompanyMarketCap',\n", " 'TR.Beta',\n", " 'TR.FreeCashFlow'],\n", " {\n", " \"SDate\":\"2010-01-01\",\"EDate\":\"2022-09-27\",\n", " })[0]\n", "df.to_excel('stoxx_dividends_data.xlsx', sheet_name='sheet1', index=False)\n", "df.head(10)\n", "\n", "\n" ] }, { "cell_type": "code", "execution_count": null, "id": "89ae3642", "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.8.5" }, "varInspector": { "cols": { "lenName": 16, "lenType": 16, "lenVar": 40 }, "kernels_config": { "python": { "delete_cmd_postfix": "", "delete_cmd_prefix": "del ", "library": "var_list.py", "varRefreshCmd": "print(var_dic_list())" }, "r": { "delete_cmd_postfix": ") ", "delete_cmd_prefix": "rm(", "library": "var_list.r", "varRefreshCmd": "cat(var_dic_list()) " } }, "types_to_exclude": [ "module", "function", "builtin_function_or_method", "instance", "_Feature" ], "window_display": false } }, "nbformat": 4, "nbformat_minor": 5 }