diff options
| author | AlexSm <[email protected]> | 2024-03-13 16:36:01 +0100 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-03-13 16:36:01 +0100 |
| commit | 6cb1176da7acfe6571977f06e7d9dc4365cb330b (patch) | |
| tree | c15fcf49a68ba829dc39eef237f94f41d0b55ee6 /contrib/python/ipython/py3/IPython/utils/path.py | |
| parent | 67ba58b766f6ca63d5471aa18728e69d03ffe1ca (diff) | |
| parent | 18c62b66fdaa3ae6c066f720f82b88b28cc3dc91 (diff) | |
Merge pull request #2697 from ydb-platform/mergelibs-240313-1032
Library import 240313-1032
Diffstat (limited to 'contrib/python/ipython/py3/IPython/utils/path.py')
| -rw-r--r-- | contrib/python/ipython/py3/IPython/utils/path.py | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/contrib/python/ipython/py3/IPython/utils/path.py b/contrib/python/ipython/py3/IPython/utils/path.py index ccb70dccd43..cb5be041957 100644 --- a/contrib/python/ipython/py3/IPython/utils/path.py +++ b/contrib/python/ipython/py3/IPython/utils/path.py @@ -12,6 +12,7 @@ import errno import shutil import random import glob +import warnings from IPython.utils.process import system @@ -292,7 +293,14 @@ def target_outdated(target,deps): If target doesn't exist or is older than any file listed in deps, return true, otherwise return false. + + .. deprecated:: 8.22 """ + warnings.warn( + "`target_outdated` is deprecated since IPython 8.22 and will be removed in future versions", + DeprecationWarning, + stacklevel=2, + ) try: target_time = os.path.getmtime(target) except os.error: @@ -312,9 +320,17 @@ def target_update(target,deps,cmd): target_update(target,deps,cmd) -> runs cmd if target is outdated. This is just a wrapper around target_outdated() which calls the given - command if target is outdated.""" + command if target is outdated. + + .. deprecated:: 8.22 + """ - if target_outdated(target,deps): + warnings.warn( + "`target_update` is deprecated since IPython 8.22 and will be removed in future versions", + DeprecationWarning, + stacklevel=2, + ) + if target_outdated(target, deps): system(cmd) |
