Skip to content

Instantly share code, notes, and snippets.

View ant358's full-sized avatar
🎯
Focusing

Anthony Wynne ant358

🎯
Focusing
  • Plymouth, UK
View GitHub Profile
@dimitryzub
dimitryzub / serpapi_google_maps_local_results.py
Created June 9, 2021 15:30
Scrape Google Maps Local Results using SerpApi
from serpapi import GoogleSearch
import csv
params = {
"api_key": "YOUR_API_KEY",
"engine": "google_maps",
"type": "search",
"google_domain": "google.com",
"q": "кофе мариуполь", # query
"ll": "@47.0919234,37.5093148,12z" # @ + latitude + , + longitude + , + zoom
@bbengfort
bbengfort / interval.py
Last active July 7, 2023 04:33
Run a function every n seconds using Python threading.
from threading import Timer
from functools import partial
class Interval(object):
def __init__(self, interval, function, args=[], kwargs={}):
"""
Runs the function at a specified interval with given arguments.
"""
self.interval = interval