Make the flaky list a little more general (#36704)
* Make the flaky list a little more general * Trigger tests * Make the flaky list a little more general
This commit is contained in:
@@ -41,8 +41,7 @@ FLAKY_TEST_FAILURE_PATTERNS = [
|
|||||||
"ConnectionError", # Connection transient error
|
"ConnectionError", # Connection transient error
|
||||||
"FileNotFoundError", # Raised by `datasets` on Hub failures
|
"FileNotFoundError", # Raised by `datasets` on Hub failures
|
||||||
"PIL.UnidentifiedImageError", # Raised by `PIL.Image.open` on connection issues
|
"PIL.UnidentifiedImageError", # Raised by `PIL.Image.open` on connection issues
|
||||||
"HTTPError.*502", # Hub-related
|
"HTTPError", # Also catches HfHubHTTPError
|
||||||
"HTTPError.*504", # Hub-related
|
|
||||||
"AssertionError: Tensor-likes are not close!", # `torch.testing.assert_close`, we might have unlucky random values
|
"AssertionError: Tensor-likes are not close!", # `torch.testing.assert_close`, we might have unlucky random values
|
||||||
# TODO: error downloading tokenizer's `merged.txt` from hub can cause all the exceptions below. Throw and handle
|
# TODO: error downloading tokenizer's `merged.txt` from hub can cause all the exceptions below. Throw and handle
|
||||||
# them under a single message.
|
# them under a single message.
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ from transformers import AutoImageProcessor, BatchFeature
|
|||||||
from transformers.image_utils import AnnotationFormat, AnnotionFormat
|
from transformers.image_utils import AnnotationFormat, AnnotionFormat
|
||||||
from transformers.testing_utils import (
|
from transformers.testing_utils import (
|
||||||
check_json_file_has_correct_format,
|
check_json_file_has_correct_format,
|
||||||
|
is_flaky,
|
||||||
require_torch,
|
require_torch,
|
||||||
require_torch_gpu,
|
require_torch_gpu,
|
||||||
require_vision,
|
require_vision,
|
||||||
@@ -212,6 +213,7 @@ class ImageProcessingTestMixin:
|
|||||||
|
|
||||||
@require_vision
|
@require_vision
|
||||||
@require_torch
|
@require_torch
|
||||||
|
@is_flaky()
|
||||||
def test_fast_is_faster_than_slow(self):
|
def test_fast_is_faster_than_slow(self):
|
||||||
if not self.test_slow_image_processor or not self.test_fast_image_processor:
|
if not self.test_slow_image_processor or not self.test_fast_image_processor:
|
||||||
self.skipTest(reason="Skipping speed test")
|
self.skipTest(reason="Skipping speed test")
|
||||||
|
|||||||
Reference in New Issue
Block a user