Skip to content

Instantly share code, notes, and snippets.

View sintezcs's full-sized avatar
🏠
Working from home

Alex Minakov sintezcs

🏠
Working from home
View GitHub Profile
@artem78
artem78 / SymbianDev-en.md
Last active April 6, 2024 20:25
Developing for Symbian OS guide
@ancientGlider
ancientGlider / keenetic_auth.py
Last active April 8, 2024 02:40
Authentication for Keenetic routers for work with CLI via REST API (Python)
# -*- coding: utf-8 -*-
"""
Данные с адресом, логином, паролем хранятся в конфигурационном файле следующего вида:
[Router]
ip_addr = 192.168.1.1:8080
login = admin
passw = anyPassword
@tossmilestone
tossmilestone / Flake8.txt
Created March 30, 2018 06:55
Flake8 integrated with PyCharm
How to manually setup flake8 as PyCharm external tool
File / Settings / Tools / External Tools / Add
Name: Flake8
Program: $PyInterpreterDirectory$/python
Parameters: -m flake8 --max-complexity 10 --ignore E501 $FilePath$
Working directory: $ProjectFileDir$
Output Filters / Add
Name: Filter 1
@sintezcs
sintezcs / rate_limit.py
Last active February 16, 2017 07:41
Rate-limiting decorator
import threading
import time
def rate_limited(max_per_second):
lock = threading.Lock()
min_interval = 1.0 / max_per_second
def decorate(func):
last_time_called = time.perf_counter()