feat(sdk)!: Deprecate V2 compatible mode in v1 compiler (#6958)
* Deprecate V2 compatible mode in v1 compiler * release note * fix tests
This commit is contained in:
parent
59dfffebea
commit
8aee62142a
|
|
@ -13,6 +13,7 @@
|
|||
|
||||
* Remove sdk/python/kfp/v2/google directory for v2, including google client and custom job [\#6886](https://github.com/kubeflow/pipelines/pull/6886)
|
||||
* APIs imported from the v1 namespace are no longer supported by the v2 compiler. [\#6890](https://github.com/kubeflow/pipelines/pull/6890)
|
||||
* Deprecate v2 compatible mode in v1 compiler. [\#6958](https://github.com/kubeflow/pipelines/pull/6958)
|
||||
|
||||
### For Pipeline Authors
|
||||
|
||||
|
|
|
|||
|
|
@ -76,8 +76,10 @@ class Compiler(object):
|
|||
raise ValueError('V2_ENGINE execution mode is not supported yet.')
|
||||
|
||||
if mode == dsl.PipelineExecutionMode.V2_COMPATIBLE:
|
||||
warnings.warn('V2_COMPATIBLE execution mode is at Beta quality.'
|
||||
' Some pipeline features may not work as expected.')
|
||||
raise ValueError('V2_COMPATIBLE mode has been deprecated in KFP SDK'
|
||||
' 2.0. To use V2_COMPATIBLE mode, install KFP SDK'
|
||||
' 1.8.*.')
|
||||
|
||||
self._mode = mode
|
||||
self._launcher_image = launcher_image
|
||||
self._pipeline_name_param: Optional[dsl.PipelineParam] = None
|
||||
|
|
@ -744,8 +746,7 @@ class Compiler(object):
|
|||
for op in pipeline.ops.values():
|
||||
if hasattr(op, 'importer_spec'):
|
||||
raise ValueError(
|
||||
'dsl.importer is not supported with v1 compiler.'
|
||||
)
|
||||
'dsl.importer is not supported with v1 compiler.')
|
||||
|
||||
if self._mode == dsl.PipelineExecutionMode.V2_COMPATIBLE:
|
||||
v2_compat.update_op(
|
||||
|
|
|
|||
|
|
@ -434,7 +434,7 @@ class TestCompiler(parameterized.TestCase):
|
|||
@parameterized.parameters(
|
||||
{
|
||||
'mode': 'V2_COMPATIBLE',
|
||||
'is_v2': True
|
||||
'error': True
|
||||
},
|
||||
{
|
||||
'mode': 'V1',
|
||||
|
|
@ -451,7 +451,7 @@ class TestCompiler(parameterized.TestCase):
|
|||
{
|
||||
'mode': 'V2_COMPATIBLE',
|
||||
'env': 'V1',
|
||||
'is_v2': True
|
||||
'error': True
|
||||
},
|
||||
{
|
||||
'mode': None,
|
||||
|
|
@ -461,7 +461,7 @@ class TestCompiler(parameterized.TestCase):
|
|||
{
|
||||
'mode': None,
|
||||
'env': 'V2_COMPATIBLE',
|
||||
'is_v2': True
|
||||
'error': True
|
||||
},
|
||||
{
|
||||
'mode': None,
|
||||
|
|
@ -1466,6 +1466,7 @@ implementation:
|
|||
p, group_type="subgraph")
|
||||
self.assertEqual(resolved, "{{inputs.parameters.op1-param1}}")
|
||||
|
||||
@unittest.skip('v2 compatible mode is being deprecated in SDK v2.0')
|
||||
def test_uri_artifact_passing(self):
|
||||
self._test_py_compile_yaml('uri_artifacts', mode='V2_COMPATIBLE')
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue