Skip to content

Commit

Permalink
Allow for whitespace in kernelspec regex
Browse files Browse the repository at this point in the history
  • Loading branch information
ana-v-espinoza committed Oct 14, 2024
1 parent 18ff930 commit 7dbec0b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jupyter-images/fall-2024/csm/default_kernel.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def update_kernelspec_in_notebooks(directory, new_name):
# (including nested structures), preserving the overall structure
# and formatting of the file.
updated_contents = re.sub(
r'"kernelspec": \{.*?\}',
r'"kernelspec": *\{.*?\}',
f'"kernelspec": {updated_kernelspec}',
file_contents, flags=re.DOTALL
)
Expand Down

0 comments on commit 7dbec0b

Please sign in to comment.