Skip to content

Commit

Permalink
Release version 0.0.0.dev40
Browse files Browse the repository at this point in the history
  • Loading branch information
AAriam committed Sep 26, 2024
1 parent 9ac161b commit e1612e6
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 10 deletions.
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ namespaces = true
# ----------------------------------------- Project Metadata -------------------------------------
#
[project]
version = "0.0.0.dev39"
version = "0.0.0.dev40"
name = "LoggerMan"
dependencies = [
"MDit == 0.0.0.dev12",
"MDit == 0.0.0.dev13",
"ActionMan == 0.0.0.dev24",
"ProtocolMan == 0.0.0.dev2",
"ExceptionMan == 0.0.0.dev12",
"ExceptionMan == 0.0.0.dev13",
"pydantic",
"rich",
]
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MDit == 0.0.0.dev12
MDit == 0.0.0.dev13
ActionMan == 0.0.0.dev24
ProtocolMan == 0.0.0.dev2
ExceptionMan == 0.0.0.dev12
ExceptionMan == 0.0.0.dev13
pydantic
rich
14 changes: 9 additions & 5 deletions src/loggerman/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -391,11 +391,15 @@ def section(
self._next_section_num.append(1)
return

def section_end(self):
self._doc.close_section()
if len(self._next_section_num) > 1:
self._next_section_num.pop()
self._next_section_num[-1] += 1
@property
def current_section_level(self) -> int:
return self._doc.current_section_level

def section_end(self, target_level: int | None = None):
target_level = target_level or self.current_section_level - 1
self._doc.close_section(target_level=target_level)
self._next_section_num = self._next_section_num[:target_level]
self._next_section_num[-1] += 1
self._out_of_section = True
self._curr_list_key = None
return
Expand Down

0 comments on commit e1612e6

Please sign in to comment.