lastorel / pytion

Unofficial Python client for official Notion API
GNU General Public License v3.0
44 stars 3 forks source link

2022-06-28 version release #27

Closed lastorel closed 2 years ago

lastorel commented 2 years ago

After checking news and changelogs Release Changelog I can't find any detailed info

I will try to check it manually

lastorel commented 2 years ago

https://developers.notion.com/reference/changes-by-version

lastorel commented 2 years ago

Wow, such changes...

Method

version 2022-02-22:

{
    "properties": {
        "title": {
            "id": "title",
            "type": "title",
            "title": [
                {
                    "type": "text",
                    "text": {
                        "content": "Pytion Tests",
                        "link": null
                    },
                    "annotations": {
                        "bold": false,
                        "italic": false,
                        "strikethrough": false,
                        "underline": false,
                        "code": false,
                        "color": "default"
                    },
                    "plain_text": "Pytion Tests",
                    "href": null
                }
            ]
        }
    }
}

version 2022-06-28:

{
    "properties": {
        "title": {
            "id": "title"
        }
    }
}
lastorel commented 2 years ago

Wow, such changes...

Method

version 2022-02-22:

{
  "properties": {
      "title": {
          "id": "title",
          "type": "title",
          "title": [
              {
                  "type": "text",
                  "text": {
                      "content": "Pytion Tests",
                      "link": null
                  },
                  "annotations": {
                      "bold": false,
                      "italic": false,
                      "strikethrough": false,
                      "underline": false,
                      "code": false,
                      "color": "default"
                  },
                  "plain_text": "Pytion Tests",
                  "href": null
              }
          ]
      }
  }
}

version 2022-06-28:

{
  "properties": {
      "title": {
          "id": "title"
      }
  }
}

Page properties must be retrieved using the page properties endpoint. (c)

lastorel commented 2 years ago

Page can be created in inline mention mode. The block has still "paragraph" type.
Another way is "link to page" mode. The block has "child_page" type. You can not add another inline text into that block.

Parents are now always direct parents (c)

I have the page created in inline mention mode, When I try to resolve "parent" of that page, I see different result.

Another change is adding parent to block objects.

a parent field has been added to block. (c)

Well I see parent field added to BOTH versions

version 2022-02-22:

{
    "object": "block",
    "id": "8a920ba7-dc1d-4961-811e-5c82b28028ed",
    "parent": {
        "type": "page_id",
        "page_id": "82ee5677-402f-4481-9a5d-a3302273400a"
    },
    "created_time": "2022-04-24T09:56:00.000Z",
    "last_edited_time": "2022-04-24T13:13:00.000Z",
}

version 2022-06-28:

{
    "object": "block",
    "id": "8a920ba7-dc1d-4961-811e-5c82b28028ed",
    "parent": {
        "type": "page_id",
        "page_id": "82ee5677-402f-4481-9a5d-a3302273400a"
    },
    "created_time": "2022-04-24T09:56:00.000Z",
    "last_edited_time": "2022-04-24T13:13:00.000Z",
}

Is it a real fix for hierarchical navigation?

lastorel commented 2 years ago

Database relations have a type of single_property and dual_property. (c)