Skip to content
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

Use BinDeps.download_cmd for Windows. #81

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

EricForgy
Copy link

@EricForgy EricForgy commented Jul 14, 2016

This PR assumes a folder called cache exists. Will this cause problems?

It also leaves .gz files in the cache folder. Suggestions welcome 😅

Closes #80

@tkelman
Copy link
Contributor

tkelman commented Jul 14, 2016

this does lose the retrying which is a bit unfortunate, could that be kept?

@EricForgy
Copy link
Author

How does that look?

@@ -43,22 +43,13 @@ function __init__()
end

@unix_only download(source::AbstractString) = (x=HTTPC.get(source); (bytestring(x.body),x.http_code))
@windows_only function download(source::AbstractString; retry = 5)
dest = Array(UInt16,261)
@windows_only function download(source::AbstractString, retry = 5)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

retry was a keyword argument before, not positional

@EricForgy
Copy link
Author

I'm still a novice with Git, but decided to go ahead and try a rebase to make it cleaner. How is that?

warn("Unknown download failure, error code: $res")
run(BinDeps.download_cmd(source,filename))
if isfile(filename)
return readall(filename),200
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what we should try to do for cleanup is something like

str = readall(filename)
rm(filename)
return str, 200

@EricForgy
Copy link
Author

👍 Thanks. Added the cleanup (and rebased again). How's that?

@tkelman
Copy link
Contributor

tkelman commented Jul 16, 2016

Will need a fair bit of testing, but looks like it might do the job. Fair warning, #77 is in progress to fix the deprecation warnings, and may result in this needing a rebase.

C_NULL,utf16(source),dest,sizeof(dest)>>1,0,C_NULL)
if res == 0
resize!(dest, findfirst(dest, 0))
filename = LegacyStrings.utf8(UTF16String(dest))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good news is it looks like this will allow us to remove LegacyStrings from REQUIRE

@nalimilan
Copy link
Member

@tkelman Should this have been merged in July (before conflicts were introduced)?

@tkelman
Copy link
Contributor

tkelman commented Nov 22, 2016

It hadn't been tested very thoroughly yet, so it wasn't entirely ready to go.

@nalimilan
Copy link
Member

So what's the way forward? Merge it and ask for people to test it in various configurations before tagging a release? There have been many reports of issues, so we could probably get some feedback from users.

@tkelman
Copy link
Contributor

tkelman commented Nov 23, 2016

Yeah, something like that. We should probably set up AppVeyor here in some way, and be sure to test on both Server versions of Windows (which have different default security policies that have made a difference here) and when running Julia inside mintty (which has caused freezes when using BinDeps.download_cmd in a few cases, IIRC).

@xgdgsc
Copy link

xgdgsc commented Feb 15, 2017

Hope this get merged soon. Installation issue is really painful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants