State lawmakers agreed Maryland's medical marijuana program was a flop, but only this weekend reached a tentative compromise on how to invent a medical marijuana industry from scratch.

Both chambers passed bills to expand access to the drug, but face a Monday deadline to decide how many growers should be allowed to cultivate it and where patients could go to fill a prescription. 

Key lawmakers working to revamp the state’s medical marijuana law came to an agreement Friday.

Only 15 growers would get licenses in the first year, but the state’s medical marijuana commission could decide to allow more under a compromise reached between House sponsors and a Senate medical marijuana work group.

Growers would also be allowed to distribute the drug through dispensaries, but other properly licensed businesses could set up shop as dispensaries as well. The medical marijuana commission would set and enforce scores of rules about how growers and dispensaries could operate.

Lawmakers first created a medical marijuana program last year, but it relied on academic centers to distribute the drug and none volunteered to participate. 

The new proposal, expected to get a final vote Monday, would allow patients to get a prescription from specially licensed physicians and then fill it at dispensaries across the state.