sources: transform() is only used in the curl sources, remove from ABC
This commit is contained in:
parent
7431653882
commit
1fc7ead2f4
6 changed files with 7 additions and 20 deletions
|
|
@ -4,7 +4,7 @@ import hashlib
|
|||
import json
|
||||
import os
|
||||
import tempfile
|
||||
from typing import ClassVar, Dict, Tuple
|
||||
from typing import ClassVar, Dict
|
||||
|
||||
from . import host
|
||||
from .objectstore import ObjectStore
|
||||
|
|
@ -105,11 +105,6 @@ class SourceService(host.Service):
|
|||
"""Returns True if the item to download is in cache. """
|
||||
return os.path.isfile(f"{self.cache}/{checksum}")
|
||||
|
||||
# pylint: disable=[no-self-use]
|
||||
def transform(self, checksum, desc) -> Tuple:
|
||||
"""Modify the input data before downloading. By default only transforms an item object to a Tupple."""
|
||||
return checksum, desc
|
||||
|
||||
@staticmethod
|
||||
def load_items(fds):
|
||||
with os.fdopen(fds.steal(0)) as f:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue