b4cb0c14ebf600daa5573bc90a419eb24329eb55,api/python/quilt3/packages.py,Package,install,#Any#Any#Any#Any#Any#Any#,315

Before Change


                raise QuiltException("No registry specified and no default remote "
                                     "registry configured. Please specify a registry "
                                     "or configure a default remote registry with quilt.config")
        elif registry == "local":
            registry = get_from_config("default_local_registry")

        if dest_registry is None:
            dest_registry = get_from_config("default_local_registry")

        pkg = cls.browse(name=name, registry=registry, top_hash=top_hash)

        if dest is None:
            dest = get_install_location()

        return pkg.push(name=name, dest=dest, registry=dest_registry)


    @classmethod
    def browse(cls, name=None, registry=None, top_hash=None):

After Change


                )

        if dest is None:
            dest = get_install_location().rstrip("/") + "/" + quote(name)
        else:
            dest_parsed = urlparse(fix_url(dest))
            if dest_parsed.scheme != "file":
                raise QuiltException(
                    f"Invalid package destination path {dest!r}. "dest", if set, must point at "
                    f"the local filesystem. To copy a package to a remote registry use "push" or "
                    f""build" instead."
                )

        pkg = cls.browse(name=name, registry=registry, top_hash=top_hash)
        dest = fix_url(dest)
        message = pkg._meta.get("message", None)  // propagate the package message

        pkg = pkg._materialize(dest)
        pkg.build(name, registry=dest_registry, message=message)
        return pkg

    @classmethod
    def browse(cls, name=None, registry=None, top_hash=None):
        
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: quiltdata/quilt
Commit Name: b4cb0c14ebf600daa5573bc90a419eb24329eb55
Time: 2019-06-05
Author: aleksey@residentmar.io
File Name: api/python/quilt3/packages.py
Class Name: Package
Method Name: install


Project Name: jbms/beancount-import
Commit Name: 0dbf54864563b1d4d19a68c0cf42b99e63610da4
Time: 2018-10-30
Author: jeremy@jeremyms.com
File Name: beancount_import/test_util.py
Class Name:
Method Name: format_entries


Project Name: pytorch/text
Commit Name: 3aa4d13e15bea9a6bca68a4261b50c433400eb6e
Time: 2017-09-07
Author: nelson-liu@users.noreply.github.com
File Name: torchtext/data/example.py
Class Name: Example
Method Name: fromCSV