<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_email_body(self, sample):
 """Returns the email body text """

        retest = sample.getRetest()
        lab_address = api.get_bika_setup().laboratory.getPrintAddress()
        setup = api.get_setup()
        body = Template(setup.getEmailBodySampleInvalidation())\
            .safe_substitute(
            dict(sample_link=self.get_html_link(sample),
                 retest_link=self.get_html_link(retest),
                 sample_id=api.get_id(sample),
                 retest_id=api.get_id(retest),
                 lab_address="<br/>".join(lab_address)))
        return body