Skip to content

Commit e7342e3

Browse files
committed
fix: add ignore filter in pyproject.toml
1 parent a966c0b commit e7342e3

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ markers = [
180180
]
181181
filterwarnings = [
182182
"error::FutureWarning",
183+
"ignore::FutureWarning:onnxscript", # Temporary ignore until onnxscript is updated
183184
]
184185
xfail_strict = true
185186
junit_duration_report = "call"

tests/tests_pytorch/models/test_onnx.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
# limitations under the License.
1414
import operator
1515
import os
16-
import warnings
1716
from io import BytesIO
1817
from pathlib import Path
1918
from unittest.mock import patch
@@ -176,8 +175,5 @@ def test_model_return_type():
176175
model.example_input_array = torch.randn((1, 32))
177176
model.eval()
178177

179-
# Temporarily suppress FutureWarning from onnxscript internal function.
180-
with warnings.catch_warnings():
181-
warnings.simplefilter("ignore", FutureWarning)
182-
ret = model.to_onnx(dynamo=True)
178+
ret = model.to_onnx(dynamo=True)
183179
assert isinstance(ret, torch.onnx.ONNXProgram)

0 commit comments

Comments
 (0)