From ff6e964b7bc69f91cf57416dfc1c3c11788cb32d Mon Sep 17 00:00:00 2001 From: Tim van Katwijk Date: Fri, 6 Jan 2023 11:49:45 +0100 Subject: [PATCH] do not use deprecated package Signed-off-by: Tim van Katwijk --- .packit.yaml | 1 - dockerfile_parse/parser.py | 3 +-- tests/requirements.txt | 3 +-- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/.packit.yaml b/.packit.yaml index c92e02e..fc82613 100644 --- a/.packit.yaml +++ b/.packit.yaml @@ -21,4 +21,3 @@ jobs: srpm_build_deps: - python3-pip - python3-setuptools_scm - - Deprecated diff --git a/dockerfile_parse/parser.py b/dockerfile_parse/parser.py index c1a45e6..a427c0c 100644 --- a/dockerfile_parse/parser.py +++ b/dockerfile_parse/parser.py @@ -11,7 +11,6 @@ import logging import os import re -from deprecated import deprecated from contextlib import contextmanager from shlex import quote @@ -862,12 +861,12 @@ def context_structure(self): return instructions -@deprecated(reason="Use image_name_from instead.") def image_from(from_value): """ :param from_value: string like "image:tag" or "image:tag AS name" :return: tuple of the image and stage name, e.g. ("image:tag", None) """ + DeprecationWarning("Use image_name_from instead.") image, name = image_name_from(from_value) return str(image) if image else None, name diff --git a/tests/requirements.txt b/tests/requirements.txt index 7a64e9c..1f5b799 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,5 +1,4 @@ pytest>=4.1.0 pytest-cov pytest-html -flake8 -Deprecated \ No newline at end of file +flake8 \ No newline at end of file