Skip to content

Instantly share code, notes, and snippets.

View romuald's full-sized avatar
🍣

Romuald Brunet romuald

🍣
View GitHub Profile
@romuald
romuald / nosy_patch.py
Last active February 22, 2023 10:05
Python "pass-through" patch recipe
"""
This is a simple "pass-through" patch recipe for python testing
Allows to check if a method was called during testing
For example:
```
with nosy_patch('package.inner_method') as mock:
package.outter_method()
@romuald
romuald / dcsv.py
Created August 5, 2025 09:45
A simple snippet that can be used to read CSV files with headers
"""
A simple snippet that can be used to read CSV files with headers
"""
import csv
from contextlib import contextmanager
@contextmanager
def dcsv(filename):
with open(filename) as reader:
@romuald
romuald / zendesk-mfa-press-enter.js
Created January 2, 2026 09:50
Fix Zendesk MFA pager, press enter to submit
// ==UserScript==
// @name Zendesk fix MFA auth
// @version 2026-01-02
// @description Just press enter dammit
// @match https://*.zendesk.com/auth/v3/mfa*
// @icon https://www.google.com/s2/favicons?sz=64&domain=zendesk.com
// @grant none
// ==/UserScript==
(function() {