Question: How to solve this first order ode?

Maple 2026 can't solve this first textbook  ode. Book gives solution in the back which Mathematica gives, but for some strange reason, Maple dsolve can't solve it with the IC given. I also tried Maple 2025, it can't solve it.

ode:=diff(y(x),x)*sin(2*x) = 2*y(x)+2*cos(x); 
ic:=y(1/2*Pi) = 0; 
sol:=dsolve([ode,ic]);

No solution. returns ()

But this is the solution from book which Maple verfies is correct

book_sol:=y(x)=tan(x)-sec(x);
odetest(book_sol,[ode,ic])

gives [0,0]

Here is Mathematica also

Why Maple can't solve it? ofcourse it is not a bug not to be able to solve an ode, but Maple being the best ode solver in the world should have been able to solve it. I've also solved it by hand (it is just a linear first order ode) and got same solution. Maple can solve it without the IC. 

So the issue is in resolving constant of integration using IC is where the problem is.

May be someone could find why Maple can't solve for the constant of integration from the IC. Here is the solution without IC which Maple finds with no problem

ode:=diff(y(x),x)*sin(2*x) = 2*y(x)+2*cos(x); 
sol:=dsolve(ode);

Please Wait...