@neumann I’ve been meaning to post this for weeks — my feeling listening to your latest series is that you’ve been watching me slog thru the mud for the last three months. 😂 😂 Long running API calls to OpenAI, or transcribing videos in RevAI, or downloading emails from Gmail, or fetching videos from Google Photos, or fetching videos and extracting videos in ffmpeg, or testing URLs for liveness. Long sessions in the REPL, plowing forward, trying to figure out what in the heck Google Java clients return, dealing with rate limit issues, long “iteration” calls, attempts to cache values for speed (and occasionally biting in the butt)… running into totally unexpected error cases as I start doing longer runs, trying to figure out where the try/catches should be. I loved your suggestion of returning maps of all the intermediate values in the “let” bindings. Would save so many “defs” in my code! Can’t wait to listen to this weeks episode!!! (I posted today my recent gobsmacked reactions to the Google Photos Java client here, which made me question my sanity here: https://clojurians.slack.com/archives/C1AC4BU2K/p1706810085720339)
In my experience, Google's APIs tend to be really frustrating and Google's Java APIs doubly so. It's actually quite impressive how they can write documentation that's comprehensive, technically correct and somehow, frustratingly unhelpful. I've definitely abandoned Google's Java APIs for their REST APIs multiple times.
@genekim Thanks so much for sharing. That sounds like a total grind! This series was 100% born out of our own slogs with integration. I'm glad it rings true and you're finding it helpful! @nate always reminds me that these are "situated" systems that are solving messy real-world problems. I love that Clojure helps me deal with the mess instead of trying to force me to define the mess away by imposing rigid structure. (Object mapping anyone?) Clojure gives me the flexibility to meet the system where it's at, so I can use Clojure to figure all this stuff out. Thanks again for taking a moment to share!
@smith.adriane I haven't used Google's API, but I have definitely abandoned language-specific API wrappers to just integrate directly with a REST API. It seems like such a better fit for Clojure. None of that everything-must-be-a-class rigidness. None of the complexity of a class model sitting on top of the intrinsic information model.
Lately, I've been writing wrappers for c libraries and I've found that it's often easier to wrap a c library than an equivalent java library.
That's so fascinating. C is so much simpler. No towers of classes!
@genekim Out of curiosity, are you using JVM Clojure or #babashka for those things? It sounds like a good use case for Babashka (I'm doing similar stuff). https://book.babashka.org/#tasks is convenient as a "UI" to my Clojure code.