Skip to content

Commit

Permalink
Also xfail zlib errors when downloading newsgroups data (#3393)
Browse files Browse the repository at this point in the history
Download errors can manifest as zlib.error as well as IOException it turns out (just saw this in CI)

Authors:
  - John Zedlewski (@JohnZed)

Approvers:
  - Dante Gama Dessavre (@dantegd)
  - Micka (@lowener)

URL: #3393
  • Loading branch information
JohnZed authored Jan 22, 2021
1 parent e8d1610 commit 29f7d08
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions python/cuml/test/conftest.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (c) 2018-2020, NVIDIA CORPORATION.
# Copyright (c) 2018-2021, NVIDIA CORPORATION.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -18,6 +18,7 @@
import pytest
from sklearn.datasets import fetch_20newsgroups
from sklearn.feature_extraction.text import CountVectorizer
import zlib


def pytest_configure(config):
Expand All @@ -30,7 +31,7 @@ def nlp_20news():
twenty_train = fetch_20newsgroups(subset='train',
shuffle=True,
random_state=42)
except IOError:
except (IOError, zlib.error):
pytest.xfail(reason="Error fetching 20 newsgroup dataset")

count_vect = CountVectorizer()
Expand Down

0 comments on commit 29f7d08

Please sign in to comment.