California is in trouble. According to a much-discussed recent L.A. Times article, the state has only about a year’s worth of water in its reservoirs, which, if depleted, would leave the state reliant on groundwater and praying for heavy snows in winter. Already, the state is tightening water use restrictions, especially for uses like watering lawns, but many think that won’t nearly be enough to dig California out of its dry, parched, cracked hole.

Weirdly, this is opening a new avenue of revenue for California farmers. In the Sacramento Valley, northeast of San Francisco, farmers are actually selling water to the state, for exorbitant fees. That’s due to the way the drought-prone state deals with allocating water.

Farmers are given “water rights,” essentially rations of water, based on size and output. When California analyzes how dire its drought situation is, it doesn’t count the water allocated to farmers; that water is no longer California’s to give. That means instead of growing crops, the farmers in the region have decided to actually sell about 20 percent their water to the state, at the price of $700 per acre-foot of water. An acre-foot is a unit of volume; imagine a swimming pool that’s the size of an acre and a foot deep. It’s equal to about 325,000 gallons of water.

It’s obviously dangerous to encourage farmers to cease growing in order to make sure the state has water, but what’s the alternative? And at least this way, the farmers are guaranteed to have a pretty good year.

Correction: An earlier version of this post had some incorrect math in defining what an acre-foot is. We apologize for the confusion.