Boundary-layer elements are tagged in a non-standard manner
Boundary-layer elements receive additional tags that seem to indicate the layer to which layer they belong. These tags interfere with the specification of partitions as described in Gmsh's doc and as interpreted by the "Inspect" feature.
Steps to reproduce: generate the mesh for the attached geometry, observe the varying partition number in the boundary layer with the "Inspect" feature of the GUI.
Problem found in version 4.0.2-git-ac4decc2.
Workaround: Re-partition the mesh (possibly with 1 partition), the boundary-layer tags are then overridden.