#1745 allow comma delimiter for allowed_methods
Merged 2 years ago by mikem. Opened 2 years ago by tkopecek.
tkopecek/koji issue1744  into  master

@@ -29,7 +29,7 @@ 

      # read configuration only once

      if config is None:

          config = koji.read_config_files([(CONFIG_FILE, True)])

-         allowed_methods = config.get('permissions', 'allowed_methods').split()

+         allowed_methods = config.get('permissions', 'allowed_methods').split(',')

          if len(allowed_methods) == 1 and allowed_methods[0] == '*':

              allowed_methods = '*'


Example config says, that comma is allowed, but it was not true. I've made it more in line with rest of configs (allowing only comma)

Fixes: https://pagure.io/koji/issue/1744

Wouldn't the first split return a list, causing the second split to return AttributeError?

rebased onto a76f02b

2 years ago

Is there a chance that someone is relying on splitting by whitespace?

There is a slight chance, but I don't know about any other deployment using this plugin than ours.

ok then :smile: :thumbsup:

Commit 4701739 fixes this pull-request

Pull-Request has been merged by mikem

2 years ago

Metadata Update from @jcupova:
- Pull-request tagged with: testing-done

2 years ago