Upgrade from Eikon -> Workspace. Learn about programming differences.

For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
1 1 3 4

Error in print.default("HTTP Error, code= ", response$status_code, sep = "") : invalid printing digits 503 - EIKON API, R

Hi,


I am getting the below error when I try to connect Eikon API using R.

Error in print.default("HTTP Error, code= ", response$status_code, sep = "") :

invalid printing digits 503

Can someone please help me?


Thanks,

Sree

eikonrefinitiv-dataplatform-eikonworkspaceworkspace-data-apireikon-data-api-r
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
78.1k 246 52 72

@sreedhanya.kavunkara

It was unable to connect to http://localhost:9000/api/v1/data on the machine to retrieve the data.

It may relate to the proxy settings on your machine.

Generated Thu, 23 Sep 2021 05:11:13 GMT by c750egs.int.thomsonreuters.com (squid)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
14k 30 5 10

hello @sreedhanya.kavunkara ,

Could you share the code that causes the issue? and Eikon API version are you using?

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
1 1 3 4

Hi,

The error I am getting is while calling the function.

Temp_Data = get_data(as.list(Temp_RICs), Column_List)

Rics and columns I am inputting as variables.


Sree

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@sreedhanya.kavunkara

You can set the debug argument to TRUE to verify a retrieved response.

get_data(list("IBM", "GOOG.O", "MSFT.O"), list("TR.PriceClose", "TR.Volume", "TR.PriceLow"),debug=TRUE)
Upvotes
1 1 3 4

Hi,

Here is the response for the command given. (get_data(list("IBM", "GOOG.O", "MSFT.O"), list("TR.PriceClose", "TR.Volume", "TR.PriceLow"),debug=TRUE))


No encoding supplied: defaulting to UTF-8.

[1] "Request *************************************"

{"Entity":{"E":["DataGrid"],"W":{"instruments":[["IBM"],["GOOG.O"],["MSFT.O"]],"fields":[{"name":["TR.PriceClose"]},{"name":["TR.Volume"]},{"name":["TR.PriceLow"]}]}}}

[1] "Response *************************************"

[1] "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd">; <html><head> <meta http-equiv=\"Content-Type\" CONTENT=\"text/html; charset=utf-8\"> <title>ERROR: The requested URL could not be retrieved</title> <style type=\"text/css\"><!-- /*\n Stylesheet for Squid Error pages\n Adapted from design by Free CSS Templates\n http://www.freecsstemplates.org\n Released for free under a Creative Commons Attribution 2.5 License\n*/\n\n/* Page basics */\n* {\n\tfont-family: verdana, sans-serif;\n}\n\nhtml body {\n\tmargin: 0;\n\tpadding: 0;\n\tbackground: #efefef;\n\tfont-size: 12px;\n\tcolor: #1e1e1e;\n}\n\n/* Page displayed title area */\n#titles {\n\tmargin-left: 15px;\n\tpadding: 10px;\n\tpadding-left: 100px;\n\tbackground: url('http://www.squid-cache.org/Artwork/SN.png') no-repeat left;\n}\n\n/* initial title */\n#titles h1 {\n\tcolor: #000000;\n}\n#titles h2 {\n\tcolor: #000000;\n}\n\n/* special event: FTP success page titles */\n#titles ftpsuccess {\n\tbackground-color:#00ff00;\n\twidth:100%;\n}\n\n/* Page displayed body content area */\n#content {\n\tpadding: 10px;\n\tbackground: #ffffff;\n}\n\n/* General text */\np {\n}\n\n/* error brief description */\n#error p {\n}\n\n/* some data which may have caused the problem */\n#data {\n}\n\n/* the error message received from the system or other software */\n#sysmsg {\n}\n\npre {\n font-family:sans-serif;\n}\n\n/* special event: FTP / Gopher directory listing */\n#dirmsg {\n font-family: courier;\n color: black;\n font-size: 10pt;\n}\n#dirlisting {\n margin-left: 2%;\n margin-right: 2%;\n}\n#dirlisting tr.entry td.icon,td.filename,td.size,td.date {\n border-bottom: groove;\n}\n#dirlisting td.size {\n width: 50px;\n text-align: right;\n padding-right: 5px;\n}\n\n/* horizontal lines */\nhr {\n\tmargin: 0;\n}\n\n/* page displayed footer area */\n#footer {\n\tfont-size: 9px;\n\tpadding-left: 10px;\n}\n body :lang(fa) { direction: rtl; font-size: 100%; font-family: Tahoma, Roya, sans-serif; float: right; } :lang(he) { direction: rtl; } --></style> </head><body id=ERR_CONNECT_FAIL> <div id=\"titles\"> <h1>ERROR</h1> <h2>The requested URL could not be retrieved</h2> </div> <hr> <div id=\"content\"> <p>The following error was encountered while trying to retrieve the URL: <a href=\"http://localhost:9000/api/v1/data\">http://localhost:9000/api/v1/data</a></p> <blockquote id=\"error\"> <p><b>Connection to localhost failed.</b></p> </blockquote> <p id=\"sysmsg\">The system returned: <i>(101) Network is unreachable</i></p> <p>The remote host or network may be down. Please try the request again.</p> <p>Your cache administrator is <a href=\"mailto:root?subject=CacheErrorInfo%20-%20ERR_CONNECT_FAIL&amp;body=CacheHost%3A%20c750egs.int.thomsonreuters.com%0D%0AErrPage%3A%20ERR_CONNECT_FAIL%0D%0AErr%3A%20(101)%20Network%20is%20unreachable%0D%0ATimeStamp%3A%20Thu,%2023%20Sep%202021%2005%3A11%3A13%20GMT%0D%0A%0D%0AClientIP%3A%2010.241.8.41%0D%0AServerIP%3A%20localhost%0D%0A%0D%0AHTTP%20Request%3A%0D%0APOST%20%2Fapi%2Fv1%2Fdata%20HTTP%2F1.1%0AHost%3A%20localhost%3A9000%0D%0AUser-Agent%3A%20libcurl%2F7.64.1%20r-curl%2F4.3.2%20httr%2F1.4.2%0D%0AAccept-Encoding%3A%20deflate,%20gzip%0D%0AProxy-Connection%3A%20Keep-Alive%0D%0AAccept%3A%20application%2Fjson,%20text%2Fxml,%20application%2Fxml,%20*%2F*%0D%0AContent-Type%3A%20application%2Fjson%0D%0Ax-tr-applicationid%3A%209cc9de03cd124761a6ad0d92d3838b12e883e788%0D%0AContent-Length%3A%20153%0D%0A%0D%0A%0D%0A\">root</a>.</p> <br> </div> <hr> <div id=\"footer\"> <p>Generated Thu, 23 Sep 2021 05:11:13 GMT by c750egs.int.thomsonreuters.com (squid)</p> <!-- ERR_CONNECT_FAIL --> </div> </body></html> "

[1] "Response status *************************************"

[1] 503

Error in print.default("HTTP Error, code= ", response$status_code, sep = "") :

invalid printing digits 503


Thansk,

Sree

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
1 1 3 4

Hi @jirapongse.phuriphanvichai

Can you please let me how to change the proxy in R. I tried a couple of ways, didn't work.


Thanks,

Sree

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
78.1k 246 52 72

@sreedhanya.kavunkara

I used the ~/.Renviron file as mentioned on this page.

However, when connecting to the localhost, a proxy shouldn't be used.

How did you configure your machine to use this proxy: c750egs.int.thomsonreuters.com?


icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.