1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/aa1eee2bd24a/ Changeset: aa1eee2bd24a User: martenson Date: 2014-03-21 00:26:45 Summary: libraries - removal of id-encoding related bug in API commited in f7ebd14c2f9b260cdb6627e4abfd5c03f14c4900 and identified by jmchilton in https://bitbucket.org/galaxy/galaxy-central/commits/f7ebd14c2f9b260cdb6627e4... Affected #: 2 files diff -r 29a9d6d904f3506f141253e2b1e97cf1aa55a081 -r aa1eee2bd24a4ba449449f16659701eb7481f301 lib/galaxy/model/__init__.py --- a/lib/galaxy/model/__init__.py +++ b/lib/galaxy/model/__init__.py @@ -2078,8 +2078,8 @@ # This needs to be a list return [ ld for ld in self.datasets if ld.library_dataset_dataset_association and not ld.library_dataset_dataset_association.dataset.deleted ] - def to_dict( self, view='collection' ): - rval = super( LibraryFolder, self ).to_dict( view=view ) + def to_dict( self, view='collection', value_mapper=None ): + rval = super( LibraryFolder, self ).to_dict( view=view, value_mapper=value_mapper ) info_association, inherited = self.get_info_association() if info_association: if inherited: diff -r 29a9d6d904f3506f141253e2b1e97cf1aa55a081 -r aa1eee2bd24a4ba449449f16659701eb7481f301 lib/galaxy/webapps/galaxy/api/library_contents.py --- a/lib/galaxy/webapps/galaxy/api/library_contents.py +++ b/lib/galaxy/webapps/galaxy/api/library_contents.py @@ -123,11 +123,18 @@ class_name, content_id = self.__decode_library_content_id( trans, id ) if class_name == 'LibraryFolder': content = self.get_library_folder( trans, content_id, check_ownership=False, check_accessible=True ) + rval = content.to_dict( view='element', value_mapper={ 'id' : trans.security.encode_id } ) + rval[ 'id' ] = 'F' + str( rval[ 'id' ] ) + rval[ 'parent_id' ] = 'F' + str( trans.security.encode_id( rval[ 'parent_id' ] ) ) + rval[ 'parent_library_id' ] = trans.security.encode_id( rval[ 'parent_library_id' ] ) else: content = self.get_library_dataset( trans, content_id, check_ownership=False, check_accessible=True ) - - return content.to_dict( view='element', value_mapper={ 'id' : trans.security.encode_id } ) - # return self.encode_all_ids( trans, content.to_dict( view='element' ) ) + rval = content.to_dict( view='element') + rval[ 'id' ] = trans.security.encode_id( rval[ 'id' ] ) + rval[ 'ldda_id' ] = trans.security.encode_id( rval[ 'ldda_id' ] ) + rval[ 'folder_id' ] = 'F' + str( trans.security.encode_id( rval[ 'folder_id' ] ) ) + rval[ 'parent_library_id' ] = trans.security.encode_id( rval[ 'parent_library_id' ] ) + return rval @web.expose_api def create( self, trans, library_id, payload, **kwd ): Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.