ModuleNotFoundError:没有名为“common.config”的模块oanda api python

ModuleNotFoundError:没有名为“common.config”的模块oanda api python,python,oanda,Python,Oanda,我正在尝试使用juypter笔记本连接Oanda REST API,代码如下: #!/usr/bin/env python import sys import select import argparse import common.config from .account import Account def main(): """ Create an API context, and use it to fetch an Account s

我正在尝试使用juypter笔记本连接Oanda REST API,代码如下:

#!/usr/bin/env python

import sys
import select
import argparse
import common.config
from .account import Account


def main():
    """
    Create an API context, and use it to fetch an Account state and then
    continually poll for changes to it.
    The configuration for the context and Account to fetch is parsed from the
    config file provided as an argument.
    """

    parser = argparse.ArgumentParser()

    #
    # The config object is initialized by the argument parser, and contains
    # the REST APID host, port, accountID, etc.
    #
    common.config.add_argument(parser)

    parser.add_argument(
        "--poll-interval",
        type=int,
        default=5,
        help="The number of seconds between polls for Account changes"
    )

    args = parser.parse_args()

    account_id = args.config.active_account

    #
    # The v20 config object creates the v20.Context for us based on the
    # contents of the config file.
    #
    api = args.config.create_context()

    #
    # Fetch the details of the Account found in the config file
    #
    response = api.account.get(account_id)

    #
    # Extract the Account representation from the response and use
    # it to create an Account wrapper
    #
    account = Account(
        response.get("account", "200")
    )

    def dump():
        account.dump()

        print("Press <ENTER> to see current state for Account {}".format(
            account.details.id
        ))

    dump()

    while True:
        i, _, _ = select.select([sys.stdin], [], [], args.poll_interval)

        if i:
            sys.stdin.readline()
            dump()

        #
        # Poll for all changes to the account since the last
        # Account Transaction ID that was seen
        #
        response = api.account.changes(
            account_id,
            sinceTransactionID=account.details.lastTransactionID
        )

        account.apply_changes(
            response.get(
                "changes",
                "200"
            )
        )

        account.apply_state(
            response.get(
                "state",
                "200"
            )
        )

        account.details.lastTransactionID = response.get(
            "lastTransactionID",
            "200"
        )


if __name__ == "__main__":
    main()

它显示了以下错误:

ModuleNotFoundError回溯上次最近的调用 在-->1中导入common.view 2从position.view导入打印位置地图3从order.view 从交易导入打印订单地图4。查看导入打印交易地图5 ModuleNotFoundError:没有名为“common.view”的模块


我正在尝试使用juypter笔记本连接到Oanda REST API。它正在显示此错误。---------------------------------------ModuleNotFoundError跟踪-->1导入通用.view 2 from position.view导入打印位置\u map 3 from order.view导入打印订单\u map 4 from trade.view导入打印交易\u map 5 ModuleNotFoundError:没有名为“common.view”的模块