File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -272,7 +272,11 @@ def __len__(self):
272272
273273 def get_id (self ):
274274 """return the id to use by pytest"""
275- return self .value .get_id ()
275+ if self .retrieved :
276+ raise ValueError ("id is lost once the tuple has been retrieved, this is ok since at this stage it should "
277+ "not be needed anymore..." )
278+ else :
279+ return self .value .get_id ()
276280
277281 def get (self ):
278282 """ Call the underlying value getter, then return the tuple (not self) """
@@ -354,7 +358,7 @@ def clone(self, remove_int_base=False):
354358 # return a type(self) (LazyValue or subclass)
355359 return _LazyValue .clone (self )
356360 else :
357- # return a _LazyValue
361+ # return a _LazyValue without the int base from _LazyValueBase
358362 return _LazyValue .copy_from (self )
359363
360364 class LazyTupleItem (_LazyTupleItem , _LazyValueBase ):
@@ -365,7 +369,7 @@ def clone(self, remove_int_base=False):
365369 # return a type(self) (LazyTupleItem or subclass)
366370 return _LazyTupleItem .clone (self )
367371 else :
368- # return a _LazyTupleItem
372+ # return a _LazyTupleItem without the int base from _LazyValueBase
369373 return _LazyTupleItem .copy_from (self )
370374
371375
You can’t perform that action at this time.
0 commit comments