title: Tornado PeriodicCallback will create a new context
body: <p>I encounter some strange behavior of <a href="http://www.tornadoweb.org/en/stable/ioloop.html" rel="nofollow noreferrer">PeriodicCallback in Python Tornado</a>. </p>
  
  <pre><code>from tornado.ioloop import PeriodicCallback
  class MyClass(object):
      def __init__(self):
          self.dict = {}
          PeriodicCallback(self._check_status, 3000).start()
      ...
      def foo(self):
          self.dict["efg"] = 20 
          print (id(self.dict)) # 1st print
  
      def _check_status(self):
          self.dict["abc"] = 10
          print ( id(self.dict)) # 2nd print
  </code></pre>
  
  <p>The 1st and 2nd print value is different, meaning self.dict are different object, which causes serious problem. This is unexpected behavior. What is wrong? </p>
  
  <p>I want self.dict referring to the same object in foo and in _check_status. What should I do? </p>