<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def from_path(filename):
 """Creates a sourcemap view from a file path."""

        filename = to_bytes(filename)
        if NULL_BYTE in filename:
            raise ValueError('null byte in path')
        return ProguardView._from_ptr(rustcall(
            _lib.lsm_proguard_mapping_from_path,
            filename + b'\x00'))