Not counting gliders, helicopters, gyro-copters, powered parachute, balloons, blimps, or whatever...and assuming proper check-out, etc...
And, all pilots must conform to the limitations of their certificate and the aircraft they are flying...
Any pilot must have an FAA medical or Basic Med to solo or act as PIC in an aircraft other than LSA. A student can solo, but not act as PIC.
A Sport Pilot can never solo or act as PIC in an aircraft other than LSA.
Any pilot can solo or act as PIC in an LSA with a driver's license, FAA medical, or Basic Med. A student can solo, but not act as PIC.
Any pilot operating an LSA without an FAA medical or Basic Med must comply with Sport Pilot privileges and limitations.
The question at hand is when and if a student pilot flying an LSA needs an FAA medical or Basic Med.
The answer is never if he is seeking a Sport Pilot certificate in an LSA.
So, if he is seeking a Private certificate in an LSA, when does he need an FAA medical?
The answer is before his instructor recommends him for a flight test and before he takes a flight test.
So, the only remaining question is how long before?
This is where we disagree and will always disagree.
Commercial Pilot Airplane Single & Multiengine Land; Instrument Airplane; Sport Endorsement Airplane Single Engine Sea; Flight Instructor Airplane Single And Multiengine; Ground Instructor Advanced Instrument