Skip to content

Rationalize NameIDFormat config.#1741

Merged
thijskh merged 2 commits intomasterfrom
fix-nameidpolicy-config
Jan 6, 2023
Merged

Rationalize NameIDFormat config.#1741
thijskh merged 2 commits intomasterfrom
fix-nameidpolicy-config

Conversation

@thijskh
Copy link
Copy Markdown
Member

@thijskh thijskh commented Jan 5, 2023

This was a mixture of legacy supported options, some of them deprecated, and data types, and also implemented differently in some places than others.

This changes it once more but hopefully for the better:

  • The value is always either an array or null/unset.
  • You can set it to a specific array to get a specific policy. (unchanged from now)
  • You can leave it unset/null to keep the default policy. (unchanged from now)
  • You can set it to the empty array to signal that you do not want any policy to be sent.
  • The string and bool types are no longer allowed.

All in all this means that we can make code much simpler, a lot less if-branching, and also typewise make use of correct typehints.

The behaviour changes are as follows:

  • We drop the already deprecated option to set it as a string (deprecated in 1.17).
  • To not send the element you need to change false to []; this was not deprecated before but I believe setting it to false was already broken in master.

@tvdijen tvdijen force-pushed the master branch 2 times, most recently from 7e3ea19 to 2523634 Compare January 5, 2023 16:31
This was a mixture of legacy supported options, some of them
deprecated, and data types, and also implemented differently
in some places than others.

This changes it once more but hopefully for the better:
* The value is always an array or null/unset.
* You can set it to a specific array to get a specific policy.
* You can leave it unset/null to keep the default policy.
* You can set it to the empty array to signal that you do not
want any policy to be sent.
* The string and bool types are no longer allowed.

All in all this means that we can make code much simpler, a lot
less if-branching, and also typewise make use of correct typehints.

The behaviour changes are as follows:
- We drop the already deprecated option to set it as a string
  (deprecated in 1.17).
- To not send the element you need to change false to [];
  this was not deprecated before but I believe setting it to
  false was already broken in master.
@thijskh thijskh force-pushed the fix-nameidpolicy-config branch from 4054d6e to 12a282a Compare January 5, 2023 19:44
@codecov
Copy link
Copy Markdown

codecov bot commented Jan 5, 2023

Codecov Report

Merging #1741 (fa89989) into master (cb0e9ac) will increase coverage by 0.93%.
The diff coverage is 100.00%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1741      +/-   ##
============================================
+ Coverage     42.68%   43.62%   +0.93%     
  Complexity     2207     2207              
============================================
  Files            83       83              
  Lines          6192     6192              
============================================
+ Hits           2643     2701      +58     
+ Misses         3549     3491      -58     

@thijskh thijskh requested a review from tvdijen January 6, 2023 08:45
@thijskh thijskh merged commit 19d1c81 into master Jan 6, 2023
@thijskh thijskh deleted the fix-nameidpolicy-config branch January 6, 2023 11:23
thijskh added a commit that referenced this pull request Jan 6, 2023
This was a mixture of legacy supported options, some of them
deprecated, and data types, and also implemented differently
in some places than others.

This changes it once more but hopefully for the better:
* The value is always an array or null/unset.
* You can set it to a specific array to get a specific policy.
* You can leave it unset/null to keep the default policy.
* You can set it to the empty array to signal that you do not
want any policy to be sent.
* The string and bool types are no longer allowed.

All in all this means that we can make code much simpler, a lot
less if-branching, and also typewise make use of correct typehints.

The behaviour changes are as follows:
- We drop the already deprecated option to set it as a string
  (deprecated in 1.17).
- To not send the element you need to change false to [];
  this was not deprecated before but I believe setting it to
  false was already broken in master.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 7, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants