r-lib / devtools

Tools to make an R developer's life easier
https://devtools.r-lib.org
Other
2.4k stars 758 forks source link

Failed to install 'unknown package' from Bitbucket #2118

Closed bjornol closed 5 years ago

bjornol commented 5 years ago

HI Im on a windows devtools version 2.2.0 and im having trouble installing from private bitbucket repo. I get current error message:

devtools::install_bitbucket("dummy/url", auth_user="user", password="password")

Failed to install 'unknown package' from Bitbucket: cannot open URL cannot open URL 'https://api.bitbucket.org/2.0/repositories/dummy/url/src/master/DESCRIPTION'

Its working on my ubuntu machine

Anyone having the same issue?

jimhester commented 5 years ago

You may want to install the devel version of the remotes package, there have been some community fixes in regards to bitbucket that may solve this issue.

devtools::install_dev("remotes")
bjornol commented 5 years ago

No change. Still get the same error.

lounsburynw commented 5 years ago

I am also having the same issue

bjornol commented 4 years ago

Why is this an issue still. Just updated one of my old servers with devtools and suddenly I get this error message again. Now what. Can’t install my private packages again. This is quite irritating

gabriben commented 4 years ago

same problem here :(

karelfiser commented 4 years ago

Same problem (Ubuntu 20.04, R version 4.0.2 (2020-06-22), devtools_2.3.0).

zero1025998080 commented 4 years ago

Same in R 3.6.3 with package devtools 2.3.0, I also tried R 4.0.2 before, which only caused more problems.

bguillod commented 4 years ago

Same here, building a docker image which installs a private package from bitbucket fails although it used to work. Very irritating indeed. Could it be some system dependencies were updated and create issue with devtools?

fdrennan commented 3 years ago

same here

Sam-cdd commented 3 years ago

Same problem

zero1025998080 commented 3 years ago

I don't remeber what is the specific problem when I come here for help then, but I did solve it. I tried to download a package called "maucantor/unodf" from Bitbucket that time, and it was my first and only time download packages from Bitbucket. I tried this in Rstudio (R 3.6.1: remotes:::download_method() options(download.file.method = "libcurl") library(devtools) install_bitbucket("maucantor/unodf") And also there is a problem on the code of the function in this package, so I collect it (≠ → !=). Hope this could help.

Micksusername commented 2 years ago

Same issue guys and can't find a solution anywhere!! Please....somebody!!!

saberpowers commented 2 years ago

I am also currently blocked by this issue.

harell commented 2 years ago

@jimhester this is still an open issue on R4.1.3 remotes v2.4.2. Could you please advise?

I'm trying to install a package on a public Bitbucket repo. This gives the following error

install_bitbucket('annalectnz/rianna')
> Error: Failed to install 'unknown package' from Bitbucket:
  cannot open URL 'https://api.bitbucket.org/2.0/repositories/annalectnz/rianna/src/HEAD/DESCRIPTION'

However, when I paste the URL address to Chrome, I can see the DESCRIPTION file content

jennybc commented 2 years ago

install_bitbucket() is implemented in the remotes package:

https://github.com/r-lib/devtools/blob/6e30ec244508ac76fbe63d661fefa2925f5eb584/R/remotes.R#L46

Also comments on old issues are often not seen.

jonkatz2 commented 2 years ago

I installed a package from a private repo using install_bitbucket() today. The remotes::install_bitbucket() help page has this blurb:

Then store your password in the environment variable BITBUCKET_PASSWORD (e.g. evelynwaugh:swordofhonour) 

I thought this meant username:password, but that did not work for me. What worked for me was to set my username and (app) password separately:

Sys.setenv(BITBUCKET_USER='jonkatz')
Sys.setenv(BITBUCKET_PASSWORD='XxXxXxXxXxXxXxX')
install_bitbucket("gsilver/coio")

Another stumble was that to look up my username I had to view my Personal Settings and look for it under Bitbucket Profile Settings, not Account Settings.

harell commented 2 years ago

I installed a package from a private repo using install_bitbucket() today. The remotes::install_bitbucket() help page has this blurb:

Then store your password in the environment variable BITBUCKET_PASSWORD (e.g. evelynwaugh:swordofhonour) 

I thought this meant username:password, but that did not work for me. What worked for me was to set my username and (app) password separately:

Sys.setenv(BITBUCKET_USER='jonkatz')
Sys.setenv(BITBUCKET_PASSWORD='XxXxXxXxXxXxXxX')
install_bitbucket("gsilver/coio")

Another stumble was that to look up my username I had to view my Personal Settings and look for it under Bitbucket Profile Settings, not Account Settings.

@jonkatz2 Please move this issue to https://github.com/r-lib/remotes/issues/703

aakashparulekar commented 2 years ago

Hey guys, what worked for me was going into Bitbucket and setting an App password. Use the App password as the password argument for install_bitbucket. Works for any Sourcetree issues as well

eliauk07yz commented 3 months ago

HI Im on a windows devtools version 2.2.0 and im having trouble installing from private bitbucket repo. I get current error message:

devtools::install_bitbucket("dummy/url", auth_user="user", password="password")

Failed to install 'unknown package' from Bitbucket: cannot open URL cannot open URL 'https://api.bitbucket.org/2.0/repositories/dummy/url/src/master/DESCRIPTION'

Its working on my ubuntu machine

Anyone having the same issue?

Hi: I also meet this problem,can you tell me how to solve it?