Skip to content

Commit bca275f

Browse files
committed
make all_patches a set, use FrozenDicts for the patch_info dict
1 parent cc4eb8a commit bca275f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

easybuild/framework/easyblock.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@
6767
import easybuild.tools.environment as env
6868
import easybuild.tools.toolchain as toolchain
6969
from easybuild.base import fancylogger
70+
from easybuild.base.frozendict import FrozenDict
7071
from easybuild.framework.easyconfig import EASYCONFIGS_PKG_SUBDIR
7172
from easybuild.framework.easyconfig.easyconfig import ITERATE_OPTIONS, EasyConfig, ActiveMNS, get_easyblock_class
7273
from easybuild.framework.easyconfig.easyconfig import get_module_path, letter_dir_for, resolve_template
@@ -188,7 +189,7 @@ def __init__(self, ec, logfile=None):
188189

189190
# list of patch/source files, along with checksums
190191
self.patches = []
191-
self.all_patches = [] # also includes patches of extensions
192+
self.all_patches = set() # set of all patches (including patches of extensions)
192193
self.src = []
193194
self.data_src = []
194195
self.checksums = []
@@ -602,7 +603,7 @@ def fetch_patches(self, patch_specs=None, extension=False, checksums=None):
602603
patch_info['path'] = path
603604
patch_info['checksum'] = self.get_checksum_for(checksums, filename=patch_info['name'], index=index)
604605

605-
self.all_patches.append(patch_info)
606+
self.all_patches.add(FrozenDict(patch_info))
606607
if extension:
607608
patches.append(patch_info)
608609
else:

0 commit comments

Comments
 (0)