Brewing a Taco-style Flavoured Python
added on 2022-08-30
This is the third post and a continuation of tacobell programming but in Python3.
This post has been inspired by this post by teddziuba here
and is a continuation of the previous post here
My objectives out of this post ?
- Check the viability of coding in this new way ->
- Combining literate programming with infix notation to designate pipes, to make code more readable and usable
- Centralise all handy tools under handy package and use it ->
- Test it out in real world ->
- Ending Remarks ->
Checking Viability
My hypothesis is the way pipes module is designed for Python3, I can get a much better productivity gain from this,
instead of depending on bash. Overtime, bash’s coreutils and moreutils can be implemented in python3 later.
But python3’s pipes advantage are far more paramount, they are more expressive, and more promising, in sense as it combines
the expressiveness of python3, with the syntactical sugar of unix’s pipes.
Test it Out
Try out handout
For testing this new style out, I’ll just quickly refactor the bearparse.py
This is overall pretty decent, now i’ll start refactoring the bearparse script, function by function
Try out pipe
develop today’s task which is to build an image notedown tool, where the code extracts my notes from bear notes under certain tags, then renders a single page html, with all the images, alongside their notes. Related images are assembled together, into collections, and rendered accordingly.
Combine them both
Build Handy Package
- handy module for email sending
- handy module for email feedback management
- handy module for newsletter generation
- handy module for pgSQL job queue
- handy module for logging
- handy module for sunday
- handy module for unix named pipe handling (for building async dataprocessing here)
Remarks
handout’s doc output feature can be combined with a central tool, which pulls the documentation from all projects and adds it to teitosite’s static folder and gates, it behind nginx authentication
Other notes
References for content in this blog post
Contact/etc
I’m mostly exploring this style of programming as an idea and thinking of how many places and how many ways, I can use this style to my advantage.
If you have more ideas on how I can improve this even more, or have questions that you think might be relevant to this discussion.
Email them to me at teito@teitoklien.com
I’ll add a link here to my next post in this series, when It’s ready,