I used to work in the Financial Aid office at my school. Many of the graduate students had filed Bankruptcy before, so I can answer this question. You can get a federal stafford loan no matter how bad your credit is. You can have bankruptcy, forclosures, etc. The federal student loans programs don't care about credit rating. The purpose of federal student loans is to make education accessible.
The ONLY exception to this is if you have defaulted on prior student loans, then you cannot get anymore federal stafford loans. All those grad students who had filed Bankruptcy had not defaulted on their student loans. So, those were excluded from the Bankruptcy and hence, they can get federal stafford loans (sub and unsubsidized)
So, you can have a really bad credits history and get $38,500 per year in Sub + Unsub federal stafford loans as a med student.
However, if your cost of attendance is more than $38,500, then you will have a more difficult time getting a private loan to make up the difference if your credit is bad. Most private medical school have a Cost of attendance over $50,000 per year so lots of med students need to take out a private loan. Therefore, be careful with your credit as you may only be accepted to a private school and need to extra funds to cover your education costs. Good credit is indeed important.