Skip to content

Instantly share code, notes, and snippets.

View mdbenito's full-sized avatar
🫥

Miguel de Benito Delgado mdbenito

🫥
View GitHub Profile
@mdbenito
mdbenito / batched.py
Created September 17, 2023 15:49
Batched iterators
from typing import Type, Callable, Iterable, List, TypeVar, Generator, cast
import pytest
T = TypeVar('T')
def class_wraps(original_cls: Type) -> Callable[[Type], Type]:
""" A decorator to update the wrapped class's docstring with that of the
original class (plus that of the wrapped class).
@mdbenito
mdbenito / float-api-v3-openapi.yaml
Last active April 22, 2022 09:18
An (incomplete) OpenApi spec for float.com's v3 API
openapi: 3.0.0
info:
version: '3.0'
title: Float API
description: This API allows 3rd party integration of your Float data.
security:
- bearerAuth: []
paths:
/accounts: