Technically you could be streaming on YouTube forever. However, if your YouTube live stream is longer than 12 hours, it may not be captured for you to save and post later. YouTube will automatically archive any streams that are under 12 hours.
YouTube does have daily limits for the number of live streams you post in 24 hours. This number goes up the more your channel is verified (proving identity with an ID will allow you more YouTube live streams than only providing your phone number), and if your channel doesn’t have a lot of strikes.