@classmethod
def from_json(cls, filename: str) -> 'PackageAPI':
    "\n        Instantiate a Package object from a file.\n\n        :param filename: Name of the JSON file\n            that contains the description of the\n            target package's API.\n\n        "
    _log_info(f'Creating package from {filename}')
    with open(filename, 'r') as f:
        pkg_dict = json.loads(f.read())
    return cls(pkg_dict)
Instantiate a Package object from a file.

:param filename: Name of the JSON file
    that contains the description of the
    target package's API.
@classmethod
def from_json(cls, filename: str) -> 'PackageAPI':
    "\n        Instantiate a Package object from a file.\n\n        :param filename: Name of the JSON file\n            that contains the description of the\n            target package's API.\n\n        "
    _log_info(f'Creating package from {filename}')
    with open(filename, 'r') as f:
        pkg_dict = json.loads(f.read())
    return cls(pkg_dict)