# https://paws-public.wmflabs.org/paws-public/User:YuviPanda/replicahelper.ipynb
import os
from sqlalchemy import create_engine
from sqlalchemy.sql import text
host = os.environ['MYSQL_HOST']
user = os.environ['MYSQL_USERNAME']
password = os.environ['MYSQL_PASSWORD']
connection_string = 'mysql+pymysql://{user}:{password}@{host}/?charset=utf8mb4'.format(
    user=user,
    password=password,
    host=host
)
engine = create_engine(connection_string, pool_recycle=300)
cur_db = 'enwiki_p'