def get(self, profile_id=None):
    
    template_values = self.build_template_values()
    
    if profile_id and template_values[handlers.base.PROFILE_KEY] and int(profile_id) == template_values[handlers.base.PROFILE_KEY].key().id():
      template_values['viewed_profile'] = template_values[handlers.base.PROFILE_KEY]
    elif profile_id:
      template_values['viewed_profile'] = Profile.get_by_id(int(profile_id))
    elif template_values[handlers.base.PROFILE_KEY]:
      return self.redirect(self.uri_for("profile", profile_id=template_values[handlers.base.PROFILE_KEY].key().id()))
    else:
      return self.forbidden()
    
    favorites = Vote.all().filter("voter = ", template_values['viewed_profile']).filter("is_up = ", True).fetch(1)
    if favorites:
      template_values['recent_up_monster'] = favorites[0].monster
      
    created =   Monster.get_recent(1, creator=template_values['viewed_profile'], user=template_values[handlers.base.PROFILE_KEY])
    if created:
      template_values['recent_monster'] = created[0]
    template = configuration.site.jinja_environment.get_template('profile/view.html')
    return self.response.write(template.render(template_values))
Recalls state for items with slots
dataset/ETHPy150Open Sagelt/dungeon-world-codex/handlers/profile.py/ProfileHandler.get--crossover with--dataset/ETHPy150Open SmokinCaterpillar/pypet/pypet/slots.py/HasSlots.__setstate__