-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NLOpt no longer installing #40
Comments
Thank you for the notification. The most recent version of nloptr on github
no longer depends on the external download, so you may want to try
installing nloptr from github.
…On Saturday, October 7, 2017, Ganesh Krishnan ***@***.***> wrote:
Installation of nloptr is failing on Ubuntu (and probably other
platforms), because the NLOpt package has moved permanently.
Note the curl -I output below:
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
HTTP/1.1 301 Moved Permanently
Date: Sat, 07 Oct 2017 03:06:45 GMT
Server: Apache/2.4.10 (Debian)
Location: https://github.com/stevengj/nlopt/releases/download/nlopt-2.4.2/nlopt-2.4.2.tar.gz
Content-Type <https://github.com/stevengj/nlopt/releases/download/nlopt-2.4.2/nlopt-2.4.2.tar.gzContent-Type>: text/html; charset=iso-8859-1
This can be fixed by changing the URL at this line
<https://github.com/jyypma/nloptr/blob/c4e0fb4a54ffc21c2a4cf4bb5741d8f9ce43e05c/src/Makevars.in#L120>
:
Alternatively, you can add the method="curl" and extra=-L options to
download.files to fix this. If you do that line 120 in the above file
will read:
${R_HOME}/bin/Rscript" --vanilla -e "download.file(
url='http://ab-initio.mit.edu/nlopt/nlopt-${NLOPT_VERSION}.tar.gz',
destfile='nlopt-${NLOPT_VERSION}.tar.gz',
method='curl', extra='-L')
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#40>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAD7R1xOZLiX1mzDAXTFMfhm4jsHMks5spuv0gaJpZM4PxNoH>
.
|
Here is another solution, which works with the nloptr version that is on
CRAN. To prevent nloptr from trying to download NLopt, you can install
the NLopt
library before install the nloptr package.
During the configuration of nloptr, it checks whether NLopt is already
installed. If NLopt is already installed, then nloptr links to the
existing library.
You can install NLopt on Ubuntu with:
… sudo apt-get install libnlopt-dev
On 7 Oct 2017 07:52, "Jelmer Ypma" ***@***.***> wrote:
Thank you for the notification. The most recent version of nloptr on
github no longer depends on the external download, so you may want to try
installing nloptr from github.
On Saturday, October 7, 2017, Ganesh Krishnan ***@***.***>
wrote:
> Installation of nloptr is failing on Ubuntu (and probably other
> platforms), because the NLOpt package has moved permanently.
>
> Note the curl -I output below:
>
> % Total % Received % Xferd Average Speed Time Time Time Current
> Dload Upload Total Spent Left Speed
> 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
> HTTP/1.1 301 Moved Permanently
> Date: Sat, 07 Oct 2017 03:06:45 GMT
> Server: Apache/2.4.10 (Debian)
> Location: https://github.com/stevengj/nlopt/releases/download/nlopt-2.4.2/nlopt-2.4.2.tar.gz
> Content-Type <https://github.com/stevengj/nlopt/releases/download/nlopt-2.4.2/nlopt-2.4.2.tar.gzContent-Type>: text/html; charset=iso-8859-1
>
> This can be fixed by changing the URL at this line
> <https://github.com/jyypma/nloptr/blob/c4e0fb4a54ffc21c2a4cf4bb5741d8f9ce43e05c/src/Makevars.in#L120>
> :
>
> Alternatively, you can add the method="curl" and extra=-L options to
> download.files to fix this. If you do that line 120 in the above file
> will read:
>
> ${R_HOME}/bin/Rscript" --vanilla -e "download.file(
> url='http://ab-initio.mit.edu/nlopt/nlopt-${NLOPT_VERSION}.tar.gz',
> destfile='nlopt-${NLOPT_VERSION}.tar.gz',
> method='curl', extra='-L')
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <#40>, or mute the thread
> <https://github.com/notifications/unsubscribe-auth/ADlPAD7R1xOZLiX1mzDAXTFMfhm4jsHMks5spuv0gaJpZM4PxNoH>
> .
>
|
@jyypma Thanks. I have continuous deployment scenario, which I've got working for now by forking the repo and using the Feel free to close the issue. Just wanted to file an issue, because this took me a good 3-4 hours to figure out (mainly because of the continuous deployment scenario), so wanted any others facing this issue to be able to get to a solution quickly. |
While trying to download nloptr in R version 3.3.3, I get the following error: Warning in download.file(url = "http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz", : Error in download.file(url = "http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz", : gzip: stdin: unexpected end of file Any assistance would be highly appreciated. |
On Ubuntu, you do not need to rely on the external library: ~> dpkg -l | grep nlopt # ie nlopt from Ubuntu
ii libnlopt-dev 2.4.2+dfsg-2bu amd64 nonlinear optimization library -- developmen
ii libnlopt0:amd64 2.4.2+dfsg-2bu amd64 nonlinear optimization library
~> install.r nloptr # install.r is a helper from littler
trying URL 'https://cran.rstudio.com/src/contrib/nloptr_1.0.4.tar.gz'
Content type 'application/x-gzip' length 353957 bytes (345 KB)
==================================================
downloaded 345 KB
* installing *source* package ‘nloptr’ ...
** package ‘nloptr’ successfully unpacked and MD5 sums checked
checking for g++... g++
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking how to run the C++ preprocessor... g++ -E
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether g++ accepts -g... (cached) yes
checking for pkg-config... yes
configure: Now testing for NLopt header file.
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking nlopt.h usability... yes
checking nlopt.h presence... yes
checking for nlopt.h... yes
configure: Suitable NLopt library found.
configure: creating ./config.status
config.status: creating src/Makevars
** libs
ccache g++ -I/usr/share/R/include -DNDEBUG -fpic -g -O3 -Wall -pipe -Wno-unused -march=native -c dummy.cpp -o dummy.o
ccache gcc -I/usr/share/R/include -DNDEBUG -fpic -g -O3 -Wall -pipe -Wno-unused -std=gnu99 -march=native -c nloptr.c -o nloptr.o
ccache g++ -Wl,-S -shared -L/usr/lib/R/lib -Wl,-Bsymbolic-functions -Wl,-z,relro -o nloptr.so dummy.o nloptr.o -lnlopt -lm -L/usr/lib/R/lib -lR
installing to /usr/local/lib/R/site-library/nloptr/libs
** R
** inst
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
* DONE (nloptr)
The downloaded source packages are in
‘/tmp/downloaded_packages’
~> Fast, easy, reliable. |
Hi Dirk, Thanks for your response.. what version of R did you use when trying to install nloptr_1.0.4.tar.gz?Sorry, if I missed those details in your post.. |
Please ignore my previous comments.. Thanks a ton! |
Hi Jyympma and Steven GJ (authors of nloptr and nlopt).. Would the new version of "nloptr" be then called "nlopt"? How would this name change impact the downstream packages. What changes to the installation downstream packages need to be made to account for the name change? |
You. Misunderstand. How. This. Works.
|
Thanks, Dirk, for the clarifications! :) |
Note the above instructions will work on ubuntu but require pkg-config to be installed |
this issue is causing downstream problems in other packages that depend on |
Please clarify what "this" is. A package not installing will by definition cause problem for its dependencies. |
sorry for the obvious statement |
Ok, can you clarify what in particular happens to ggeffects? I am still confused what particular aspect you are trying to stress. I am probably just extra-dense. Monday and all... |
|
Sure. R> library(tools)
R> db <- CRAN_package_db()
R> revdeps <- package_dependencies("nloptr", db=db, recursive=TRUE, reverse=TRUE)
R> length(revdeps[[1]])
[1] 507
R> |
If there is a problem with downstream dependencies, shouldn't this be recognized by CRAN? The check results are all ok: https://cran.r-project.org/web/checks/check_results_ggeffects.html |
…ht be as in: topepo/caret#640 further reference is astamm/nloptr#40
Is there really no fix for this? I am still facing this issue. I mean I just try to install a package and have no idea why I need to understand how I will get 403
|
I will try to submit the development version to CRAN this weekend.
…On Fri, 20 Apr 2018, 07:38 Sam Xiao, ***@***.***> wrote:
Is there really no fix for this? I am still facing this issue.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAB0UNp91zq46NJgU_Vbp3MwyRKrnks5tqXRggaJpZM4PxNoH>
.
|
Awesome! Thanks! |
Hi,
I noticed many package developers including noted developers like Hadley
Wickham are using their github accounts, outside of CRAN, for making
revisions to a package.
Is there a reason for not using CRAN's github account? My apologies if it's
a trivial question. The reason for asking is my team is having a hard time
keeping track of package dependencies that are outside of CRAN (cloud and
github) and installation of packages with dependencies; and many times the
installation of some packages fail as some packages are not found at
expected the Cran/r-forge/bioconductor locations..
Would truly appreciate your ideas /suggestions in successfully installing
and managing packages with dependencies..
Thanks
Pitla
…On Thu, Apr 19, 2018, 11:33 PM Sam Xiao ***@***.***> wrote:
@jyypma <https://github.com/jyypma>
Awesome! Thanks!
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AfI6v50TXu1vZ8kcjjJcZEzTGiNbKEtAks5tqYEygaJpZM4PxNoH>
.
|
Wrong place for the question. Try the r-package-devel list. |
@jyypma Any update on this? |
All checks pass on win-builder and on debian and solaris via r-hub. Mac OS
cannot build the package on r-hub and I don't know whether this is specific
to r-hub or not. Any ideas?
The reverse dependency check has not finished yet.
…On Mon, 23 Apr 2018, 08:25 Sam Xiao, ***@***.***> wrote:
@jyypma <https://github.com/jyypma> Any update on this?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAI-rGNXurOn-KyDvuGovcLEl96hyks5trXPogaJpZM4PxNoH>
.
|
@jyypma Thanks! Mind to share the fix? So we can help test it out? We are on Ubuntu/Debian Linux on AWS if that helps. |
The latest development version on GitHub should fix this.
…On Mon, Apr 23, 2018 at 9:28 PM, Sam Xiao ***@***.***> wrote:
@jyypma <https://github.com/jyypma> Thanks! Mind to share the fix? So we
can help test it out? We are on Ubuntu/Debian Linux on AWS if that helps.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAALo9VeEyXRdzPn4YYcv5nImEFQKks5tritqgaJpZM4PxNoH>
.
|
I don't think it works
|
You used
because you missed the part where Jelmer clearly stated
|
@eddelbuettel Thanks for pointing that out. I just follow this line to install it:
Am I missing something? (I am very new to R and helping my team to fix this issue.) |
See my October 9, 2017, comment above. "Works for me" but then I also take care of things by making sure the underlying nlopt library is installed and can be used for development (ie |
@eddelbuettel |
Ahh. I know why it doesn't work for me. Because I have transitive dependency. Why can't we just publish the latest development code here to CRAN ? |
No, each package is independent. I urge to calm down, not send a message every few minutes but maybe re-read this ticket as well as other that may have gotten closed. They all contain information. Jelmer did fix this by embedding the sources. If you end up attempting (and failing) an nlopt downloading then ... you appear to be doing something wrong. |
@eddelbuettel Sorry about the message earlier. I am not sure whether there's a better way to communicate this. AFAIK, package |
Your suite of messages is really of somewhat sub-standard quality. Read eg something like this for SO. So far you told us numerous times that things fail for you, often copying the same (basically irrelevant) lengthy error message. What you have not done is saying:
To repeat what I said many times before, what I do (based on something we added to nloptr years ago) is
Please note the
(I use (And no, one does not "just upload to CRAN".) Hth. |
And for completes, when installing from here rather than CRAN I see
and we now have three files compiled
but it succeeds of course the same way. |
Thanks! @eddelbuettel You are right, I cannot treat this Github issue page as an IM. I am using Ubuntu/Debian Linux:
Install Thanks, |
I am experiencing an issue which I believe is similar to others reported here: installation of
There is a previous report of this problem on the As of the current master commit, it looks like Should the download link be updated to point directly to the GitHub download link? Or should the uptime of http://ab-initio.mit.edu be improved? I'm not experienced enough with the R packaging ecosystem to sure which answer is right. I'll also cross-post this question on the |
The code you are referring to (in src/Makeveras.in L120) is commented out.
The current master version on GitHub does not download the NLopt code. If
NLopt is not yet installed on your system, upon configuration, nloptr will
try to build NLopt from the NLopt source code which is included in
src/nlopt_src. Hope this helps.
…On Thu, 20 Sep 2018, 09:36 Josh Rosen, ***@***.***> wrote:
I am experiencing an issue which I believe is similar to others reported
here: installation of nloptr is hanging indefinitely because the server
hosting http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz is down.
Specifically, I see the following error message in my build, followed by an
indefinite hang:
configure: Need to download and build NLopt
trying URL 'http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz'
Error in download.file(url = "http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz", :
cannot open URL 'http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz'
In addition: Warning message:
In download.file(url = "http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz", :
URL 'http://ab-initio.mit.edu/nlopt/nlopt-2.4.2.tar.gz': status was 'Couldn't connect to server'
Execution halted
Error in file(con, "rb") : cannot open the connection
Calls: untar -> readBin -> file
In addition: Warning message:
In file(con, "rb") :
cannot open file 'nlopt-2.4.2.tar.gz': No such file or directory
Execution halted
configure: Starting to install library to /tmp/RtmpspySgn/R.INSTALL3a747896656d/nloptr/nlopt-2.4.2
./configure: line 3325: cd: nlopt-2.4.2: No such file or directory
./configure: line 3325: ed: command not found
./configure: line 3327: ed: command not found
./configure: line 3331: ed: command not found
There is a previous report of this problem on the nlopt repository at
stevengj/nlopt#119 <stevengj/nlopt#119>, where
@stevengj <https://github.com/stevengj> suggested filing an issue against
nloptr to update the download link to point to GItHub downloads at
https://github.com/stevengj/nlopt/releases/download/nlopt-2.4.2/nlopt-2.4.2.tar.gz
instead of the old MIT link.
As of the current master commit, it looks like nloptr is still using the
old download link:
https://github.com/jyypma/nloptr/blob/8d5f62a1d2e2db8c62810f8462cc7fe72de8945c/src/Makevars.in#L120
Should the download link be updated to point directly to the GitHub
download link? Or should the uptime of http://ab-initio.mit.edu be
improved? I'm not experienced enough with the R packaging ecosystem to sure
which answer is right. I'll also cross-post this question on the nlopt
issue.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAMZ7idbbeWdF5v9da3Kzsw30_ctJks5uc0VogaJpZM4PxNoH>
.
|
Thank you for the clarification! Are there plans to publish an updated version to CRAN? It looks like the latest version available there (1.0.4) was published on 2017-08-22 and does not include the bundled nlopt sources. If there are factors which would delay a larger feature release (such as additional testing requirements), would it be possible to publish a minor 1.0.5 release whose only change is to update the download URL with everything else remaining unchanged? That seems like it would be a quick and surgical fix for this download flakiness issue (which appears to be impacting multiple users based on the linked GitHub issues). |
To be clear, I'm no longer personally blocked by this issue (since I just installed |
@jyypma Can you detail what is holding |
In submission 1.2.0 I made some changes to `configure.ac` to try and
address a request by CRAN. This change resulted in NOTEs in two downward
dependencies (packages `minimaxdesign` and `qle`). I did not catch this,
because I run my reverse dependencies on Windows. I have updated my virtual
machine with Ubuntu in order to be able find out where the error is coming
from and how to fix this and then make a new submission. This may take a
while, so any help would be appreciated.
More information on the change in downward dependency behaviour is below.
My current guess is that the `PKG_LIBS` that are defined in the [Makevars
file](https://github.com/cran/qle/blob/master/src/Makevars) of the `qle`
package are not correctly picked up, overwritten, etc. by the definition of
`PKG_LIBS` in `configure` from `nloptr`, but my knowledge on how macros
interact between packages (should I expect them to interact at all?) is
very limited at the moment.
Package: minimaxdesign
Check: use of SHLIB_OPENMP_*FLAGS in Makefiles
New result: NOTE
src/Makevars: SHLIB_OPENMP_CXXFLAGS is included in PKG_CXXFLAGS but not
in PKG_LIBS
src/Makevars: SHLIB_OPENMP_CFLAGS is included in PKG_LIBS but not in
PKG_CFLAGS
Use of these macros is discussed in sect 1.2.1.1 of ‘Writing R
Extensions’. The macros for different languages may differ so the
matching macro must be used in PKG_CXXFLAGS (etc) and match that used
in PKG_LIBS (except for F77: see the manual).
Package: qle
Check: use of SHLIB_OPENMP_*FLAGS in Makefiles
New result: NOTE
src/Makevars: SHLIB_OPENMP_CFLAGS is included in PKG_LIBS but not in
PKG_CFLAGS
Use of these macros is discussed in sect 1.2.1.1 of ‘Writing R
Extensions’. The macros for different languages may differ so the
matching macro must be used in PKG_CXXFLAGS (etc) and match that used
in PKG_LIBS (except for F77: see the manual).
…On Thu, Sep 20, 2018 at 1:21 PM Dirk Eddelbuettel ***@***.***> wrote:
@jyypma <https://github.com/jyypma> Can you detail what is holding nloptr
up at CRAN? Version 1.2.0 has been sitting in incoming for several weeks
now. Is anything happening? Can we help? Should we place it another (eg
drat-based) repo?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAFcSd68N8DavTXAFHcjos2M1N-Dbks5uc3o4gaJpZM4PxNoH>
.
|
Gosh, I should have asked you earlier. That is a copy and paste issue introduced by us in the example from RcppArmadillo that everybody copies. This has nothing to do with you. See this file from
It is two years old, and the values are static and not influenced at all by whatever you do. And that is the error: Are you sure there is nothing else going on? |
Many thanks for your reply, that explains a lot.
As noted in the submission notes, the nloptr update causes a downstream
ERROR in the package ROI.plugin.nloptr. When I contacted the maintainer of
this package, he mentioned that he would prepare an update once the new
nloptr version is on CRAN.
Package: ROI.plugin.nloptr
Check: examples
New result: ERROR
Running examples in ‘ROI.plugin.nloptr-Ex.R’ failed
Also, there is a NOTE similar to the ones for qle and minimaxdesign in
seqHMM, but I'm assuming that this is not an issue given your previous
comment.
Package: seqHMM
Check: use of SHLIB_OPENMP_*FLAGS in Makefiles
New result: NOTE
src/Makevars: SHLIB_OPENMP_CXXFLAGS is included in PKG_CXXFLAGS but not
in PKG_LIBS
src/Makevars: SHLIB_OPENMP_CFLAGS is included in PKG_LIBS but not in
PKG_CFLAGS
Use of these macros is discussed in sect 1.2.1.1 of ‘Writing R
Extensions’. The macros for different languages may differ so the
matching macro must be used in PKG_CXXFLAGS (etc) and match that used
in PKG_LIBS (except for F77: see the manual).
…On Thu, Sep 20, 2018 at 10:15 PM Dirk Eddelbuettel ***@***.***> wrote:
Gosh, I should have asked you earlier. That is a *copy and paste* issue
introduced by us in the example from RcppArmadillo that everybody copies.
This has nothing to do with you.
See this file from minimaxdesign
<https://github.com/cran/minimaxdesign/blob/master/src/Makevars>:
PKG_CXXFLAGS = $(SHLIB_OPENMP_CXXFLAGS)
PKG_LIBS = $(SHLIB_OPENMP_CFLAGS)
It is two years old, and the values are *static* and not influenced at
all by whatever you do. And that is the error: SHLIB_OPENMP_CXXFLAGS in
one line, but SHLIB_OPENMP_CFLAGS in another. While I have never seen the
actual value differ, CRAN now barks. No more, no less.
Are you sure there is nothing else going on?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#40 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADlPAPtcuNXZ8f9VJFG4WAvvA0wE8IsBks5uc_dJgaJpZM4PxNoH>
.
|
I also had problems installing lme4 in Ubuntu 16.04 and R version 3.4.4 (2018-03-15) b/c nloptr failed to install. I used
which @eddelbuettel suggested, followed by
from @xbeta then installed lme4. The original error message follows:
|
Does someone try to install it on mac? |
We just released v2.0.0. It should work on all platforms. The only platform where a download is still needed is |
Installation of nloptr is failing on Ubuntu (and probably other platforms), because the NLOpt package has moved permanently.
Note the
curl -I
output below:This can be fixed by changing the URL at this line:
Alternatively, you can add the
method="curl"
andextra=-L
options todownload.files
to fix this. If you do that line 120 in the above file will read:The text was updated successfully, but these errors were encountered: