Skip to content
  • Projects
  • Groups
  • Snippets
  • Help

Owo Sugiana / async-web

  • This project
    • Loading...
  • Sign in
Go to a project
  • Project
  • Repository
  • Issues 0
  • Merge Requests 0
  • Pipelines
  • Wiki
  • Settings
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Branches
  • Tags
  • Contributors
  • Graph
  • Compare
  • Charts
Switch branch/tag
  • async-web
  • async_web
  • read_conf.py
  • Owo Sugiana's avatar
    Kali pertama · 6c90ccc2
    Owo Sugiana committed Mar 07, 2023
    6c90ccc2
read_conf.py 398 Bytes
RawBlameHistoryPermalink
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
def get_module_object(name):
    module_obj = __import__(name)
    sub_obj = None
    for sub in name.split('.')[1:]:
        if sub_obj:
            sub_obj = getattr(sub_obj, sub)
        else:
            sub_obj = getattr(module_obj, sub)
    return sub_obj


def str2dict(s):
    r = dict()
    for token in s.split():
        key, value = token.split(':')
        r[key] = value
    return r