Repository navigation
Conversation
A group's name, description and options were set through `profile`, as
an attribute and as a constructor keyword. `profile` is also the keyword
that selects which account to connect as, on every resource, so a
group created with `profile={...}` connected with no credentials.
Group settings are now `config`, as on jobs and repos:
org.Group("reports", config={"options": {"allow_inbound_mail": True}})
group.config.options.allow_inbound_mail = True
`profile` on a group now only selects the connection. The API paths
under `/profile` are unchanged.
The API returns option values with a trailing newline, so every option read back as False. Strip the value before comparing.
Contributor
Author
|
Folded into #333. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Group settings were exposed as
profile, which collides with theprofile=keyword every resource accepts to select a connection profile from the config file. Passing the settings as a keyword was read as a connection profile:No config profile matched the dict, so no token was loaded and the request went out unauthenticated, which the API answers with a 404.
This renames the group settings to
config, matching the naming used by other resources:A second commit fixes group option getters, which always returned
Falsebecause the value read from the API ends in a newline.Breaking change
group.profileis nowgroup.config, and theprofile=constructor keyword on groups now only selects the connection profile, as it does everywhere else. There is no alias.NovemGroupProfileis nowNovemGroupConfig(novem/group/config.py).The API paths are unchanged; the settings are still read from and written to
/profile/....Testing
config.profile=on a group selects the connection profile, and option reads ignore the trailing newline.