-
Notifications
You must be signed in to change notification settings - Fork 4
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
Error in file(con, "r"): cannot open the connection
for 1 of 42 URLs
#37
Comments
What do you get if you check the URLs with plain |
With R CMD check, I get 0 error, 0 message, and 0 note—same on CRAN. And I see no warning about URLs. |
On a different computer, also on Windows 10 but on an earlier R version and on a different directory, on which I have pulled the latest change, I get the same result: R.version
#> _
#> platform x86_64-w64-mingw32
#> arch x86_64
#> os mingw32
#> crt ucrt
#> system x86_64, mingw32
#> status
#> major 4
#> minor 2.0
#> year 2022
#> month 04
#> day 22
#> svn rev 82229
#> language R
#> version.string R version 4.2.0 (2022-04-22 ucrt)
#> nickname Vigorous Calisthenics
packageVersion("urlchecker")
#> [1] '1.0.1'
urlchecker::url_check("D:/github/rempsyc")
#> fetching [ 0 / 42 ]fetching [ 1 / 42 ]fetching [ 2 / 42 ]fetching [ 3 / 42 ]fetching [ 4 / 42 ]fetching [ 5 / 42 ]fetching [ 6 / 42 ]fetching [ 7 / 42 ]fetching [ 8 / 42 ]fetching [ 9 / 42 ]fetching [ 10 / 42 ]fetching [ 11 / 42 ]fetching [ 12 / 42 ]fetching [ 13 / 42 ]fetching [ 14 / 42 ]fetching [ 15 / 42 ]fetching [ 16 / 42 ]fetching [ 17 / 42 ]fetching [ 18 / 42 ]fetching [ 19 / 42 ]fetching [ 20 / 42 ]fetching [ 21 / 42 ]fetching [ 22 / 42 ]fetching [ 23 / 42 ]fetching [ 24 / 42 ]fetching [ 25 / 42 ]fetching [ 26 / 42 ]fetching [ 27 / 42 ]fetching [ 28 / 42 ]fetching [ 29 / 42 ]fetching [ 30 / 42 ]fetching [ 31 / 42 ]fetching [ 32 / 42 ]fetching [ 33 / 42 ]fetching [ 34 / 42 ]fetching [ 35 / 42 ]fetching [ 36 / 42 ]fetching [ 37 / 42 ]fetching [ 38 / 42 ]fetching [ 39 / 42 ]fetching [ 40 / 42 ]fetching [ 41 / 42 ]
#> Warning in file(con, "r"): cannot open file
#> 'D:\github\rempsyc/D:/github/rempsyc/vignettes/assumptions.Rmd': Invalid
#> argument
#> Error in file(con, "r"): cannot open the connection Created on 2023-10-10 with reprex v2.0.2 Perhaps there is something wrong with the vignette? Perhaps you can try to replicate the issue with the following? usethis::create_from_github("rempsyc/rempsyc")
urlchecker::url_check() |
Does |
urlchecker checks the same URLs as |
|
I see, thanks. I usually just use Using |
This is how to check it with
|
Btw. is this reproducible? Do you also see it if you run |
Yes, it is reproducible. In my reprex, I had to specify the path for it to work, but when testing internally I don't use path (so ran from the package directory itself, without arguments) and get the same result. For running
|
Do you also see it if you run urlchecker::url_check() from the package directory itself, without arguments? |
As I said in my previous answer,
And as I said in a previous answer, I encourage you to try to replicate it yourself, here are the steps again:
Btw even running |
I tried, cannot reproduce it myself.
EDIT: actually, maybe |
Ok thanks for the clarification! It worked with I thought this would be replicable since I get the same thing on two different Windows 10 computers... Are you on Windows 10 as well? Because I just literally deleted the whole repo, used |
Not a big deal though, not sure if it's worth spending more time on this bug, I just wanted to report it, but feel free to close this issue if it's too much trouble... |
You can put a dummy bad URL into |
Are you saying that In any case, |
Came across this issue is well. This also happens for me for URLs in a vignette file. I direct everyone to the OP:
For some reason, the path in the
So I believe this causes an error downstream, maybe due to |
I experience the following error:
Reprex:
Created on 2023-10-09 with reprex v2.0.2
It seems for the 42 URL/file, the working directory is being appended to the URL. Any idea for a solution?
The text was updated successfully, but these errors were encountered: