Changeset View
Changeset View
Standalone View
Standalone View
swh/provenance/postgresql/db_utils.py
from configparser import ConfigParser | |||||
import io | import io | ||||
import psycopg2 | |||||
from configparser import ConfigParser | import psycopg2 | ||||
def config(filename: str, section: str): | def config(filename: str, section: str): | ||||
# create a parser | # create a parser | ||||
parser = ConfigParser() | parser = ConfigParser() | ||||
# read config file | # read config file | ||||
parser.read(filename) | parser.read(filename) | ||||
▲ Show 20 Lines • Show All 49 Lines • Show Last 20 Lines |