def insert(self):
        assert not self.exists, "Cannot insert existing version"
        self.name = simplify_whitespace(self.name)
        if not self.name:
            raise TracError(_("Invalid version name."))

        with self.env.db_transaction as db:
            self.env.log.debug("Creating new version '%s'", self.name)
            db("INSERT INTO version (name,time,description) VALUES (%s,%s,%s)",
                (self.name, to_utimestamp(self.time), self.description))
            self._old_name = self.name
            TicketSystem(self.env).reset_ticket_fields()
We need to override the default behavior slightly here,
dataset/ETHPy150Open edgewall/trac/trac/ticket/model.py/Version.insert--crossover with--dataset/ETHPy150Open tomchristie/flask-api/flask_api/app.py/FlaskAPI.create_url_adapter