comparison create_or_update_organism.py @ 3:bf2f5f6e11a9 draft

planemo upload for repository https://github.com/galaxy-genome-annotation/galaxy-tools/tree/master/tools/apollo commit 079b759c21c00200544a6d8d5521617dce8ca70d
author gga
date Wed, 20 Sep 2017 09:43:23 -0400
parents dc738069b5ac
children 0af4179e6758
comparison
equal deleted inserted replaced
2:720f372226eb 3:bf2f5f6e11a9
42 except Exception: 42 except Exception:
43 org = None 43 org = None
44 44
45 if org: 45 if org:
46 has_perms = False 46 has_perms = False
47 old_directory = org.directory 47 old_directory = org['directory']
48 for user_owned_organism in gx_user.organismPermissions: 48 for user_owned_organism in gx_user.organismPermissions:
49 if 'WRITE' in user_owned_organism['permissions']: 49 if 'WRITE' in user_owned_organism['permissions']:
50 has_perms = True 50 has_perms = True
51 break 51 break
52 52
63 genus=args.genus, 63 genus=args.genus,
64 species=args.species, 64 species=args.species,
65 public=args.public 65 public=args.public
66 ) 66 )
67 time.sleep(2) 67 time.sleep(2)
68 if(args.remove_old_directory): 68 if args.remove_old_directory and args.jbrowse != old_directory:
69 shutil.rmtree(old_directory) 69 shutil.rmtree(old_directory)
70 70
71 data = [wa.organisms.findOrganismById(org['id'])] 71 data = [wa.organisms.findOrganismById(org['id'])]
72 72
73 else: 73 else: