💾 Archived View for warmedal.se › ~bjorn › posts › gemcall-now-supports-streaming-and-more.gmi captured on 2024-05-10 at 11:52:48. Gemini links have been rewritten to link to archived content
View Raw
More Information
⬅️ Previous capture (2021-12-03)
-=-=-=-=-=-=-
Gemcall Now Supports Streaming and More
https://notabug.org/tinyrabbit/gemcall
Big changes to my CLI gemini client gemcall in the past few days!
- Replaced getopt with argparse. I think Solene initially suggested argparse, but I somehow got it into my head that it wasn't part of the standard library. That mistake is now amended.
- The client can now be used as a lib. It provides the function gemcall.request, which returns a gemcall.Response object. This has everything you need to build a more feature-full client or browser around.
- It supports streaming! It will output data as it comes in, instead of waiting for everything to download first.
- The response code and meta line are now printed to stderr instead of stdout, neatly separated from the response body.
- Speaking of which, you can now choose to omit the header output -- or ONLY print the header.
This is a big thing. After some battle testing I intend to read up on how to make this available to pip install.
Please let me know if you have questions or find issues.
-- CC0 ew0k, 2021-07-11