notionary 0.1.23__py3-none-any.whl → 0.1.24__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -46,7 +46,7 @@ class NotionClient(LoggingMixin):
46
46
  for instance in list(cls._instances):
47
47
  await instance.close()
48
48
 
49
- async def close(self): #
49
+ async def close(self):
50
50
  """
51
51
  Closes the HTTP client for this instance and releases resources.
52
52
  """
@@ -32,13 +32,21 @@ class PageContentManager(LoggingMixin):
32
32
  )
33
33
  self._chunker = NotionPageContentChunker()
34
34
 
35
- async def append_markdown(self, markdown_text: str) -> str:
35
+ async def append_markdown(self, markdown_text: str, append_divider: bool = False) -> str:
36
36
  """
37
37
  Append markdown text to a Notion page, automatically handling content length limits.
38
38
  First strips out triple backtick markdown fences if they wrap the entire content.
39
+
40
+ Args:
41
+ markdown_text: The markdown text to append
42
+ append_divider: If True, appends a divider after the markdown content (default: False)
39
43
  """
40
44
  try:
41
45
  blocks = self._markdown_to_notion_converter.convert(markdown_text)
46
+
47
+ if append_divider:
48
+ divider_block = {"type": "divider", "divider": {}}
49
+ blocks.append(divider_block)
42
50
 
43
51
  fixed_blocks = self._chunker.fix_blocks_content_length(blocks)
44
52
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: notionary
3
- Version: 0.1.23
3
+ Version: 0.1.24
4
4
  Summary: A toolkit to convert between Markdown and Notion blocks
5
5
  Home-page: https://github.com/mathisarends/notionary
6
6
  Author: Mathis Arends
@@ -1,5 +1,5 @@
1
1
  notionary/__init__.py,sha256=ypCkbF1YEcwy5aE2kGFmtJOZq41Vs01lahJNqRO27fU,735
2
- notionary/notion_client.py,sha256=9oYhjY-OhFzACP-gHczDx1sif-YzmjFKX3CmluJBeIw,6038
2
+ notionary/notion_client.py,sha256=6YhaDK9UjH18Q0f1bxVVNGMbCvpQhatse6WRVIARGCE,6035
3
3
  notionary/database/database_discovery.py,sha256=qDGFhXG9s-_6CXdRg8tMiwX4dvX7jLjgAUFPSNlYtlI,4506
4
4
  notionary/database/database_info_service.py,sha256=Ig6gx8jUSPYORJvfgEV5kV6t72pZQsWU8HPMqd43B-o,1336
5
5
  notionary/database/notion_database.py,sha256=YCOuzrWfKRJvMiWdVfEt8i3NAEqpKDwHj5SX4GUraEk,8017
@@ -36,7 +36,7 @@ notionary/page/notion_page.py,sha256=pJSy-vWFqQdCqmtFifL9AdUZpWoM0DzfblRBBBUTsTI
36
36
  notionary/page/notion_page_factory.py,sha256=UUEZ-cyEWL0OMVPrgjc4vJdcplEa1bO2yHCYooACYC8,8189
37
37
  notionary/page/notion_to_markdown_converter.py,sha256=qZIeZjDpeGFgW5RGTrcfi0mVI6NT0VvXeHM7jpP6ZHo,8067
38
38
  notionary/page/content/notion_page_content_chunker.py,sha256=xRks74Dqec-De6-AVTxMPnXs-MSJBzSm1HfJfaHiKr8,3330
39
- notionary/page/content/page_content_manager.py,sha256=u-OAMLNKrbuBjifh2PAKxW3L9fM0sbeHrW94etedsPw,6215
39
+ notionary/page/content/page_content_manager.py,sha256=qZqd9xMrpatxgIjw-DK0XSr7adXKzPZpF-bPRO4LQy4,6586
40
40
  notionary/page/metadata/metadata_editor.py,sha256=61uiw8oB25O8ePhytoJvZDetuof5sjPoM6aoHZGo4wc,4949
41
41
  notionary/page/metadata/notion_icon_manager.py,sha256=ixZrWsHGVpmF05Ncy9LCt8vZlKAQHYFZW-2yI5JZZDI,1426
42
42
  notionary/page/metadata/notion_page_cover_manager.py,sha256=qgQxQE-bx4oWjLFUQvpXD5GzO1Mx7w7htz1xC2BOqUg,1717
@@ -51,8 +51,8 @@ notionary/page/relations/page_database_relation.py,sha256=F9aGXFjjL8ZLNbfTGeGm_Q
51
51
  notionary/page/relations/relation_operation_result.py,sha256=NDxBzGntOxc_89ti-HG8xDSqfY6PwyGHKHrrKbCzNjM,5010
52
52
  notionary/util/logging_mixin.py,sha256=fKsx9t90bwvL74ZX3dU-sXdC4TZCQyO6qU9I8txkw_U,1369
53
53
  notionary/util/page_id_utils.py,sha256=EYNMxgf-7ghzL5K8lKZBZfW7g5CsdY0Xuj4IYmU8RPk,1381
54
- notionary-0.1.23.dist-info/licenses/LICENSE,sha256=zOm3cRT1qD49eg7vgw95MI79rpUAZa1kRBFwL2FkAr8,1120
55
- notionary-0.1.23.dist-info/METADATA,sha256=9AUWVqDZ8PtJ6N_NvHzVDdCcw3MCxGrIuOC06JCJ3jY,8342
56
- notionary-0.1.23.dist-info/WHEEL,sha256=SmOxYU7pzNKBqASvQJ7DjX3XGUF92lrGhMb3R6_iiqI,91
57
- notionary-0.1.23.dist-info/top_level.txt,sha256=fhONa6BMHQXqthx5PanWGbPL0b8rdFqhrJKVLf_adSs,10
58
- notionary-0.1.23.dist-info/RECORD,,
54
+ notionary-0.1.24.dist-info/licenses/LICENSE,sha256=zOm3cRT1qD49eg7vgw95MI79rpUAZa1kRBFwL2FkAr8,1120
55
+ notionary-0.1.24.dist-info/METADATA,sha256=tmm7v4gJBKvISXtf4aZcEkirizEGlBtZYxfZOwUKnOk,8342
56
+ notionary-0.1.24.dist-info/WHEEL,sha256=SmOxYU7pzNKBqASvQJ7DjX3XGUF92lrGhMb3R6_iiqI,91
57
+ notionary-0.1.24.dist-info/top_level.txt,sha256=fhONa6BMHQXqthx5PanWGbPL0b8rdFqhrJKVLf_adSs,10
58
+ notionary-0.1.24.dist-info/RECORD,,