Not enough info to make a determination. You'd have to tell us the purpose of the chest surgery, the outcome, and any other related conditions. Chest surgery, in and of itself, is not a contraindication to diving...but there are many conditions requiring chest surgery that would make diving far too risky.
Even if you were to give a medical professional all of that info over the Internet, you'd still have to see a physician in person (for history-taking, physical exam, and review of the medical record) in order for him/her to grant clearance. I recommend that you do this well before you sign up for any scuba classes.