We study the electronic transport through a finite-size slit in a barrier in a two-dimensional sample in the hydrodynamic regime. We assume a negligible disorder-induced Ohmic resistance, so that dissipation is purely viscosity-induced. We find that the only solution to the Stokes equation in this geometry, which yields a finite dissipation at finite resistance (and, hence, is not self-contradictory), is the one that fulfills both the no-stress and no-slip boundary conditions simultaneously. As a remarkable consequence, the obtained velocity profile satisfies the so-called "partial-slip" (Maxwell) boundary condition for any value of the slip length λ, which drops out from all final results. We also calculate the electronic temperature profile for the small and large heat conductivity, and find asymmetric (with respect to the barrier) temperature patterns in the former case.