There are pressures from different groups. when there is shortage in market and consumers pressurize, the ban on export is enforced. But farmers dislike such ban as they want profit on exports. Then on pressure of farmers, ban is removed.
Unexpected natural calamities at different places are causing scarcity of food item. I dont think exporting to foreign countries is good at this time though it is profitable. however it is good to know that government has found some profit out of lifting this ban.