catalyst-cooperative / ferc-xbrl-extractor

A tool for converting FERC filings published in XBRL into SQLite databases
MIT License
11 stars 0 forks source link

Suppress warnings with 'ignore' not 'once' becuase 'once' doesn't work. #170

Closed zaneselvans closed 7 months ago

zaneselvans commented 7 months ago

After much experimentation, it sure seems like

warnings.filterwarnings(action="once")

just doesn't filter the warnings at all. I tried doing it at the module level, and with a context manager, with the modules specified or not. I tried using action="module" and that also had no effect. Only action="ignore" seems to make the tens of thousands of warnings go away, so I did it with as narrow a scope as possible.

codecov[bot] commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (7fc8580) 93.41% compared to head (d33b8af) 93.43%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #170 +/- ## ========================================== + Coverage 93.41% 93.43% +0.02% ========================================== Files 8 8 Lines 607 609 +2 ========================================== + Hits 567 569 +2 Misses 40 40 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.