Earlier this spring, it looked like Virginia had the wind at its back in the state’s quest to become a leader in alternative energy. But that smooth sailing has hit rough waters.

Gamesa Energy and Huntington Ingalls Industries, which had jointly announced plans to build the state’s first offshore wind turbine, pulled the plug on the project. Gamesa will instead focus on building the turbine off the coast of the Spanish Canary Islands, where there are fewer regulatory hurdles.

Gamesa spokeswoman Susana Sanjuan said the company has been committed to Virginia, but switched gears because of uncertainty on federal energy policy, possible tax breaks, a committed market for wind power, and an offshore grid to carry the electricity.

In March, the Virginia Marine Resources Commission unanimously approved a permit for Gamesa to develop a prototype turbine, which would have shown interested investors and regulators how much wind could be generated and how much it would cost.

The turbine would have generated enough electricity to power 1,250 homes.

Virginia Gov. Bob McDonnell told reporters he was disappointed that the partnership couldn’t make it work, but he understood the hazards of moving forward in the face of an uncertain energy policy.

McDonnell and the state have embraced wind and the jobs it could bring, especially to an area like Norfolk, which has a ready workforce thanks to skilled port and shipbuilding jobs.

There are still plans to lease 113,000 acres of federal waters off the coast of Virginia

Beach for wind power development. Eight companies have expressed interest in the leases.