For years, lawmakers have struggled to balance reducing government spending while maintaining funding for essential services.