Why the list of log entries is not displayed

Why does the entity I created not display log entries
my entity
Snipaste_2021-02-05_21-21-58

async def async_setup_platform(hass,
                               config,
                               async_add_devices,
                               discovery_info=None):
    _LOGGER.info("Successfully loaded.....")

    _my_entity = anysctestEntity("binary_sensor.00145442hmkh")
    creat_entiy = [_my_entity]
    async_add_devices(creat_entiy)

    async def _get_data(now):
        await _my_entity._update_status()
        async_call_later(hass, 6, _get_data)
    async_call_later(hass, 6, _get_data)


class anysctestEntity(BinarySensorEntity):

    def __init__(self,  unique_id):
        self._unique_id = unique_id
        self._status = False

    @property
    def name(self):
        return self._unique_id

    @property
    def unique_id(self):
        return self._unique_id

    @property
    def is_on(self):
        return self._status

    @property
    def device_state_attributes(self):
        return {"aa": "bb", "cc": "dd", "dd": "bb"}

    @property
    def should_poll(self):
        return False

    @property
    def device_class(self):
        return "motion"

    async def _update_status(self):
        self._status = not self._status
        _LOGGER.info("status:%s" % self._status)
        self.async_write_ha_state()

Have you excluded the sensor from the recorder?

Also, it’s History, not Logbook. Two different things.

No Settings excluded, this is the new entity I created for testing, no other Settings

Do you have default_config: or history: and recorder: in your configuration.yaml file?

There are no settings you said. I think it’s the relationship between my code, because other entities can be displayed, except the entities I created

If you don’t have either of those settings in your configuration.yaml file you would not see any sensor history.

But other third-party entities can be displayed without any settings

So the settings and entities are there somewhere.