Skip to content

Conversation

@pcrespov
Copy link
Member

@pcrespov pcrespov commented Jun 13, 2025

What do these changes do?

ReDoc

image

This PR introduces a controller in the functions domain that serves the GET /me/function-permissions endpoint, as required by the front-end in #7888.

It leverages the existing service-layer functionality exposed in #7868 via _functions_service.get_functions_user_api_access_rights.

The implementation follows a minimalistic approach, focusing on fulfilling the immediate client requirements, while being structured to allow easy future extensions (e.g. expanding the response model or improving test coverage).

  • NOTE: @odeimaiz due to camel-case rule, you have to modify a bit the fields you use in your response model.

Related issue/s

How to test

cd services/web/server
make install-dev
pytest -vv tests/unit/with_dbs/04/functions_rpc -k test_list_user_functions_permissions

Dev-ops

None

@pcrespov pcrespov self-assigned this Jun 13, 2025
@pcrespov pcrespov added this to the Engage milestone Jun 13, 2025
@pcrespov pcrespov added release Preparation for pre-release/release a:webserver webserver's codebase. Assigning the area is particularly useful for bugs labels Jun 13, 2025
@codecov
Copy link

codecov bot commented Jun 13, 2025

Codecov Report

Attention: Patch coverage is 81.81818% with 2 lines in your changes missing coverage. Please review.

Project coverage is 89.50%. Comparing base (5d5eac3) to head (649826b).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #7901      +/-   ##
==========================================
+ Coverage   87.94%   89.50%   +1.55%     
==========================================
  Files        1845     1441     -404     
  Lines       71130    59784   -11346     
  Branches     1220      476     -744     
==========================================
- Hits        62558    53511    -9047     
+ Misses       8220     6152    -2068     
+ Partials      352      121     -231     
Flag Coverage Δ
integrationtests 64.23% <55.55%> (+0.01%) ⬆️
unittests 87.82% <81.81%> (+1.28%) ⬆️
Components Coverage Δ
api 76.84% <ø> (ø)
pkg_aws_library ∅ <ø> (∅)
pkg_dask_task_models_library ∅ <ø> (∅)
pkg_models_library 93.25% <100.00%> (+<0.01%) ⬆️
pkg_notifications_library ∅ <ø> (∅)
pkg_postgres_database ∅ <ø> (∅)
pkg_service_integration 69.92% <ø> (ø)
pkg_service_library ∅ <ø> (∅)
pkg_settings_library ∅ <ø> (∅)
pkg_simcore_sdk 84.99% <ø> (-0.06%) ⬇️
agent 96.29% <ø> (ø)
api_server 91.85% <ø> (ø)
autoscaling 96.03% <ø> (ø)
catalog 92.29% <ø> (ø)
clusters_keeper 99.13% <ø> (ø)
dask_sidecar 91.79% <ø> (ø)
datcore_adapter ∅ <ø> (∅)
director 76.82% <ø> (+0.09%) ⬆️
director_v2 91.07% <ø> (-0.08%) ⬇️
dynamic_scheduler 96.69% <ø> (ø)
dynamic_sidecar 90.09% <ø> (ø)
efs_guardian 89.65% <ø> (ø)
invitations 93.00% <ø> (ø)
payments 92.57% <ø> (ø)
resource_usage_tracker 89.03% <ø> (-0.17%) ⬇️
storage 87.71% <ø> (+0.24%) ⬆️
webclient ∅ <ø> (∅)
webserver 87.52% <77.77%> (+0.03%) ⬆️

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5d5eac3...649826b. Read the comment docs.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@pcrespov pcrespov changed the title Is1901/function permisions rest ✨ Add Controller for /me/function-permissions Endpoint in Functions Domain Jun 13, 2025
@pcrespov pcrespov force-pushed the is1901/function-permisions-rest branch from 6e195c5 to 124caa7 Compare June 13, 2025 16:02
Copy link
Contributor

@wvangeit wvangeit left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks.

Copy link
Member

@odeimaiz odeimaiz left a comment

Choose a reason for hiding this comment

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

Merci!!

@pcrespov pcrespov force-pushed the is1901/function-permisions-rest branch from 124caa7 to 7165b29 Compare June 16, 2025 07:37
@pcrespov pcrespov enabled auto-merge (squash) June 16, 2025 07:38
@pcrespov
Copy link
Member Author

@mergify queue

@mergify
Copy link
Contributor

mergify bot commented Jun 16, 2025

queue

🟠 Waiting for conditions to match

  • any of: [🔀 queue conditions]
    • all of: [📌 queue conditions of queue default]
      • label=🤖-automerge
      • #approved-reviews-by >= 2 [🛡 GitHub branch protection]
      • #approved-reviews-by>=2
      • #changes-requested-reviews-by = 0 [🛡 GitHub branch protection]
      • #changes-requested-reviews-by=0
      • #review-threads-unresolved = 0 [🛡 GitHub branch protection]
      • #review-threads-unresolved=0
      • -conflict
      • -draft
      • base=master
      • branch-protection-review-decision = APPROVED [🛡 GitHub branch protection]
      • label!=🤖-do-not-merge
      • any of: [🛡 GitHub branch protection]
        • check-skipped = deploy to dockerhub
        • check-neutral = deploy to dockerhub
        • check-success = deploy to dockerhub
      • any of: [🛡 GitHub branch protection]
        • check-success = system-tests
        • check-neutral = system-tests
        • check-skipped = system-tests
      • any of: [🛡 GitHub branch protection]
        • check-success = unit-tests
        • check-neutral = unit-tests
        • check-skipped = unit-tests
      • any of: [🛡 GitHub branch protection]
        • check-success = check OAS' are up to date
        • check-neutral = check OAS' are up to date
        • check-skipped = check OAS' are up to date
      • any of: [🛡 GitHub branch protection]
        • check-success = integration-tests
        • check-neutral = integration-tests
        • check-skipped = integration-tests
      • any of: [🛡 GitHub branch protection]
        • check-success = build-test-images (frontend) / build-test-images
        • check-neutral = build-test-images (frontend) / build-test-images
        • check-skipped = build-test-images (frontend) / build-test-images
  • -closed [📌 queue requirement]
  • -conflict [📌 queue requirement]
  • -draft [📌 queue requirement]
  • any of: [📌 queue -> configuration change requirements]
    • -mergify-configuration-changed
    • check-success = Configuration changed

@odeimaiz odeimaiz added the 🤖-automerge marks PR as ready to be merged for Mergify label Jun 16, 2025
@odeimaiz
Copy link
Member

@mergify queue

@mergify
Copy link
Contributor

mergify bot commented Jun 16, 2025

queue

🛑 The pull request has been merged manually

The pull request has been merged manually at 975e587

@sonarqubecloud
Copy link

@pcrespov pcrespov merged commit 975e587 into ITISFoundation:master Jun 16, 2025
92 of 96 checks passed
@pcrespov pcrespov deleted the is1901/function-permisions-rest branch June 16, 2025 10:31
@matusdrobuliak66 matusdrobuliak66 mentioned this pull request Aug 5, 2025
88 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🤖-automerge marks PR as ready to be merged for Mergify a:webserver webserver's codebase. Assigning the area is particularly useful for bugs release Preparation for pre-release/release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants