~rmescandon/jenkins-launchpad-plugin/prevent-exception-when-no-downstream-project

« back to all changes in this revision

Viewing changes to jlp/launchpadagent.py

  • Committer: Francis Ginther
  • Date: 2017-02-21 21:00:50 UTC
  • mfrom: (130.1.8 support-query-auto-mps)
  • Revision ID: francis.ginther@canonical.com-20170221210050-u2smkon0ath6awsn
Add support to query merge proposals from launchpad git repos. Originally contributied by albaguirre and powersj. [r=albaguirre,powersj]

Show diffs side-by-side

added added

removed removed

Lines of Context:
61
61
        get_config_option('credential_store_path'))
62
62
    lp_app = get_config_option('lp_app')
63
63
    lp_env = get_config_option('lp_env')
 
64
    try:
 
65
        lp_version = get_config_option('lp_version')
 
66
    except KeyError:
 
67
        lp_version = Launchpad.DEFAULT_VERSION;
 
68
 
64
69
    authorization_engine = AuthorizeRequestTokenWithConsole(lp_env, lp_app)
65
70
    return Launchpad.login_with(lp_app, lp_env,
66
71
                                credential_store=store,
67
72
                                authorization_engine=authorization_engine,
68
 
                                launchpadlib_dir=launchpadlib_dir)
 
73
                                launchpadlib_dir=launchpadlib_dir,
 
74
                                version=lp_version)