sqlite.py 文件源码

python
阅读 27 收藏 0 点赞 0 评论 0

项目:chocolate 作者: AIworx-Labs 项目源码 文件源码
def insert_space(self, space):
        """Insert a space in the database.

        Raises:
            AssertionError: If a space is already present in the database.
        """
        gc.collect()
        db = dataset.connect(self.url)
        assert db[self.space_table_name].count() == 0, ("Space table cannot contain more than one space, "
                                                        "clear table first.")
        return db[self.space_table_name].insert({"space": pickle.dumps(space)})
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号