Skip to content

feat(api): adds automatic keycloak verification#12

Merged
Matt-Carre merged 10 commits into
mainfrom
keycloak_auth
Jul 21, 2026
Merged

feat(api): adds automatic keycloak verification#12
Matt-Carre merged 10 commits into
mainfrom
keycloak_auth

Conversation

@Matt-Carre

Copy link
Copy Markdown
Collaborator

Adds keycloak verification to the graphql file

@codecov

codecov Bot commented Jun 29, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (ae0adae) to head (2f54e60).

Additional details and impacted files
@@            Coverage Diff            @@
##              main       #12   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            3         5    +2     
  Lines           22        77   +55     
=========================================
+ Hits            22        77   +55     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Matt-Carre
Matt-Carre force-pushed the keycloak_auth branch 5 times, most recently from 384fc4a to ba92fc2 Compare June 29, 2026 13:35
@Matt-Carre

Matt-Carre commented Jun 29, 2026

Copy link
Copy Markdown
Collaborator Author

Not entirely sure how to test the "_open_auth_url" portion of the "return_key" function. Do you guys have any ideas?

In the mean time, once this and the previous PR are approved, this will be moved to the auth folder, and will also delete the old get_token.py file.

Comment thread src/python_interface_to_workflows/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/keycloak_checker.py Outdated
Comment thread pyproject.toml Outdated
@Matt-Carre
Matt-Carre force-pushed the keycloak_auth branch 11 times, most recently from f184967 to 47bccfa Compare July 1, 2026 11:21

@JamesDoingStuff JamesDoingStuff left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work with the tests 👍 What's the process for using this auth mechanism? Or is that to come in future? I tried running a print(return_key(True)) but I only seem to get Client not found from keycloak

Comment thread notes
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
davehadley
davehadley previously approved these changes Jul 16, 2026
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/auth/open_auth_url.py
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/auth/open_auth_url.py
Comment thread src/python_interface_to_workflows/submit_to_graphql.py Outdated
Comment thread notes
@Matt-Carre
Matt-Carre force-pushed the keycloak_auth branch 2 times, most recently from 2d394ab to 591dcf2 Compare July 16, 2026 12:16
@Matt-Carre
Matt-Carre force-pushed the keycloak_auth branch 7 times, most recently from 285ef58 to b96d0d3 Compare July 17, 2026 12:06
@JamesDoingStuff

Copy link
Copy Markdown
Collaborator

I think this is in need of splitting up. To me, it seems that there are three distinct things being added here, each of which should be its own PR:

  1. Keycloak auth (this PR)
  2. Jinja templating
  3. The recreated example workflow template

If you could please have a go at separating, then this should be easier to get reviewed & merged

@Matt-Carre
Matt-Carre force-pushed the keycloak_auth branch 2 times, most recently from cfb5cf7 to 19a8efe Compare July 20, 2026 08:57

@JamesDoingStuff JamesDoingStuff left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully tested getting a token 👍 Couple of comments added, plus @davehadley's still need addressing

Comment thread src/copier_template/src/{{ project_name }}/templates/example.yaml.jinja Outdated
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py Outdated
Comment thread src/python_interface_to_workflows/auth/keycloak_checker.py
@Matt-Carre
Matt-Carre force-pushed the keycloak_auth branch 2 times, most recently from fddbf3a to 1d4a7c5 Compare July 21, 2026 11:01
@Matt-Carre
Matt-Carre merged commit 83d5447 into main Jul 21, 2026
11 checks passed
@Matt-Carre
Matt-Carre deleted the keycloak_auth branch July 21, 2026 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants