17th November 2021
Coding⚑
Python⚑
FactoryBoy⚑
-
New: Automatically generate a factory from a pydantic model.
Sadly it's not yet supported, it will at some point though. If you're interested in following this path, you can start with mgaitan snippet for dataclasses.
Python Snippets⚑
-
New: Make a flat list of lists with a list comprehension.
There is no nice way to do it :(. The best I've found is:
t = [[1, 2, 3], [4, 5, 6], [7], [8, 9]] flat_list = [item for sublist in t for item in sublist]
DevOps⚑
Infrastructure Solutions⚑
Jobs⚑
-
New: Manually creating a job from a cronjob.
kubectl create job {{ job_name }} -n {{ namespace }} \ --from=cronjobs/{{ cronjob_name}}
Continuous Integration⚑
Pyment⚑
-
New: Introduce Pyment.
Pyment is a python3 program to automatically create, update or convert docstrings in existing Python files, managing several styles.
As of 2021-11-17, the program is not production ready yet for me, I've tested it in one of my projects and found some bugs that needed to be fixed before it's usable. Despite the number of stars, it looks like the development pace has dropped dramatically, so it needs our help to get better :).