This afternoon, Troy and I were trying to figure out why he couldn't load the feed for one of the internal blogs into BottomFeeder. At first, we thought it might be some kind of oddball network/proxy issue, and brought in one of our IT people to answer questions. Nothing seemed to be out of the ordinary there, so I had Troy go to the System menu in BottomFeeder and open up a workspace. This is one of the cooler things about the application; you can write Smalltalk script just like you can in a development workspace. So, I had him try this:
(HttpClient new get: 'internalUrlWentHere') contents.
That worked, so I had him try out the test code I normally use to look for feed issues:
doc := Constructor
documentFromURL: 'internalUrlHere'
forceUpdate: true
useMaskedAgent: false.
cls := Constructor determineClassToHandle: doc content.
target := cls objectForData.
feed := cls
processDocument: doc content
from: 'internalUrlHere'
into: target.
Inspecting the feed variable at the end showed that the url was reachable - what we had was a cache problem. I had Troy reset his cache in Bf, and all was well. I'll have to see about not caching bad results, but the cool thing was that we could do this in the runtime - he didn't have to set up a dev version in order to try this stuff out.
That's the power of Smalltalk, right there.
Technorati Tags:
smalltalk