File: mips_ignore_nonwarning.patch

package info (click to toggle)
statsmodels 0.14.5%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 49,940 kB
  • sloc: python: 253,284; f90: 612; sh: 560; javascript: 337; asm: 156; makefile: 145; ansic: 16; xml: 9
file content (25 lines) | stat: -rw-r--r-- 1,103 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Description: Ignore missing HessianInversionWarning on some mips*

Author: Rebecca N. Palmer <rebecca_palmer@zoho.com>
Forwarded: no

--- a/statsmodels/base/tests/test_generic_methods.py
+++ b/statsmodels/base/tests/test_generic_methods.py
@@ -9,6 +9,8 @@ Created on Wed Oct 30 14:01:27 2013
 
 Author: Josef Perktold
 """
+import platform
+import contextlib
 from statsmodels.compat.pytest import pytest_warns
 from statsmodels.compat.pandas import assert_index_equal, assert_series_equal
 from statsmodels.compat.platform import (
@@ -232,7 +234,7 @@ class CheckGenericMixin:
                                                       start_params=sp,
                                                       method=method, disp=0)
             else:
-                with pytest_warns(warn_cls):
+                with (contextlib.nullcontext() if ((warn_cls is not None) and ('mips' in platform.uname()[4])) else pytest_warns(warn_cls)):
                     # more special casing RLM
                     if (isinstance(self.results.model, (sm.RLM))):
                         res1 = mod._fit_collinear()