I must've done something wrong with BinDeps. For some reason
Pkg.build("LibCURL") does not seem to be doing anything. If you manually do
using WinRPM
WinRPM.update()
WinRPM.install("libcurl")
then HTTPC.get("http://www.google.com") works for me. I thought the
deps/build.jl I wrote in that patch would just automatically do that.
On Tuesday, May 6, 2014 1:47:11 PM UTC-7, Tony Kelman wrote:
>
> I'll have a look. It might be another case of Windows XP missing a some
> function in its runtime library that libcurl.dll is trying to use.
>
>
>
> On Tuesday, May 6, 2014 7:57:08 AM UTC-7, Amit Murthy wrote:
>>
>> Unfortunately I don't have access to a Windows machine to try it out. May
>> be related to this patch
>> https://github.com/amitmurthy/LibCURL.jl/pull/10that was recently applied.
>> Maybe Tony can help out here.
>>
>>
>> On Tue, May 6, 2014 at 7:13 PM, joanenric barcelo <[email protected]>wrote:
>>
>>> Thanks Amit, I've tried your package as well. What I get in my machine
>>> is the following:
>>>
>>> Microsoft Windows XP [Version 5.1.2600]
>>> (C) Copyright 1985-2001 Microsoft Corp.
>>>
>>>
>>> C:\Documents and Settings\jbarcelo>julia
>>> OpenBLAS : Your OS does not support AVX instructions. OpenBLAS is using
>>> Nehalem
>>> kernels as a fallback, which may give poorer performance.
>>> _
>>> _ _ _(_)_ | A fresh approach to technical computing
>>> (_) | (_) (_) | Documentation: http://docs.julialang.org
>>> _ _ _| |_ __ _ | Type "help()" to list help topics
>>> | | | | | | |/ _` | |
>>> | | |_| | | | (_| | | Version 0.3.0-prerelease+2809 (2014-04-28
>>> 22:41 UTC)
>>> _/ |\__'_|_|_|\__'_| | Commit d1095bb* (7 days old master)
>>> |__/ | i686-w64-mingw32
>>>
>>>
>>> julia> using HTTPClient.HTTPC
>>>
>>> julia> r = HTTPC.get("http://xxx.xxx.xxx.xxx:xx/?request=var")
>>> ERROR: error compiling get: error compiling setup_easy_handle:
>>> in get at C:\Documents and Settings\user\.julia\v0.3\HTTPClient\src\
>>> HTTPC.j
>>> l:519
>>>
>>>
>>> Do you have any idea on what can be causing this issue? Thanks Amit
>>>
>>>
>>> El martes, 6 de mayo de 2014 10:55:46 UTC+1, Amit Murthy escribió:
>>>>
>>>> If you want to try with HTTPClient, the usage would be
>>>>
>>>> using HTTPClient.HTTPC
>>>> r=HTTPC.get("http://xxx.xxx.xxx.xxx:xx/?request=var")
>>>>
>>>> r.body is an IOBuffer containing has the response body. If the response
>>>> is an ASCII string, you can stringify it with bytestring(r.body)
>>>> r.http_code has the response code
>>>>
>>>>
>>>>
>>>>
>>>> On Tue, May 6, 2014 at 3:00 PM, Avik Sengupta <[email protected]>wrote:
>>>>
>>>>> I'm presuming you're using this in windows.
>>>>>
>>>>> The download(url) method places the content of the url into a
>>>>> temporary filename. The function should then return the name of the file
>>>>> in
>>>>> which the content has been placed. Unfortunately, the windows verson of
>>>>> the
>>>>> function seems to have a bug where it does not return the filename. The
>>>>> unix version does.
>>>>>
>>>>> As a workaround, you can use the download(url, filename) version of
>>>>> the method. So something like:
>>>>>
>>>>> filename = tempname()
>>>>> download(url, filename)
>>>>>
>>>>> The contents of the url will then be in the file represented by
>>>>> filename.
>>>>>
>>>>> Regards
>>>>> -
>>>>> Avik
>>>>>
>>>>>
>>>>>
>>>>> On Tuesday, 6 May 2014 10:20:30 UTC+1, joanenric barcelo wrote:
>>>>>>
>>>>>> That is right, what I want is to get the value of var as you said, ie.
>>>>>>
>>>>>> http://xxx.xxx.xxx.xxx:xx/?request=var
>>>>>>
>>>>>> so, doing
>>>>>>
>>>>>>
>>>>>> julia> dir = "http://xxx.xxx.xxx.xxx:xx/?request=var";
>>>>>>
>>>>>> julia> a = download(dir)
>>>>>>
>>>>>> julia> println(a)
>>>>>> nothing
>>>>>>
>>>>>> julia> typeof(a)
>>>>>> Nothing (constructor with 1 method)
>>>>>>
>>>>>>
>>>>>>
>>>>>> I am not getting anything. Any ideas so far? Thanks!
>>>>>>
>>>>>>
>>>>>> El sábado, 3 de mayo de 2014 17:17:10 UTC+1, Jameson escribió:
>>>>>>>
>>>>>>> Or use the builtin `download` command. it isn't very fancy, but
>>>>>>> should
>>>>>>> get the job done.
>>>>>>>
>>>>>>> I'm not sure what matlab means by PARAMS for an HTTP GET, since the
>>>>>>> GET method doesn't take arguments. presumably though, it is
>>>>>>> rewriting
>>>>>>> the url to `http://xx.xx.xx.xx:xx/?request=value' with quoting for
>>>>>>> request and value as needed
>>>>>>>
>>>>>>> On Sat, May 3, 2014 at 6:19 AM, joanenric barcelo <
>>>>>>> [email protected]> wrote:
>>>>>>> > Thanks Tony for your help.
>>>>>>> >
>>>>>>> > However, I need to use Win XP for working reasons and I cannot
>>>>>>> manage to get
>>>>>>> > it work. I have raised another post with this issue
>>>>>>> > https://groups.google.com/forum/#!topic/julia-users/wPNc8T8lxX8
>>>>>>> >
>>>>>>> > thanks again!!
>>>>>>> >
>>>>>>> > El miércoles, 30 de abril de 2014 17:57:50 UTC+1, Tony Kelman
>>>>>>> escribió:
>>>>>>> >>
>>>>>>> >> I'm not sure if the functionality is in base, but presumably one
>>>>>>> of the
>>>>>>> >> http client packages (like https://github.com/loladiro/Re
>>>>>>> quests.jl) could do
>>>>>>> >> what you're looking for?
>>>>>>> >>
>>>>>>> >>
>>>>>>> >> On Wednesday, April 30, 2014 8:57:17 AM UTC-7, joanenric barcelo
>>>>>>> wrote:
>>>>>>> >>>
>>>>>>> >>> Hi!
>>>>>>> >>>
>>>>>>> >>> I'm coming from Matlab and I would like to request some
>>>>>>> information
>>>>>>> >>> through IP connection. Basically, I would like to translate the
>>>>>>> following
>>>>>>> >>> Matlab command
>>>>>>> >>>
>>>>>>> >>> urlread('URL','method',PARAMS)
>>>>>>> >>>
>>>>>>> >>>
>>>>>>> >>> concretely:
>>>>>>> >>>
>>>>>>> >>> urlread('http://xx.xx.xx.xx:xx','Get',{'request','value'})
>>>>>>> >>>
>>>>>>> >>>
>>>>>>> >>>
>>>>>>> >>> Thanks in advance!
>>>>>>> >>>
>>>>>>> >>> JoanEnric
>>>>>>>
>>>>>>
>>>>
>>