mirror of
https://github.com/clearml/clearml-agent
synced 2025-06-26 18:16:15 +00:00
Add Requirement.clone()
This commit is contained in:
parent
15f4aa613e
commit
6f078afafd
@ -4,7 +4,7 @@ import operator
|
|||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
from abc import ABCMeta, abstractmethod
|
from abc import ABCMeta, abstractmethod
|
||||||
from copy import deepcopy
|
from copy import deepcopy, copy
|
||||||
from itertools import chain, starmap
|
from itertools import chain, starmap
|
||||||
from operator import itemgetter
|
from operator import itemgetter
|
||||||
from os import path
|
from os import path
|
||||||
@ -81,6 +81,9 @@ class MarkerRequirement(object):
|
|||||||
|
|
||||||
return ''.join(parts)
|
return ''.join(parts)
|
||||||
|
|
||||||
|
def clone(self):
|
||||||
|
return MarkerRequirement(copy(self.req))
|
||||||
|
|
||||||
__str__ = tostr
|
__str__ = tostr
|
||||||
|
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user