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

Add debug log #1151

Merged
merged 6 commits into from
Jun 17, 2024
Merged

Add debug log #1151

merged 6 commits into from
Jun 17, 2024

Conversation

paulineribeyre
Copy link
Contributor

Link to JIRA ticket if there is one:

TODO: change authutils dependency to uc-cdis/authutils#77

New Features

Breaking Changes

Bug Fixes

Improvements

  • Add debug log when the authorization header cannot be parsed
  • Print stack trace when usersync cannot downloaded files from an ftp/sftp server

Dependency updates

Deployment changes

Avantol13
Avantol13 previously approved these changes Jun 14, 2024
@paulineribeyre
Copy link
Contributor Author

need to merge #1116 and then update this branch so the unit tests run

@paulineribeyre
Copy link
Contributor Author

fence pods failing to come up with:

spawned uWSGI worker 2 (pid: 1738, cores: 1)
*** Stats server enabled on 127.0.0.1:9191 fd: 11 ***
Traceback (most recent call last):
  File "/fence/wsgi.py", line 1, in <module>
    from fence import app_init, app
  File "/fence/fence/__init__.py", line 11, in <module>
    from authutils.oauth2.client import OAuthClient
  File "/usr/local/lib/python3.9/site-packages/authutils/oauth2/client/__init__.py", line 1, in <module>
    from authutils.oauth2.client.client import OAuthClient
  File "/usr/local/lib/python3.9/site-packages/authutils/oauth2/client/client.py", line 2, in <module>
    from authlib.integrations.flask_client import OAuth as OAuthClient
ModuleNotFoundError: No module named 'authlib.integrations'
unable to load app 0 (mountpoint='') (callable not found or import error)
*** no app loaded. going in full dynamic mode ***
Traceback (most recent call last):
  File "/fence/wsgi.py", line 1, in <module>
    from fence import app_init, app
  File "/fence/fence/__init__.py", line 11, in <module>
    from authutils.oauth2.client import OAuthClient
  File "/usr/local/lib/python3.9/site-packages/authutils/oauth2/client/__init__.py", line 1, in <module>
    from authutils.oauth2.client.client import OAuthClient
  File "/usr/local/lib/python3.9/site-packages/authutils/oauth2/client/client.py", line 2, in <module>
    from authlib.integrations.flask_client import OAuth as OAuthClient
ModuleNotFoundError: No module named 'authlib.integrations'
unable to load app 0 (mountpoint='') (callable not found or import error)
*** no app loaded. going in full dynamic mode ***
--- no python application found, check your startup logs for errors ---

@BedfordWest

@paulineribeyre
Copy link
Contributor Author

i believe the error above means it installed authlib 1.3.0 (as used in authutils) instead of authlib v0.11_CVE_patch_v1 (which should be used here)

@paulineribeyre
Copy link
Contributor Author

Unable to upgrade authutils for now because of a conflict with the authlib version:

Because authutils (6.2.5) depends on authlib (>=1.1.0)
 and fence depends on authlib (*) @ git+https://github.com/uc-cdis/authlib@v0.11_CVE_patch_v1, authutils is forbidden.
So, because fence depends on authutils (=6.2.5), version solving failed.

We can upgrade authutils when fence is moved off this authlib patch

@coveralls
Copy link

coveralls commented Jun 17, 2024

Pull Request Test Coverage Report for Build 9554018069

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 19 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.02%) to 75.02%

Files with Coverage Reduction New Missed Lines %
jwt/utils.py 5 73.68%
auth.py 14 87.58%
Totals Coverage Status
Change from base Build 9550344446: -0.02%
Covered Lines: 7622
Relevant Lines: 10160

💛 - Coveralls

@paulineribeyre paulineribeyre merged commit 7532951 into master Jun 17, 2024
9 of 10 checks passed
@paulineribeyre paulineribeyre deleted the add-debug-log branch June 17, 2024 21:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants