Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-15999

[Python] Turn deadlines off for the test using hypothesis

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 8.0.0
    • Python

    Description

      Turn deadlines off for test test_python_datetime_with_pytz_timezone in test_pandas-py that is using hypothesis and is failing in nightly builds:

      =================================== FAILURES ===================================
      _____ TestConvertDateTimeLikeTypes.test_python_datetime_with_pytz_timezone _____
      
      self = <pyarrow.tests.test_pandas.TestConvertDateTimeLikeTypes object at 0x7f504239d730>
      
          @h.given(st.none() | tzst.timezones())
      >   def test_python_datetime_with_pytz_timezone(self, tz):
      
      opt/conda/envs/arrow/lib/python3.8/site-packages/pyarrow/tests/test_pandas.py:1048: 
      _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
      
      self = <hypothesis.core.StateForActualGivenExecution object at 0x7f503f91c320>
      message = "Hypothesis test_python_datetime_with_pytz_timezone(self=<pyarrow.tests.test_pandas.TestConvertDateTimeLikeTypes at 0x...la' LMT-1 day, 19:36:00 STD>) produces unreliable results: Falsified on the first call but did not on a subsequent one"
      
          def __flaky(self, message):
              if len(self.falsifying_examples) <= 1:
      >           raise Flaky(message)
      E           hypothesis.errors.Flaky: Hypothesis test_python_datetime_with_pytz_timezone(self=<pyarrow.tests.test_pandas.TestConvertDateTimeLikeTypes at 0x7f504239d730>, tz=<DstTzInfo 'America/Anguilla' LMT-1 day, 19:36:00 STD>) produces unreliable results: Falsified on the first call but did not on a subsequent one
      
      opt/conda/envs/arrow/lib/python3.8/site-packages/hypothesis/core.py:886: Flaky
      ---------------------------------- Hypothesis ----------------------------------
      Falsifying example: test_python_datetime_with_pytz_timezone(
          tz=<DstTzInfo 'America/Anguilla' LMT-1 day, 19:36:00 STD>,
          self=<pyarrow.tests.test_pandas.TestConvertDateTimeLikeTypes at 0x7f504239d730>,
      )
      Unreliable test timings! On an initial run, this test took 559.16ms, which exceeded the deadline of 200.00ms, but on a subsequent run it took 1.93 ms, which did not. If you expect this sort of variability in your test timings, consider turning deadlines off for this test by setting deadline=None.
      

      Attachments

        Issue Links

          Activity

            People

              alenka Alenka Frim
              alenka Alenka Frim
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 50m
                  1h 50m