ResourceWarning: unclosed file

This repository was archived by the owner on Nov 6, 2023. It is now read-only.

This repository was archived by the owner on Nov 6, 2023. It is now read-only.

@jayvdb

Description

Type: code issue

test/rules/src/https_everywhere_checker/check_rules.py:269: ResourceWarning: unclosed file <_io.BufferedReader name='rules/Whisper-Gifts.xml'>
  hasher.update(open(filename, 'rb').read())
ResourceWarning: Enable tracemalloc to get the object allocation traceback
test/rules/src/https_everywhere_checker/check_rules.py:391: ResourceWarning: unclosed file <_io.BufferedReader name='rules/Whisper-Gifts.xml'>
  ruleset = Ruleset(etree.parse(open(xmlFname, "rb")).getroot(), xmlFname)
ResourceWarning: Enable tracemalloc to get the object allocation traceback