It was brilliant PR move to earmark the tax revenue for education, there's no doubt about that. It's very hard to argue with such things, and many other states have opted to dedicate certain "sin taxes" to select public works. For example, earmarking some funds for veterans affairs out of state lottery tickets as my state (Iowa) does, or education as many more states do.
On the surface, this seems like a brilliant way to justify revenue collection for what many citizens would consider unseemly or undignified. It is an effective sales pitch to say to a voter, "You may disagree with marijuana legalization, but it will bring in $50 million dollars to state schools."
The problem is that budgets will adjust to incorporate this earmark for future years. That is, education budgets are likely to reflect this revenue for future years. That's precisely what has happened in so many states where state lottery revenues have been earmarked for education and other noble causes. John Oliver's Last Week Tonight had an excellent take on a similar topic: the "sin tax" of state lottery tickets. See here: https://www.youtube.com/watch?v=9PK-netuhHA
It is wonderful that marijuana taxes are going to a good cause. It is dangerous to make education funding dependent on a volatile tax source, and the evidence suggests that is exactly what will happen.