Archives mensuelles : décembre 2021

Ergonomic tricks

Windows And Linux Native Copy: Ctrl+Ins Cut: Shift+Del Paste: Shift+Ins Windows apps PowerToys Rebind some keys or keys combination.– to reduce the thumb painful combination with Alt + keys  in the left side such as : Alt + Tab, Alt … Continuer la lecture

Publié dans Non classé | Laisser un commentaire

Python – Asyncio

Purpose and overview asyncio is a library to write concurrent code using the async/await syntax. At its core, it relies on an event loop model processing coroutines, so it uses only one thread. It is is used as a foundation … Continuer la lecture

Publié dans Non classé | Laisser un commentaire

python unit testing

unittest API General – add the tests files/fixtures in a test folder at the root of the project. The folder may have any name in last Python 3 versions. – create an empty file __init__.py at the root of the … Continuer la lecture

Publié dans Non classé | Laisser un commentaire

python venv

Introduction When using that ? In almost every applications. The python and packages installed on the host may suit to some applications needs but not to all. To settle that : the venv module. That is the standard python module … Continuer la lecture

Publié dans Non classé | Laisser un commentaire

Pip : package manager

Pip Generalities Repository : https://pypi.org/ requirements.txt VS requirements.in requirements.txt is the pip official format to list all dependencies for a project. It is a universal format understood by pip install -r but also uv pip, poetry export, Docker, Heroku, AWS, … Continuer la lecture

Publié dans Non classé | Laisser un commentaire

Python HTTP requests

Requests API Allow to send HTTP/1.1 requests. No need to manually add query strings to your URLs, or to form-encode POST data. Basic usage : import requests … response = requests.get(’https://api.github.com/events’) Session Object A Session object has all the methods … Continuer la lecture

Publié dans Non classé | Laisser un commentaire