Show More
@@ -1135,7 +1135,7 getbundle2partsorder = [] | |||||
1135 | # This exists to help extensions wrap steps if necessary |
|
1135 | # This exists to help extensions wrap steps if necessary | |
1136 | getbundle2partsmapping = {} |
|
1136 | getbundle2partsmapping = {} | |
1137 |
|
1137 | |||
1138 | def getbundle2partsgenerator(stepname): |
|
1138 | def getbundle2partsgenerator(stepname, idx=None): | |
1139 | """decorator for function generating bundle2 part for getbundle |
|
1139 | """decorator for function generating bundle2 part for getbundle | |
1140 |
|
1140 | |||
1141 | The function is added to the step -> function mapping and appended to the |
|
1141 | The function is added to the step -> function mapping and appended to the | |
@@ -1147,7 +1147,10 def getbundle2partsgenerator(stepname): | |||||
1147 | def dec(func): |
|
1147 | def dec(func): | |
1148 | assert stepname not in getbundle2partsmapping |
|
1148 | assert stepname not in getbundle2partsmapping | |
1149 | getbundle2partsmapping[stepname] = func |
|
1149 | getbundle2partsmapping[stepname] = func | |
|
1150 | if idx is None: | |||
1150 | getbundle2partsorder.append(stepname) |
|
1151 | getbundle2partsorder.append(stepname) | |
|
1152 | else: | |||
|
1153 | getbundle2partsorder.insert(idx, stepname) | |||
1151 | return func |
|
1154 | return func | |
1152 | return dec |
|
1155 | return dec | |
1153 |
|
1156 |
General Comments 0
You need to be logged in to leave comments.
Login now