|
|
#281 |
|
Senior Member
Join Date: Sep 2003
Posts: 123
|
after further testing, I can say that I only get the "installation aborted" message when the download actually fails. I tried changing the download url to something that doesn't exist, and now everytime I press the [x] button, I get the wrong message ("are you trying to install nquake offline?").
so apparently, inetc only returns "Cancelled" if the download was successful AND cancelled? Bored with the real world? Try QuakeWorld! |
|
|
|
|
|
#282 |
|
Junior Member
Join Date: May 2004
Posts: 4
|
URL Parts Error
My installer works fine on my machine but as soon as i run it on another machine it seems to download and at the end get a URL Parts error. i am using inetc get command with the /END prefixed and still getting it.
All i am downloading is the ASP.NET Ajax framework with the following command inetc::get /caption "Downloading AJAX ASP.NET Framework 1.0" /canceltext "Cancel Download" "http://download.microsoft.com/download/5/4/6/5462bcbd-e738-45fa-84ca-fa02b0c4e1c2/ASPAJAXExtSetup.msi" "$INSTDIR\ajax.msi" /TIMEOUT 5000 /END I do not know why it works on one and the other machine gets the URL Parts Error, anyone mind to shed some light on this? ![]() TIA |
|
|
|
|
|
#283 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Does $INSTDIR exist?
Stu |
|
|
|
|
|
#284 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Move /TIMEOUT 5000 to the beginning of command line.
|
|
|
|
|
|
#285 |
|
Junior Member
Join Date: May 2004
Posts: 4
|
aha! That did the trick!
Hmm, the fact that it worked on one machine and didn't in the other really did not strike me as writing the command erroneously :P |
|
|
|
|
|
#286 |
|
Senior Member
Join Date: Sep 2006
Posts: 150
|
What is the OS on the two machines?
|
|
|
|
|
|
#287 |
|
NSIS MUI Dev
Join Date: Nov 2001
Posts: 3,717
|
InetLoad frequently crashes on Windows Vista while downloading from an FTP server. Did you test the Vista compatibility?
|
|
|
|
|
|
#288 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
I tested InetLoad on Vista. Do you know any addition requirements for NSIS plug-ins on this OS? And please attach test script if you can reproduce crash. Might be good to compare situation with Inetc that not includes 'crashable' NSISdl code fragment. Thanks.
|
|
|
|
|
|
#289 |
|
Junior Member
Join Date: Aug 2007
Posts: 4
|
InetLoad is great!
I have a problem though: I'm using InetLoad to post installation status to a server. When I call it before the first custom page (MUI) it makes the installer run in the background. This is really bad cause when a user downloads my installation and the installer doesn't go to the front of the page, the user wouldn't know it's running. Any way to solve this? |
|
|
|
|
|
#290 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
If new process (installer) creates any window during a short period of time, OS gives this window focus and sets it foreground. In your situation window appear too late (silent http request delay from .oninit function?). If you don't want to use InetLoad popup/banner, use one of NSIS banner plug-ins to catch foreground position. You can also try to use SetForegroundWindow call to move installer foreground, but this is not efficient in most OSes (InetLoad do this in silent mode for some reasons), see example in the attached script how to do this.
|
|
|
|
|
|
#291 |
|
Junior Member
Join Date: Aug 2007
Posts: 4
|
Takhir, thanks for you quick response.
Tried your code - Now after the post the installer flickers (windows xp) on the taskbar. No way to make the posting not steal focus? |
|
|
|
|
|
#292 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
The only good way I know is to create new window when process starts. Try to use InetLoad' own (/popup, /banner) or another banner.
Yes, on XP and later SetForeground causes flickering only. |
|
|
|
|
|
#293 |
|
Senior Member
Join Date: Sep 2003
Posts: 123
|
would it be possible to get some speed information on the /banner window?
i want to have customized download texts (i.e. not "downloading <filename>" but rather "downloading <file description"), but /banner makes the download speed text go away
Bored with the real world? Try QuakeWorld! |
|
|
|
|
|
#294 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Sorry, I am overloaded with urgent job, but for now you can create your version of plug-in with this output in the /banner window static field by copying code from /popup output timer function (C experience required).
|
|
|
|
|
|
#295 |
|
Senior Member
Join Date: Dec 2005
Location: Glow
Posts: 285
|
Small suggestion. Use the INTERNET_FLAG_NO_CACHE_WRITE flag in HttpOpenRequest() to disable writing in the IE cache. At the moment all downloaded files goes into to the cache as well.
I tried this my self and it seems to work so far.
|
|
|
|
|
|
#296 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Thanks! I'll add this to the next release.
BTW I prepared an dcompilled but not tested Unicode (TCHAR) version (because not sure that NSIS Unicode package will not damage current ANSI version), so if anybody want to test it - please send me private message (it's in Account on the page top). |
|
|
|
|
|
#297 | ||
|
Senior Member
Join Date: Dec 2005
Location: Glow
Posts: 285
|
Quote:
Quote:
) or resume won't work at all while INTERNET_FLAG_NO_CACHE_WRITE is used. So I think it's better leave the cache writing on while resume is used.
|
||
|
|
|
|
|
#298 |
|
Senior Member
Join Date: Dec 2005
Location: Glow
Posts: 285
|
From the InternetSetFilePointer() MSDN page "... This handle must not have been created with the INTERNET_FLAG_DONT_CACHE or INTERNET_FLAG_NO_CACHE_WRITE value set."So using INTERNET_FLAG_NO_CACHE_WRITE breaks the resume for sure. I realized that there's a small bug in the Inetc code. This statement is always true because InternetSetFilePointer() return type is DWORD. code: You should use something like this. code: -- The IE cache writing still bothered me so I made a little research for alternative methods and I found this article. http://www.clevercomponents.com/arti...5/resuming.asp I implemented the range request method described in there to Inetc code. It works without the cache, but probably isn't reliable as the InternetSetFilePointer() method. |
|
|
|
|
|
#299 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Thank you very much {_trueparuex^}
I updated both inetc & inetload plug-ins. Also new feature in inetc: /question cancel_text (was requested here) About no_cache_write using 'range request' - interesting idea for big files (like night movie downloads). Let's check reliability and if OK we'll add your code to inetc. Or you can write new multuthreaded super-fast downloader
|
|
|
|
|
|
#300 | |
|
Senior Member
Join Date: Dec 2005
Location: Glow
Posts: 285
|
Quote:
...1500 megawatt Aperture Science heavy-duty super-threaded super loader. Seriously that's not a bad idea at all.At least there shouldn't any difference on what servers the resume methods work... http://support.microsoft.com/kb/168408 But InternetSetFilePointer() definitely is more flexible and handles exceptions way better. |
|
|
|
|
|
|
#301 |
|
Senior Member
Join Date: Dec 2005
Location: Glow
Posts: 285
|
There was bug in the content length / accept ranges check in my last file. So here's a new one.
|
|
|
|
|
|
#302 |
|
Junior Member
Join Date: Feb 2008
Posts: 5
|
I think there is a bug in inetc::put. When I try to upload a file, the http header content-length is always 0. Here's an example:
======= Start ======= PUT / HTTP/1.1 Content-Type: octet-stream Content-Length: 0 User-Agent: NSIS_Inetc (Mozilla) Host: XXXXXXXX.de:8812 Connection: Keep-Alive Cache-Control: no-cache line1 line2 ======= End ======= In the NSIS script I use this line: inetc::put "http://docstore.interchange.de:8812/" "$EXEDIR\testfile" /END When I upload the file with curl (curl -T testfile http://XXXXXXXX.de:8812) everything works as expected: ======= Start ======= PUT /testfile HTTP/1.1 User-Agent: curl/7.16.3 (i686-pc-cygwin) libcurl/7.16.3 OpenSSL/0.9.8g zlib/1.2.3 libssh2/0.15-CVS Host: XXXXXXXX.de:8812 Accept: */* Content-Length: 16 Expect: 100-continue line1 line2 ======= End ======= On XXXXXXXX.de:8812 runs netcat (nc -l -p 8812) which does nothing more than capturing everything that comes in on port 8812. Inetc and curl connect directly to the server (no proxies). Is this a know problem? Unfortunately, I don't have Visual Studio available, so I can't dive in the code myself. But I'd love to help debugging it on the server side if needed. |
|
|
|
|
|
#303 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Thanks, janekschwarz. Bug was added in the Jan. 30, 2007 revision. Fixed now, please update your files.
|
|
|
|
|
|
#304 |
|
Junior Member
Join Date: Feb 2008
Posts: 5
|
Thank you for the quick answer. I'll download the new version and report back.
|
|
|
|
|
|
#305 |
|
Junior Member
Join Date: Feb 2008
Posts: 5
|
Takhir, thanks again for the fix. It works.
Another question: Does http authentication work with inetc::put? I tried something simple (http://user:passwd@XXXXXXXX.de/puttest/put.php) and always get an 401 error back. Curl authenticates successfully. |
|
|
|
|
|
#306 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Thanks, janekschwarz! I could reproduce this issue, probably this configuration was not tested earlier. Short googling gave me few similar questions, but no answers yet. Server accepts PUT request, receives file, but returns 401 in EndRequest() status header. Download from the same protected folder (.htaccess overridden) works correct. Any ideas?
|
|
|
|
|
|
#307 |
|
Junior Member
Join Date: Feb 2008
Posts: 5
|
I did an experiment. Authentication works if I set the Authorization header my self:
inetc::put /HEADER "Authorization: Basic PXVzZXI6cGFzc3dk" "http://XXXXXXXX.de/puttest/put.php" "$EXEDIR\testfile" /END Maybe the trick is to send the Authorization headers preemptively. |
|
|
|
|
|
#308 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
And thank you again, janekschwarz!
I tested patch (internal base64 login asswd encoding) and it worked fine. When (and if) sourceforge will work again I'll put new zip to server.
|
|
|
|
|
|
#309 |
|
Junior Member
Join Date: Feb 2008
Posts: 5
|
Hi, thank you for the fix.
I hate to admit it, but I found another problem: inetc::put through an authenticating proxy does not work. It gives up right after receiving the 407 status code from the proxy and does not ask for proxy credentials (example.nsi contained in the zip file does, so it works in principle). Any ideas? |
|
|
|
|
|
#310 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Unicode
I attached unicode version on inetc plug-in to this post - worked correct during my (short) testing. Wiki version has the same TCHAR decoration, so the only difference with archive code is path to exdll.h. I'll convert project to VS 2005 with additional Unicode configurations and put to wiki later (after some tests, and I hope you will help me). Version with log prints (for debugging) is temporary available here http://ineum.narod*****inetc.htm
Have fun
|
|
|
|
|
|
#311 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
By the way there is a slight issue when using inetc on the install files page. If you haven't clicked the show details button, then everything is fine (inetc disables it, fine). If however, you do click the show details button before downloading, inetc shows over the log window without hiding it.
Be nice if this code could go in the plug-in but this is how to sort it in NSIS script: code: Just make sure you don't touch the $R0 and $R1 variables between DownloadPre and DownloadPost. Stu |
|
|
|
|
|
#312 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Thanks, Stu, I'll try to add this feature to next release. Is 1016 unique value for this page-control?
This morning I uploaded inetc version with (I hope) finally fixed PUT issue if proxy or HTTP server authorization required (many thanks to janekschwarz). Problem was in proxy/server auth request that came back after all data were already sent (and progress bar reached right border). New version for HTTP PUT first tests connection using OPTIONS request. The only remaining 'difficult' situation is PUT to HTTPS if proxy/server authorization data to be requested from user (in password/login dialog) because OPTIONS request to HTTPS failed in my tests. http://nsis.sourceforge.net/Inetc_plug-in |
|
|
|
|
|
#313 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Yes it is the id for the list view control.
Stu |
|
|
|
|
|
#314 |
|
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
Also, is it just me or does it not re-enable the show details button?
Stu |
|
|
|
|
|
#315 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
Inetc restores original button style after transfer complited. May be nothing to 'show' in your sample?
|
|
|
|
|
|
#316 |
|
Junior Member
Join Date: Oct 2007
Posts: 24
|
If i use Inetc plugin in .OnInit function, installer never gets focus when launched.
Ex : code: Another problem with close button : I have a script with AutoClose = True and InetC command in .OnInstSuccess function If a user click on the button before the page desappears then the execution of the script jump to a random location (always the same though). Any help ? thx |
|
|
|
|
|
#317 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
1. You can find related discussion on page 5 of this thread.
2. Any plug-in require installer running, may not work when on the exit step, so it's not a good idea to run inetc in .OnInstSuccess. |
|
|
|
|
|
#318 |
|
Major Dude
|
Is this a bug or am i doing something wrong?
I'm trying to download a file from https using authentication, the username dialog comes up fine and works as expected when wrong and right usernames are entered. However is one clicks cancel on that dialog, inetc downloads the http error report and sets status to OK. Is there a way to detect if/when this happens? Vytautas |
|
|
|
|
|
#319 |
|
Major Dude
Join Date: Feb 2004
Location: Moscow, Russia
Posts: 1,222
|
This is a bug. InternetErrorDlg() returns ERROR_SUCCESS 0 on Cancel click (I hoped this to be ERROR_CANCELLED 1223 as MSDN declares). Thanks, Vytautas, I'll put updated to server version as soon as sourceforge will be up (with 2 other small changes).
|
|
|
|
|
|
#320 |
|
Major Dude
|
Thank you, thats much better now
|
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|