Am 18.04.2013 um 23:10 schrieb "Sean P. DeNigris" <sean@clipperadams.com>:
Sven Van Caekenberghe-2 wrote
Where/how does Zinc think this is text ?
If I add #systemPolicy, and alter the snippet to: latestVersionUrl := 'http://mirrors.jenkins-ci.org/war/latest/jenkins.war'. javaArchiveMimeType := ZnMimeType main: 'application' sub: 'java-archive'. ZnClient new systemPolicy; accept: javaArchiveMimeType; followRedirects: true; url: latestVersionUrl; downloadTo: FileLocator imageDirectory.
I get either: a. /intermittently/ "ZnUnexpectedContentType: expected application/java-archive actual text/plain" or b. it downloads, but it shows up in Mac Finder as a text file (kind: TEXT)... not the end of the world, butâ¦
Sean, let me guess, you can't reliable test it. Sometimes it works and sometimes not? This is the situation: - your url is a redirect to another url - the redirected url is load balanced so get different server in subsequent requests. - the guys at dl.aragost.com didn't configure the web server correct. They didn't at a content type handler for .war so it says text/plain Just do $ curl -v http://dl.aragost.com//jenkins/war/1.511/jenkins.war -O /tmp/foo and you can see the text/plain content-type whiel $ curl -v http://jenkins.mirror.isppower.de/war/1.511/jenkins.war -O /tmp/foo gives you the java type. Norbert