First of all, you’re listening to all the wrong people! Looking backward, the ONLY reason a property doesn’t sell is that you priced it too high — or didn’t market it well. And that means you’re planning with an important asset as an amateur.
First, get a qualified real estate agent. Show him or her the rental contract you signed. A LOT depends on the wording of that contract. Did you have a real estate attorney draw up the contract? If it specifies, in writing, that if the apartment is sold the tenant has 30 days, or some other period, to get out then you are in luck. If not, you may have to market the townhouse with a closing date set in August of this year.
Stop fooling around and get professional help. You need a realtor/broker and an attorney who specializes in real estate law. Start with the broker who can read the contract and recommend an attorney.