Skip to content

Commit

Permalink
fixes bug when 'docker ps' has trailing whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
dmalan committed Nov 19, 2023
1 parent a420ffe commit 91551b3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cli50/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def main():
else:
containers = []
for line in stdout.rstrip().splitlines():
ID, Image, RunningFor, Status, *Mounts = line.split("\t")
ID, Image, RunningFor, Status, *Mounts = line.rstrip().split("\t")
Mounts = Mounts[0].split(",") if Mounts else []
Mounts = [re.sub(r"^/host_mnt", "", Mount) for Mount in Mounts if not re.match(r"^[0-9a-fA-F]{64}$", Mount)] # Ignore hashes
containers.append((ID, Image, RunningFor.lower(), Status.lower(), Mounts))
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@
"console_scripts": ["cli50=cli50.__main__:main"]
},
url="https://github.com/cs50/cli50",
version="7.4.0",
version="7.4.1",
include_package_data=True
)

0 comments on commit 91551b3

Please sign in to comment.