When you say 'not credited' do you mean the leg was shown on your status but with 0 miles and 0 sector?
I remember AM will still show the flight that’s not eligible for mile accrual on your activity list. If that's the case, most likely you were on a deep discounted booking class that AM will not credit you with anything.
However, if you did not give your AM number before taking the flight and try to credit the non eligible class after then AM will simply just reject it.