Hi,
Yes, the mass action system will logout the users when it changes their user groups.
That's because Joomla caches the user groups data of the current user in its user session.
And thus if a mass action changes the user groups without logging out the corresponding users, they wouldn't see any change until they logout and login again.
So we force the logout as the mass action system cannot clear the user session caching data as it can be done from other user sessions where that information is not accessible to it.
Now regarding the cart, you have a setting "clean cart when order is" in the HikaShop configuration.
If that setting is set to "created", then the cart data will be cleared when the order is created, before the user is redirected to the payment gateway for the payment.
If that setting is set to "confirmed", then the cart data will be cleared when the customer comes back from the payment gateway, just before displaying the thank you page.
If you set that setting to "confirmed" and you have a mass action forcefully logging out the user when the order is confirmed (so after the payment, but before the user is redirected back to the website), the user will indeed be redirected to the login form, and the cart won't be cleared.
In that case, I would recommend changing that setting to "created" so that the cart is cleared before the redirection to the payment gateway.