Yes, a tree can recover from Bagworms until the full trees have not become brown, which means if there’s no green foliage- this is considered as a dead tree. At that time, there will be no possibility for the trees to be recovered from the Bagworms.
If the trees have green foliage even after being eradicated by the Bagworms, the trees can still grow if their shoots are strong enough to repair, but it will take many years to recover.