Mine runs on 4x AA batteries, which lasts a very long time. On the order of a year. Cutting electricity would indeed prevent the notification, but a dumb lock couldn’t send one even with all the power in the world.
Plus, in a shared apartment/condo building the power is much less likely to be cut and in a freestanding home one could theoretically put their network on a UPS so any notifications would still go out.