code: def active_db():
      
      global dbs
      # The task database is encapsulated in a class for easier serialization to
      # JSON. Get the DB for the (project, task) combination.
      dbkey = (project, task)
      if dbkey in dbs:
          taskdb = dbs[dbkey]
      else:
          taskdb = TaskDB()
          dbs[dbkey] = taskdb
          msg.okay("Initialized JSON database for {}.{}".format(*dbkey), 2)
  
      return taskdb
docs: Returns the active :class:`TaskDB` for the current project and task.