# Number of blocks in a BABE session

**URL:** https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842
**Category:** Duniter-v2
**Created:** [8 January 2025 13:45 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842 "2025-01-08T13:45:33Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![HugoTrentesaux](https://forum.duniter.org/user_avatar/forum.duniter.org/hugotrentesaux/32/6396_2.png) [@HugoTrentesaux](https://forum.duniter.org/u/HugoTrentesaux)
#### Post date: [8 January 2025 13:45 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/1 "2025-01-08T13:45:33Z")

</div>

![image](https://forum.duniter.org/uploads/default/original/2X/8/8058532f7029bb8cb1e38eae183b323831a65ec0.png)

This is a plot of the number of blocks within a gdev session.

I was expecting it to be exactly 600 outside of periods with missing blocks but it seems to drop as low as 413 blocks for session 7194.

Seems I have to revise the definition of a session…

---

<div class="post-metadata">

### Author: ![HugoTrentesaux](https://forum.duniter.org/user_avatar/forum.duniter.org/hugotrentesaux/32/6396_2.png) [@HugoTrentesaux](https://forum.duniter.org/u/HugoTrentesaux)
#### Post date: [8 January 2025 13:48 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/2 "2025-01-08T13:48:19Z")

</div>

If we look at bloc [4125935](https://duniter-portal.axiom-team.fr/#/explorer/query/4125935) (beginning of session 7194), we see:

 ![image](https://forum.duniter.org/uploads/default/original/2X/e/e51553e0c8f8367e1139dee3a7b3a48b43680ae3.png)

Some offence and a lot of outgoing authorities.

---

<div class="post-metadata">

### Author: ![HugoTrentesaux](https://forum.duniter.org/user_avatar/forum.duniter.org/hugotrentesaux/32/6396_2.png) [@HugoTrentesaux](https://forum.duniter.org/u/HugoTrentesaux)
#### Post date: [8 January 2025 13:50 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/3 "2025-01-08T13:50:21Z")

</div>

It seems like a bug to see three times `authorityMembers.OutgoingAuthorities` 😱

→ [#281](https://git.duniter.org/nodes/rust/duniter-v2s/-/issues/281)

---

<div class="post-metadata">

### Author: ![tuxmain](https://forum.duniter.org/user_avatar/forum.duniter.org/tuxmain/32/6423_2.png) [@tuxmain](https://forum.duniter.org/u/tuxmain)
#### Post date: [8 January 2025 14:20 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/4 "2025-01-08T14:20:43Z")

</div>

> [@HugoTrentesaux](#):
>
> Seems I have to revise the definition of a session…

Why? If authorities expire or there is a bug that makes validators crash, the session has \<600 blocks, that’s normal.

The graph is even reassuring: it never drops under 2/3.

---

<div class="post-metadata">

### Author: ![HugoTrentesaux](https://forum.duniter.org/user_avatar/forum.duniter.org/hugotrentesaux/32/6396_2.png) [@HugoTrentesaux](https://forum.duniter.org/u/HugoTrentesaux)
#### Post date: [8 January 2025 14:23 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/5 "2025-01-08T14:23:11Z")

</div>

We have 2356 sessions with 600 blocks which is less than 30%. Are there so many bugs we did not see?

---

<div class="post-metadata">

### Author: ![HugoTrentesaux](https://forum.duniter.org/user_avatar/forum.duniter.org/hugotrentesaux/32/6396_2.png) [@HugoTrentesaux](https://forum.duniter.org/u/HugoTrentesaux)
#### Post date: [8 January 2025 17:07 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/6 "2025-01-08T17:07:35Z")

</div>

Voilà la répartition des intervalles de temps entre blocs de 4125935 à 4126348 (412 blocs de la session 7194 en 3564 secondes) :

 ![image](https://forum.duniter.org/uploads/default/original/2X/2/2d0c53828e9adb5b7c53602102180edac8fe6511.png)

- 283 à 6 secondes
- 90 à 12 secondes
- 29 à 18 secondes
- 5 à 24 secondes
- 2 à 30 secondes
- 0 à 36 secondes
- 2 à 42 secondes

Soit 283×1 + 90×2 + 29×3 + 5×4 + 2×5 + 2×7 = 594 slots sur 600 (j’ai juste oublié le premier et dernier bloc dans mes données).

Le bloc [4,126,014](https://duniter-portal.axiom-team.fr/#/explorer/query/4126014) vient 42 secondes après le précédent.

---

<div class="post-metadata">

### Author: ![HugoTrentesaux](https://forum.duniter.org/user_avatar/forum.duniter.org/hugotrentesaux/32/6396_2.png) [@HugoTrentesaux](https://forum.duniter.org/u/HugoTrentesaux)
#### Post date: [8 January 2025 21:00 UTC](https://forum.duniter.org/t/number-of-blocks-in-a-babe-session/12842/7 "2025-01-08T21:00:29Z")

</div>

![image](https://forum.duniter.org/uploads/default/original/2X/3/3e775295fbafe8ff80256301ce5d5fa01d2a1954.png)

Voilà la durée des sessions. La moyenne est à 3600 secondes (1h), et une session trop longue est composées par une session plus courte juste après, ça doit juste être une histoire de slot.
