<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def assert_200(response, max_len=500):
 """ Check that a HTTP response returned 200. """

  if response.status_code == 200:
    return

  raise ValueError(
      "Response was {}, not 200:\n{}\n{}".format(
          response.status_code,
          json.dumps(dict(response.headers), indent=2),
          response.content[:max_len]))