python-sonarqube-api icon indicating copy to clipboard operation
python-sonarqube-api copied to clipboard

'SonarQubeClient' object has no attribute 'settings'

Open dvelardez opened this issue 2 years ago • 0 comments

I can no longer update the settings although the documentation indicates that it is possible. This commit breaks the compatibility of my app, is there a workaround to update SonarQube settings?

I am getting this error on my app: 'SonarQubeClient' object has no attribute 'settings' Below is a part of my code:

def update_settings(args):
    # oidc configuration
    sonar = SonarQubeClient(sonarqube_url=args.Url, username=args.Username, password=args.Password)
    sonar.settings.update_setting_value(key='sonar.core.serverBaseURL', value=args.Url)
    sonar.settings.update_setting_value(key='sonar.auth.oidc.enabled', value='true')
    sonar.settings.update_setting_value(key='sonar.auth.oidc.issuerUri', value=args.IssuerURI)
    sonar.settings.update_setting_value(key='sonar.auth.oidc.clientId.secured', value=args.ClientID)
    sonar.settings.update_setting_value(key='sonar.auth.oidc.clientSecret.secured', value=args.ClientSecret)
    sonar.settings.update_setting_value(key='sonar.auth.oidc.groupsSync', value='true')
    sonar.settings.update_setting_value(key='sonar.auth.oidc.groupsSync.claimName', value=args.GroupsClaimName)

I appreciate if you can help me.

dvelardez avatar Oct 30 '23 12:10 dvelardez