To cheers from senators, Lt. Gov. Dan Forest, the Senate's presiding officer, gaveled out his chamber shortly after 4 a.m. A similar sight followed less than 10 minutes later in the House, led by Speaker Tim Moore, R-Cleveland. Both chambers had just finalized a large "technical corrections" bill. A proposed $2 billion bond issue got final approval just after midnight.
The term began in mid-January and turned out to be the longest budget-writing session since 2001.
Here's a look at what got addressed — or not — in the session's final hours:
The legislature completed its annual effort to reduce and streamline environmental rules and other regulations that Republicans say finds balance between protecting nature and reducing burdens upon business.
"It is clean, green and not extreme," said Rep. Pat McElraft, R-Carteret, before the House finalized a compromise with the Senate by a vote of 73-39. "There is nothing in the bill that will help anyone pollute or decrease the air quality in our state."
Environmental groups and most Democrats disagreed with the assessment, critical of provisions in the bill that in part would allow companies who determine they are violating environmental rules to avoid civil penalties if they conduct compliance audits. Other businesses otherwise working to keep their noses clean wouldn't have such a break.
"We're going to punish companies that are doing the right thing," said Rep. Pricey Harrison, D-Guilford. Small tracts of wetlands and streams that only flow during rainy seasons also would receive reduced protections. "I'm bothered by these continued roadblocks in environmental protection," Harrison added.
The "technical corrections" bill addressed concerns by many lawmakers about a separate measure also heading to Gov. Pat McCrory that's related to immigration.
The original bill approved Tuesday night would prevent government officials and police from using certain identification documents from foreign governments called "matricula consulars" and those issued by local governments and organizations to determine a person's ID or residency.
According to lawmakers, police were worried about the inability to use some ID documents that would make their jobs harder in recognizing potential criminal suspects. So the other "technical" measure added a provision stating police could use ID cards created by local governments or nonprofits to help determine residency or identity if needed.
What doesn't change is a provision that would block local government policies instructing law enforcement and other officials not to ask the immigration status of people with whom they come into contact.
A bill heading to McCrory that would have required more information be released to the public about the current search for the successor to University of North Carolina system President Tom Ross got scaled back just before adjournment.
The House had agreed earlier in the week to attach disclosures to a measure placing term limits on UNC Board of Governors members. They would have forced the names of three finalists and their credentials to be made public and demanded at least one public meeting to discuss the three.
But Rep. Nelson Dollar, R-Wake, offered a new amendment that removed the release of three names and the public meeting to discuss the finalists. He said confidentiality was crucial in recruiting the best candidates for a high-level job.
WHAT ELSE PASSED
A wide-ranging farm regulation bill passed. Beaufort County residents who want the Pungo Hospital in Belhaven to reopen would get help from legislation to let the hospital avoid revisiting some regulatory hurdles.
The final technical corrections bill also adjusts some campaign finance changes on McCrory's desk that would allow the partisan House and Senate caucuses to create campaign committees that would bypass state parties.
WHAT DIDN'T SURVIVE
Left on the table until at least next year is a bill that would have earmarked more local school districts funds for charter schools.
Another deferred measure attempted to crack down on employers purposefully mislabeling workers as independent contractors to avoid paying taxes and employee benefits. Part of the hang up stemmed from a Senate effort to remove an exemption newspapers have had to treat paper carriers as independent contractors.
An effort by some House and Senate Republicans to block current or future local government ordinances that place specific requirements on businesses on employee pay, housing and landlord-tenant relationships also got derailed.
Barring a veto by McCrory that would cause lawmakers to return to attempt an override, the North Carolina legislature isn't supposed to reconvene until next April 25. Some legislators will return occasionally for government oversight committees and study panels.
A bill on McCrory's desk shifting all primary elections to March, meaning lawmakers facing challengers from their own party will have to focus on campaign fundraising earlier.