regression.py 文件源码

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

项目:zanph 作者: zanph 项目源码 文件源码
def __enter__(self):
        gc.disable()
        _gc_lock.acquire()
        loc = flask._request_ctx_stack._local

        # Force Python to track this dictionary at all times.
        # This is necessary since Python only starts tracking
        # dicts if they contain mutable objects.  It's a horrible,
        # horrible hack but makes this kinda testable.
        loc.__storage__['FOOO'] = [1, 2, 3]

        gc.collect()
        self.old_objects = len(gc.get_objects())
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号