Skip to content

Commit

Permalink
🩹Strip descriptions (#866)
Browse files Browse the repository at this point in the history
  • Loading branch information
lord-haffi authored Jul 30, 2024
1 parent 713a24d commit 0841f83
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/bo4e/utils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ def add_comments_to_description(cls: type[T]) -> type[T]:

for field_name, field_info in cls.model_fields.items():
if field_info.description is not None:
field_info.description = field_info.description.strip()
continue
# search for (single line) comments above the field
match = re.search(regex_comment_above.format(field_name=field_name), fields_code)
Expand Down

0 comments on commit 0841f83

Please sign in to comment.