[rkward-tracker] [ rkward-Feature Requests-3381036 ] NEEDINFO: setting up proxy info on GNU/Linux with Gnome

SourceForge.net noreply at sourceforge.net
Fri Oct 14 14:25:39 UTC 2011


Feature Requests item #3381036, was opened at 2011-07-28 17:07
Message generated for change (Comment added) made by xavidp
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=459010&aid=3381036&group_id=50231

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Settings / options
Group: None
Status: Open
Priority: 5
Private: No
Submitted By: Xavier de Pedro (xavidp)
Assigned to: Nobody/Anonymous (nobody)
Summary: NEEDINFO: setting up proxy info on GNU/Linux with Gnome

Initial Comment:
Hi all:

I'm using RKward 0.5.6 with R 2.13 for work inside the Gnome 2.x environment on a GNU/Linux machine (Ubuntu 11.04, 64 bits). Our research center is behind a firewall.

When I try to fetch some information from internet with some XML functions, I can't do it thorugh RKWard. Example (between lines of dashes):
--------------------------------------------------
> require(XML)
Loading required package: XML
> u = "http://cran.r-project.org/web/packages/available_packages_by_date.html"
> t = readHTMLTable(u)[[1]]
Error in htmlParse(doc) : 
  error in creating parser for http://cran.r-project.org/web/packages/available_packages_by_date.html
Calls: readHTMLTable -> readHTMLTable -> htmlParse -> .Call
--------------------------------------------------

However, when I run the same lines on a terminal in the same computer, they all run fine (no errors reported for htmlparse).

The computer has already been setup to use the firewall in R on a console, by means of adding this line to /etc/R/Renviron file:

HTTP_PROXY=${HTTP_PROXY="http://conf_www.ir.vhebron.net:8081"}

just above where it says;:
 ### Local Variables: ***

Therefore, I guess that this is some sort of issue of missing proxy information for RKward when on a Gnome-based environment. All other gnome-based programs run fine (prxoy info added everwhere as needed).

I tried adding info for the proxy in systemsettings, so that KDE dialogues for network config are open at the gnome desktop, and setting up there the proxy info, but no way: rkward produces the same error.
 
Konqueror, as a reference, can browse internet, with the proxy info.
But I don't know how to do that with RKWard.

Any idea?

Thanks in advanced

Xavier de Pedro, Ph.D.


----------------------------------------------------------------------

Comment By: Xavier de Pedro (xavidp)
Date: 2011-10-14 16:25

Message:
Hi Thomas, and sorry for the long delay (again) in replying your answer...

You got the solution in your PS message.

When I arrived to this reasearch unit I was told the that syntax to at to
the Renviron file for the proxy was:
HTTP_PROXY=${HTTP_PROXY="http://conf_www.ir.vhebron.net:8081"}

and that syntax seems to work for R sessions in console, and a few other
programs (Rstudio, emacs, etc). But not for RKward or apache, either.

However, with the simpler syntax to set the ennvironment variable as you
suggested, rkward comes back to work, as well as apache, etc.

Thanks for your help!

FYI, with this syntax:
HTTP_PROXY=${HTTP_PROXY="http://conf_www.ir.vhebron.net:8081"}

the output of 

Sys.getenv ("HTTP_PROXY") 

was: 

> Sys.getenv ("HTTP_PROXY")
[1] "${HTTP_PROXY"

and download.file didn't succeed through rkward (but it did succeed
through r console on a terminal).

but when I added your syntax
HTTP_PROXY="http://conf_www.ir.vhebron.net:8081", then 

> Sys.getenv ("HTTP_PROXY")
[1] "http://conf_www.ir.vhebron.net:8081"

So, thanks thomas for your hint!


----------------------------------------------------------------------

Comment By: Thomas Friedrichsmeier (tfry)
Date: 2011-07-29 10:49

Message:
Hi!

Based on the given information, I am not quite convinced this is an issue
with the proxy. Two things to try, first:
1) Try
  download.file
("http://cran.r-project.org/web/packages/available_packages_by_date.html",
"somewhere")
2) What's the output of
  Sys.getenv ("HTTP_PROXY")
? Does it change anything, if you run 
  Sys.setenv (HTTP_PROXY="http://conf_www.ir.vhebron.net:8081")

Also, having the output of 
  rk.sessionInfo()
might be helpful.

Regards
Thomas

P.S.: The line
  HTTP_PROXY=${HTTP_PROXY="http://conf_www.ir.vhebron.net:8081"}
looks strange to me. Shouldn't this be just
  HTTP_PROXY="http://conf_www.ir.vhebron.net:8081"
? Have you tried the command in a plain R session?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=459010&aid=3381036&group_id=50231




More information about the rkward-tracker mailing list