Title: Cannot locate jwt package in app_check.py after updating to firebase-admin-python V6.0.0 · Issue #653 · firebase/firebase-admin-python · GitHub
Open Graph Title: Cannot locate jwt package in app_check.py after updating to firebase-admin-python V6.0.0 · Issue #653 · firebase/firebase-admin-python
X Title: Cannot locate jwt package in app_check.py after updating to firebase-admin-python V6.0.0 · Issue #653 · firebase/firebase-admin-python
Description: [REQUIRED] Step 2: Describe your environment Operating System version: MacOS 10.15.7 Firebase SDK version: V6.0.0 Firebase Product: app_check Python version: 3.7.9 Pip version: 22.1.2 [REQUIRED] Step 3: Describe the problem Updated to V6...
Open Graph Description: [REQUIRED] Step 2: Describe your environment Operating System version: MacOS 10.15.7 Firebase SDK version: V6.0.0 Firebase Product: app_check Python version: 3.7.9 Pip version: 22.1.2 [REQUIRED] St...
X Description: [REQUIRED] Step 2: Describe your environment Operating System version: MacOS 10.15.7 Firebase SDK version: V6.0.0 Firebase Product: app_check Python version: 3.7.9 Pip version: 22.1.2 [REQUIRED] St...
Opengraph URL: https://github.com/firebase/firebase-admin-python/issues/653
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Cannot locate jwt package in app_check.py after updating to firebase-admin-python V6.0.0","articleBody":"### [REQUIRED] Step 2: Describe your environment\r\n\r\n * Operating System version: MacOS 10.15.7 \r\n * Firebase SDK version: `V6.0.0`\r\n * Firebase Product: `app_check`\r\n * Python version: 3.7.9\r\n * Pip version: 22.1.2\r\n\r\n### [REQUIRED] Step 3: Describe the problem\r\nUpdated to V6.0.0 and attempted to run my development server within Flask and encountered the following errors:\r\n\r\n```\r\nError: While importing 'api', an ImportError was raised:\r\n\r\nTraceback (most recent call last):\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/env/lib/python3.7/site-packages/flask/cli.py\", line 218, in locate_app\r\n __import__(module_name)\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/api/api.py\", line 2, in \u003cmodule\u003e\r\n from auth import validate_auth, validate_app\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/api/auth.py\", line 2, in \u003cmodule\u003e\r\n from service.firebase import verify_auth_token, verify_app_token\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/api/service/firebase.py\", line 2, in \u003cmodule\u003e\r\n from firebase_admin import credentials, auth, firestore, app_check\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/env/lib/python3.7/site-packages/firebase_admin/app_check.py\", line 18, in \u003cmodule\u003e\r\n import jwt\r\nModuleNotFoundError: No module named 'jwt'\r\n```\r\n\r\nAfter attempting to install the jwt package to fix the issue, a new error occurred:\r\n\r\n```\r\nError: While importing 'api', an ImportError was raised:\r\n\r\nTraceback (most recent call last):\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/env/lib/python3.7/site-packages/flask/cli.py\", line 218, in locate_app\r\n __import__(module_name)\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/api/api.py\", line 2, in \u003cmodule\u003e\r\n from auth import validate_auth, validate_app\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/api/auth.py\", line 2, in \u003cmodule\u003e\r\n from service.firebase import verify_auth_token, verify_app_token\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/api/service/firebase.py\", line 2, in \u003cmodule\u003e\r\n from firebase_admin import credentials, auth, firestore, app_check\r\n File \"/Users/kdfriedman/Desktop/curate-ai-python-api/env/lib/python3.7/site-packages/firebase_admin/app_check.py\", line 19, in \u003cmodule\u003e\r\n from jwt import PyJWKClient, ExpiredSignatureError, InvalidTokenError\r\nImportError: cannot import name 'PyJWKClient' from 'jwt' (/Users/kdfriedman/Desktop/curate-ai-python-api/env/lib/python3.7/site-packages/jwt/__init__.py)\r\n```\r\n#### Steps to reproduce:\r\n\r\nI updated to V6 of the SDK and immediately encountered this issue. When I attempted to install the jwt package, a different error occurred.\r\n\r\n#### Relevant Code:\r\n\r\n```\r\nimport firebase_admin\r\nfrom firebase_admin import credentials, auth, firestore, app_check\r\nimport os\r\n\r\n# Initialize the default app\r\nENV_KEYS = {\r\n \"CREDS_GO_HERE\"\r\n}\r\n\r\nCREDENTIALS = credentials.Certificate(ENV_KEYS)\r\nfirebase_app = firebase_admin.initialize_app(CREDENTIALS)\r\n\r\nverify_app_token = app_check.verify_token\r\n```\r\n","author":{"url":"https://github.com/kdfriedman","@type":"Person","name":"kdfriedman"},"datePublished":"2022-10-13T20:00:31.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/653/firebase-admin-python/issues/653"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:de54766d-36a2-a825-e180-7a79098ecce7 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D9E8:219F18:1A071:2270F:698F355C |
| html-safe-nonce | 7514a2968df290e374165990ef0723e2d6deda7cb40b61a2eae4a9f56d43a969 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOUU4OjIxOUYxODoxQTA3MToyMjcwRjo2OThGMzU1QyIsInZpc2l0b3JfaWQiOiI0ODg3NDE2MjE2MTU3NjMxODM2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 3d72aa5e418482ecdc454744d5067360c3f187e7cd5560238df22eb1d31e3d57 |
| hovercard-subject-tag | issue:1408354558 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/firebase/firebase-admin-python/653/issue_layout |
| twitter:image | https://opengraph.githubassets.com/0b19addc23b383440451a23ee524024fcb34f8937859681e82197b7a3c34e536/firebase/firebase-admin-python/issues/653 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/0b19addc23b383440451a23ee524024fcb34f8937859681e82197b7a3c34e536/firebase/firebase-admin-python/issues/653 |
| og:image:alt | [REQUIRED] Step 2: Describe your environment Operating System version: MacOS 10.15.7 Firebase SDK version: V6.0.0 Firebase Product: app_check Python version: 3.7.9 Pip version: 22.1.2 [REQUIRED] St... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | kdfriedman |
| hostname | github.com |
| expected-hostname | github.com |
| None | 6102991c714c1a6a27d05fb4f96ea6ca87a6750b4f093b95cc57ed1b84b145a1 |
| turbo-cache-control | no-preview |
| go-import | github.com/firebase/firebase-admin-python git https://github.com/firebase/firebase-admin-python.git |
| octolytics-dimension-user_id | 1335026 |
| octolytics-dimension-user_login | firebase |
| octolytics-dimension-repository_id | 84979152 |
| octolytics-dimension-repository_nwo | firebase/firebase-admin-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 84979152 |
| octolytics-dimension-repository_network_root_nwo | firebase/firebase-admin-python |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e2fe82f90e107669021e243add8f74ea2a9be1b3 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width