HOME/Articles/

mysql example scorpio common util yamlUtil (snippet)

Article Outline

Python mysql example 'scorpio common util yamlUtil'

Functions in program:

  • def load_yaml(path):

Modules used in program:

  • import yaml

python scorpio common util yamlUtil

Python mysql example: scorpio common util yamlUtil

import yaml


def load_yaml(path):
    with open(path, encoding='utf-8') as f:
        return yaml.load(f)