Skip to content

Commit 31efffe

Browse files
author
KevinGG
committed
[BEAM-11045] Avoid broken deps
1. A new release: jupyter-client 6.1.13 breaks notebooks when getting messages. 2. This is caught by screen diff integration tests of interactive beam. 3. The issue is documented at jupyter/jupyter_client#637 ETA of the fix might be 6.2.x of jupyter-client. 4. Added a timeout=-1 to allow indefinite wait for execution of each notebook cell in integration tests. The default value was 1 second. Instead of timeout each cell, moved the timeout to each test using pytest mark.
1 parent 0805b9b commit 31efffe

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed

sdks/python/apache_beam/runners/interactive/testing/integration/notebook_executor.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,8 @@ def execute(self):
8282
for path in self._paths:
8383
with open(path, 'r') as nb_f:
8484
nb = nbformat.read(nb_f, as_version=4)
85-
ep = ExecutePreprocessor(allow_errors=True, kernel_name='test')
85+
ep = ExecutePreprocessor(
86+
timeout=-1, allow_errors=True, kernel_name='test')
8687
ep.preprocess(nb, {'metadata': {'path': os.path.dirname(path)}})
8788

8889
execution_id = obfuscate(path)

sdks/python/apache_beam/runners/interactive/testing/integration/tests/init_square_cube_test.py

+3
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,12 @@
2222

2323
import unittest
2424

25+
import pytest
26+
2527
from apache_beam.runners.interactive.testing.integration.screen_diff import BaseTestCase
2628

2729

30+
@pytest.mark.timeout(300)
2831
class InitSquareCubeTest(BaseTestCase):
2932
def __init__(self, *args, **kwargs):
3033
kwargs['golden_size'] = (1024, 10000)

sdks/python/setup.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,9 @@ def get_version():
206206
'facets-overview>=1.0.0,<2',
207207
'ipython>=5.8.0,<8',
208208
'ipykernel>=5.2.0,<6',
209-
'jupyter-client>=6.1.11,<7',
209+
# Skip version 6.1.13 due to
210+
# https://github.com/jupyter/jupyter_client/issues/637
211+
'jupyter-client>=6.1.11,<6.1.13',
210212
'timeloop>=1.0.2,<2',
211213
]
212214

0 commit comments

Comments
 (0)