Skip to content

Commit

Permalink
[DOP-13337] Use typing_extensions.deprecated on legacy FileFilter and…
Browse files Browse the repository at this point in the history
… FileLimit
  • Loading branch information
dolfinus committed Mar 5, 2024
1 parent 66057e0 commit a994486
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions onetl/core/file_filter/file_filter.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@
from typing import List, Optional, Union

from pydantic import Field, root_validator, validator
from typing_extensions import deprecated

from onetl.base import BaseFileFilter, PathProtocol
from onetl.impl import FrozenModel, RemotePath


@deprecated("Deprecated in 0.8.0 and will be removed in 1.0.0. Use Glob, Regexp or ExcludeDir instead", category=None)
class FileFilter(BaseFileFilter, FrozenModel):
r"""Filter files or directories by their path.
Expand Down
2 changes: 2 additions & 0 deletions onetl/core/file_limit/file_limit.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@
import warnings

from pydantic import validator
from typing_extensions import deprecated

from onetl.base import BaseFileLimit, PathProtocol
from onetl.impl import FrozenModel


@deprecated("Deprecated in 0.8.0 and will be removed in 1.0.0. Use MaxFilesCount instead", category=None)
class FileLimit(BaseFileLimit, FrozenModel):
"""Limits the number of downloaded files.
Expand Down

0 comments on commit a994486

Please sign in to comment.