How to use the reprozip.common.File.__init__ function in reprozip

To help you get started, we’ve selected a few reprozip examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github VIDA-NYU / reprozip / reprozip / reprozip / tracer / trace.py View on Github external
def __init__(self, path):
        path = Path(path)
        size = None
        if path.exists():
            if path.is_link():
                self.comment = "Link to %s" % path.read_link(absolute=True)
            elif path.is_dir():
                self.comment = "Directory"
            else:
                size = path.size()
                self.comment = hsize(size)
        self.what = None
        self.runs = defaultdict(lambda: None)
        File.__init__(self, path, size)
github VIDA-NYU / reprozip / reprozip / reprozip / tracer / trace.py View on Github external
def __init__(self, path):
        path = Path(path)
        size = None
        if path.exists():
            if path.is_link():
                self.comment = "Link to %s" % path.read_link(absolute=True)
            elif path.is_dir():
                self.comment = "Directory"
            else:
                size = path.size()
                self.comment = hsize(size)
        self.what = None
        self.runs = defaultdict(lambda: None)
        File.__init__(self, path, size)