#perl - Wed 28 Mar 2007 between 21:49 and 21:54



Randalstep 3 - write like mad
step 4 - produce and ship book
we haven't done step 1 yet. )
revdiabloMaybe "Learning Perl 6 (kinda)"
Randal"Learning Perl 5.99"
DoddeI use Mechanize to fetch a webpage, but imagine each webpage is 50kb of size, is there a way to check existance of a webpage without actually retrieving it, and thus cause less server load and bandwidth? imagine 1 million pages would be checked, so totally it makes a significant difference... anyone has an idea?
revdiabloThe new "Learning X (kinda)" series of O'Reilly books
Randalsometimes HEAD works instead of GET
alesteryes, use head()
Randalit doesn't necessarily though
if you do that to most of my pages, you'll still get the whole page
saves me nothing. :)
jagermanEven worse, sometimes HEAD returns a 200 when a GET returns a 404.
QtPlatypusAnd while I'm Leanring Haskell I'm not yet good enought to help Pugs. And as for my C and C++ skills they have aptrophied.
Randalyeah
I keep *starting* to learn haskell.
then I don't grok a particular "obviously..." example
and then it doesn't get any easier. :)
people who grok haskell are Smarter Than Me
Doddehmm so what does head() actually check for?
Randalhead() invokes HEAD
it's up to the server how that differs
HEAD /some/url
vs
GET /some/url
QtPlatypusRandal: So I guess I will not be seeing a "Learning Haskell" book anytime soon?
Randaltotally server-side
Doddeit's for a wikipedia bot... so it's checking wikipedia pages
revdiabloDodde: TIAS
Randalis that within the terms of service?
jagermanIn theory, HEAD is meant to return just the header of the same GET request. In practise, ignorant Windows server users break it all the time.
RandalI know they're not too happy with automated hits
QtPlatypusDodde: Isn't there a web service gateway to wikipedia?
DoddeQtPlatypus: I am not sure what you mean
actionQtPlatypus thought that there was a SOAP interface or a REST interface to wikipedia... but I could be wrong.
QtPlatypusthought that there was a SOAP interface or a REST interface to wikipedia... but I could be wrong.
DoddeRandal: how you mean within terms of service?
Randalheh. HEAD on wikipedia returns 403 forbidden
on a page that's definitely there
so yeah, it won't work on wikip
DoddeRandal: it is meant to check the existance of translations on foreign wiktionaries... based on the result the bot will save the info to the entry checked... so yes it's a service

Page: 4 11 18 25 32 39 46 53 60 67 74 81 88 95 102 109 116 123 

IrcArchive