Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve debugging experience #12961

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

sirux88
Copy link
Contributor

@sirux88 sirux88 commented Feb 8, 2025

Details

This PR is ment to improve the debugging experiance:

  1. It sets the vscode debugging python configurations to use relative paths instead of absolute paths. This reverts the last commit of lifecycle: much improved debugging experience #12804
  2. Since usage of docker-compose.override.yml is necessary due to website/docs: updated debugging docs #12809 it adds docker-compose.override.yml to gitignore to remove noice when comitting

Further thoughts:

  1. Remove Debug: Attach Worker configuration since it only duplicates Debug: Attach Server Core in its curretns state. Renaming Debug: Attach Server Core would be useful for clarification then
  2. If debugging worker and server should be able at the same time it would be necessary distinguish between both when setting up the debugging ports on startup or via port forwarding in docker-compose.override.yml.
    Both needs to be documented somewhere
  3. The dev-server containers don't include the dev-dependencies. They need to be installed in runtime but the container needs root rights to do that. Might be ok for developing but the dependencies could be included aswell by making changes to Dockerfile (Sidemark: Image size will increase ~30%)

Checklist

  • Local tests pass (ak test authentik/)
  • The code has been formatted (make lint-fix)

If an API change has been made

  • The API schema has been updated (make gen-build)

If changes to the frontend have been made

  • The code has been formatted (make web)

If applicable

  • The documentation has been updated
  • The documentation has been formatted (make website)

@sirux88 sirux88 requested review from a team as code owners February 8, 2025 15:11
Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for authentik-storybook canceled.

Name Link
🔨 Latest commit 94721de
🔍 Latest deploy log https://app.netlify.com/sites/authentik-storybook/deploys/67a7740b65045000086b94c0

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for authentik-docs canceled.

Name Link
🔨 Latest commit 94721de
🔍 Latest deploy log https://app.netlify.com/sites/authentik-docs/deploys/67a7740b4cc5860008cd7f02

Copy link

codecov bot commented Feb 8, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.74%. Comparing base (daebeb1) to head (94721de).

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #12961      +/-   ##
==========================================
- Coverage   92.75%   92.74%   -0.02%     
==========================================
  Files         785      785              
  Lines       39580    39580              
==========================================
- Hits        36714    36710       -4     
- Misses       2866     2870       +4     
Flag Coverage Δ
e2e 48.50% <ø> (-0.06%) ⬇️
integration 24.54% <ø> (ø)
unit 90.43% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@sirux88
Copy link
Contributor Author

sirux88 commented Feb 8, 2025

@BeryJu:
As mentioned in #12804 I reviewed what you stated there. I could not reproduce your issue. After properly setting up everything (pulling dev-server container, creating docker-compose.override.yml, creating .env file and spinning up docker compose) I could debug the python part of the application.

For testing purpose I added some minor python changes. After that the breaking points around the changes didn't get hit anymore (which makes sense since the changes aren't visible in the container itself).
I could resolve this by adding:

volumes:
  - ./authentik:/authentik

to docker-compose.override.yml

Maybe you could reevaluate your problem with this PR/comment

@sirux88 sirux88 changed the title Improve debugging experiance Improve debugging experience Feb 8, 2025
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.

1 participant