Thread Barriers synchronize a fixed number of participants at a shared phase boundary. Each participant reaches the boundary by calling wait, and the barrier releases the group when the required number has arrived. The same object can be reused for another phase, but a broken barrier follows a different path from a successful release.
The Python threading barrier reference defines the primitive for a fixed party count. A three-party example therefore needs three participating wait calls before that phase can pass. Two completed arrivals are not enough simply because their own preliminary work has finished.
Imagine threads A, B and C performing invented preparation steps. A arrives first and waits. B then arrives and waits. When C reaches the same barrier, the required count is complete and the phase is released. This is a synchronization example rather than a measured schedule from an operating robot or a promise about wall-clock arrival times.
Release makes the waiting participants able to continue. It does not require them to execute their next instructions at the same physical instant or in a fixed order. Scheduling after release is separate from the barrier condition that allows the group to proceed.

Each successful wait returns a different integer from zero through the party count minus one. Code can use one selected value to choose a single participant for additional bookkeeping. The documented property is uniqueness within that release, rather than a permanent thread identity attached to that number.
The CPython 3.14.0 Barrier implementation assigns an index from the current arrival count while holding its condition lock. It also keeps filling and draining states, so a participant entering the next phase cannot mix its new arrival into a release that is still draining from the previous one.
After the last participant exits a successful draining phase, the internal count is zero and the state returns to filling. A new phase then has its own arrivals. Reusing the barrier is therefore different from leaving a permanent event flag set after the first group passed.
A constructor action, when supplied, runs once through one participant before the successful group is released. Its existence does not mean that every participant independently runs the same action. Nor should an action be confused with the later bookkeeping code selected through a returned index.
If that action raises an exception, the source marks the barrier broken and wakes its waiters before re-raising the action's exception in the executing participant. Waiting participants encounter the broken-barrier path. It would be inaccurate to describe that branch as an ordinary successful release with a missing action result.
A participant can wait indefinitely if a required party never arrives and no timeout or abort occurs. Under the documented timeout behavior, a timed-out wait breaks the barrier and raises BrokenBarrierError. Other waiting participants are also released from their wait through failure, rather than being told that the required party count was satisfied.
Calling abort puts the barrier into its broken state. Active and future wait calls then fail with BrokenBarrierError. The second diagram shows A and B waiting while C never contributes an arrival, followed by abort. No third successful arrival is invented to make the picture look complete.

The barrier itself does not own a queue of preparation jobs or test whether their results satisfy an application-specific condition. The program decides when each participant reaches wait. If a participant calls it before producing its expected data, the arrival still contributes to the required count. If it finishes useful work but never calls wait, that work does not count as a barrier arrival. This separation helps explain both a premature successful phase and a phase that never releases: the primitive coordinates the calls it receives, while the surrounding application defines what those calls mean.
Reset returns the barrier toward its initial empty state and makes current waiters receive BrokenBarrierError. It does not complete C's missing preparation, undo work A already performed or automatically move every participant into the same new application phase. The reference notes that coordinating a reset may require synchronization outside the barrier.
The properties parties, n_waiting and broken describe different things: required participation, a current waiting count, and failure state. A momentary waiting count alone does not certify that the application's data is ready. Preserve the phase definition and failure handling beside the party count. Related explanations appear in the programming reference collection and the technical article library.