Skip to content

Commit 4c6efec

Browse files
Address review feedback: list[object] and NotImplementedError
Co-authored-by: nathanjmcdougall <18602289+nathanjmcdougall@users.noreply.github.com>
1 parent 299895a commit 4c6efec

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

src/usethis/_file/yaml/update.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def update_ruamel_yaml_map(
6464
cmap[key] = cmap_copy[key]
6565

6666

67-
def lcs_list_update(original: list[Any], new: list[Any]) -> None:
67+
def lcs_list_update(original: list[object], new: list[object]) -> None:
6868
"""Update in-place using a longest common subsequence solver.
6969
7070
This makes `original` identical to `new`, but respects subtypes of list such as

src/usethis/_pipeweld/func.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,8 @@ def _insert_before_postrequisites(
252252
)
253253
union = _union(successor_component, self.step)
254254
if len(container) == 1 and container[0] == union:
255-
assert union is not None
255+
if union is None:
256+
raise NotImplementedError
256257
component[idx + 1] = union
257258

258259
return instructions

0 commit comments

Comments
 (0)