There currently is one option to travel by night train from Budapest (Hungary) to Lviv (Ukraine), taking approximately 13 hours: Namely the 10 operated by MÁV-Start.
MÁV-Start, Hungary's national passenger railway, operates domestic and cross-border trains throughout the region.