def main(): try: pdbid = sys.argv[1] except IndexError: sys.exit(1) r = start_job(pdbid.upper()) console.stdoutln("%s" % r)
def prepare_submission(pdbfile): """class SubmitPDBPage """ job_id = mysql.job_new() ## basic sanity checks ## If check_upload returns anything but a empty string, the server will ## inform the user of the problem and not proceed any further. ln = pdbfile.split("\n") r = check_upload(job_id, ln) if r != '': console.stdoutln("WARNING: %s" % str(r)) sys.exit(0) result = webtlsmdd.set_structure_file(job_id, xmlrpclib.Binary(pdbfile)) if result != "": console.stdoutln("ERROR: Failed to submit structure. %s. Please try again." % result) sys.exit(0) return job_id
def prepare_submission(pdbfile): """class SubmitPDBPage """ job_id = mysql.job_new() ## basic sanity checks ## If check_upload returns anything but a empty string, the server will ## inform the user of the problem and not proceed any further. ln = pdbfile.split("\n") r = check_upload(job_id, ln) if r != '': console.stdoutln("WARNING: %s" % str(r)) sys.exit(0) result = webtlsmdd.set_structure_file(job_id, xmlrpclib.Binary(pdbfile)) if result != "": console.stdoutln( "ERROR: Failed to submit structure. %s. Please try again." % result) sys.exit(0) return job_id