def primer_library():
form = FORM('primary library',INPUT (_type = 'submit') )
query_forward_match = []
hits_forward_match = []
query_backward_match = []
hits_backward_match = []
query_loc_forward = []
hits_loc_forward = []
query_loc_backward = []
hits_loc_backward = []
match_annealing_temp = []
primer_annealing_temp = []
if form.accepts(request.vars):
for record in db(db.plugin_seq.id > 0).select():
for primer_record in db(db.primer_seq_files.id>0).select():
#print 'query: ',primer_record.primer_filename, ' ',
record.filename
#print 'query: ',primer_record.primer_filename, ' ',
record.filename
if primer_record.primer_processed_seq in
record.processed_seq or primer_record.primer_processed_seq in
record.reverse_seq:
print 'query: ', record.filename
query_forward_match =
aling_function(primer_record.primer_processed_seq,record.processed_seq)
query_backward_match =
aling_function(primer_record.primer_processed_seq,record.reverse_seq)
hits_forward_match.append(LI('%s\n'
%record.filename,'%s\n'
%query_forward_match,'%s\n'%record.processed_seq,'%s\n'%record.reverse_seq,'%s\n'%query_backward_match))
query_loc_forward = [(m.start(),m.end(),m.group(0))for
m in re.finditer(primer_record.primer_processed_seq,record.processed_seq)]
hits_loc_forward.append(LI('%s\t' % record.filename
,'%s' %query_loc_forward))
query_loc_backward = [(m.start(),m.end(),m.group(0))for
m in re.finditer(primer_record.primer_processed_seq,record.reverse_seq)]
hits_loc_backward.append(LI('%s\t' % record.filename
,'%s' %query_loc_backward))
#match_annealing_temp =
[annealing_temp(primer_record.primer_processed_seq)]
#primer_annealing_temp.append(LI('14nt: 13nt: 50nt:'
match_annealing_temp))
#hits_backward_match.append(LI('Match hits in compliment
sequence : %s' % record.filename,,'\n',query_backward_match))
return
DIV(UL(hits_forward_match),UL(hits_loc_forward),UL(hits_loc_backward))
return(form)
In this function the if condition is not getting executed what could be the
error .The application is not generating ticket when I initiate the form
execution.
--