<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_etag(self, overwrite=False, weak=False):
 """Add an etag for the current response if there is none yet."""

        if overwrite or "etag" not in self.headers:
            self.set_etag(generate_etag(self.get_data()), weak)