Skip to content

Commit

Permalink
fix new ruff re errors
Browse files Browse the repository at this point in the history
  • Loading branch information
alexfikl committed Nov 22, 2024
1 parent 3371766 commit 2d1edd3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion contrib/cldis.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def main(ctx, tmp_dir, cl_str, output=None, build_options=()):
if output == "sass":
with open(os.path.join(tmp_dir, "cl.ptx"), "w") as f:
f.write(res)
tgt = re.findall(".target sm_[0-9]*", res, re.MULTILINE)[0]
tgt = re.findall(r".target sm_[0-9]*", res, re.MULTILINE)[0]
gpu_name = tgt[8:]
subprocess.check_call(["ptxas", "cl.ptx", "--verbose",
f"--gpu-name={gpu_name}", "--warn-on-spills"], cwd=tmp_dir)
Expand Down
2 changes: 1 addition & 1 deletion pyopencl/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@


VERSION_TEXT = metadata.version("pyopencl")
_match = re.match("^([0-9.]+)([a-z0-9]*?)$", VERSION_TEXT)
_match = re.match(r"^([0-9.]+)([a-z0-9]*?)$", VERSION_TEXT)
assert _match is not None
VERSION_STATUS = _match.group(2)
VERSION = tuple(int(nr) for nr in _match.group(1).split("."))

0 comments on commit 2d1edd3

Please sign in to comment.