State:Closed|icon_bug|database:public|icon_mari|Resolution:Fixed|TargetRelease:3.4v1|BugID:337468|
Problem summary
When importing the attached session script, an exception is thrown due to channel.resize being called without using the correct mari.ImageSet type
Customer reported version
3.3v1
Customer reported platform
centos7
Steps to reproduce
1) Launch Mari
2) Download the attached archive and session
3) Open the archive
4) Import the attached .msf using the below script:
uvIndex = 210
dstUvIndex = 192
msfPath = '/path/to/sessionscript.msf'
mariDstGeo = mari.geo.find('dva_eyes')
uvIndexMap = {uvIndex : [dstUvIndex]} # in 3.1 keys must be strings
dstGeo = mari.session.types.GeoEntity.fromMariObject(mariDstGeo, None)
srcProj = mari.session.types.Project.fromMSF(msfPath)
srcGeo = srcProj.geoEntities[0]
copiedChannels = dstGeo.copyChannels(srcGeo.channels, uvIndexMap)
dstGeo.make()
Traceback (most recent call last):
File "<string>", line 10, in <module>
File "C:/Program Files/Mari4.0v2/Bundle/Media/Scripts\Mari\session\types\geo_entity.py", line 326, in copyChannels
channel.remapPatchUvIndexes(uvIndexesMap)
File "C:/Program Files/Mari4.0v2/Bundle/Media/Scripts\Mari\session\types\channel.py", line 394, in remapPatchUvIndexes
mappedPatches[targetIndex] = self.patches[key]
KeyError: 210
exceptions.TypeError, 'mari.Channel.resize' called with wrong argument types:
mari.Channel.resize(int, list)
Supported signatures:
mari.Channel.resize(mari.Mari::ImageSet.Size, list = QList< int >())
We're sorry to hear that
Please tell us why