#!/usr/bin/python import requests, re, json, os, yaml from db import * from aliexpress import * def get_conf(): '''return settings in settings.yaml file''' with open(os.path.dirname(os.path.realpath(__file__))+"/settings.yaml", 'r') as conf_file: settings = yaml.safe_load(conf_file) return settings if __name__ == '__main__': settings = get_conf() print(check_items(settings["id"])) connection = connect_db(settings["db"]) close_db(connection)