Github data source doesn't work at all #688

Closed
opened 2026-02-16 10:20:12 -05:00 by yindo · 3 comments
Owner

Originally created by @hiiamboris on GitHub (Oct 5, 2025).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues Dify issues & Dify Official Plugins, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.9.1

Plugin version

0.3.3

Cloud or Self Hosted

Cloud

Steps to reproduce

  1. Install GH plugin (tried both self-hosted and cloud-hosted)

  2. Generate access token (tried both classic and fine-grained)

  3. Configure it in the Settings -> Data Source -> Github, Save, it succeeds so far

  4. Create a simplest pipeline:

  5. 'Run this step' always fails with: req_id: 029237627c PluginInvokeError: {"args":{},"error_type":"TypeError","message":"string indices must be integers, not 'str'"}

  6. There's no choice of Github repository or owner or anything ever offered

  7. Make a new OAuth token on Github

  8. Generate a secret for it

  9. Set authorization callback to "https://.../console/api/oauth/callback" from readme or to "https://.../console/api/oauth/plugin/langgenius/github_datasource/github_datasource/datasource/callback" from the plugin's OAuth page (doesn't matter, result is the same)

  10. In Settings -> Data Source -> Github select OAuth, fill in client id and secret, press 'Save & Authorize'

  11. Authorization always fails:

✔️ Error log

nothing stands out in the plugin-daemon logs

Originally created by @hiiamboris on GitHub (Oct 5, 2025). ### Self Checks - [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [x] I have searched for existing issues [Dify issues](https://github.com/langgenius/dify/issues) & [Dify Official Plugins](https://github.com/langgenius/dify-official-plugins/issues), including closed ones. - [x] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [x] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [x] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.9.1 ### Plugin version 0.3.3 ### Cloud or Self Hosted Cloud ### Steps to reproduce 1. Install GH plugin (tried both self-hosted and cloud-hosted) 2. Generate access token (tried both classic and fine-grained) 3. Configure it in the Settings -> Data Source -> Github, Save, it succeeds so far 4. Create a simplest pipeline: ![](https://link.storjshare.io/raw/jxfnjjold7d4xtoupll4mp7ychkq/img/5sFSLNq.png) 5. 'Run this step' always fails with: `req_id: 029237627c PluginInvokeError: {"args":{},"error_type":"TypeError","message":"string indices must be integers, not 'str'"}` 6. There's no choice of Github repository or owner or anything ever offered 7. Make a new OAuth token on Github 8. Generate a secret for it 9. Set authorization callback to "https://.../console/api/oauth/callback" from readme or to "https://.../console/api/oauth/plugin/langgenius/github_datasource/github_datasource/datasource/callback" from the plugin's OAuth page (doesn't matter, result is the same) 10. In Settings -> Data Source -> Github select OAuth, fill in client id and secret, press 'Save & Authorize' 11. Authorization always fails: ![](https://link.storjshare.io/raw/jxfnjjold7d4xtoupll4mp7ychkq/img/DEV1vv5.png) ### ✔️ Error log nothing stands out in the plugin-daemon logs
yindo added the bug label 2026-02-16 10:20:12 -05:00
yindo closed this issue 2026-02-16 10:20:12 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Oct 5, 2025):

There are two main issues here:

  1. The OAuth "invalid redirect_uri" error happens because the Dify backend does not currently support a generic OAuth callback endpoint for external plugins like GitHub. The plugin expects the redirect_uri to match exactly what is registered in your GitHub OAuth app, but Dify only wires up OAuth callbacks for a few internal sources (like Notion), so the handshake fails regardless of which callback URL you use. As a result, OAuth-based GitHub integration is not fully supported at this time, even though the plugin's README suggests otherwise. Using a Personal Access Token (PAT) with the correct scopes (repo, user:email, read:user) is the only viable option right now for authentication. source source

  2. The "string indices must be integers, not 'str'" error is likely caused by the plugin treating a string as a dictionary or list, usually due to an unexpected or missing field in the GitHub API response or user input. This is a bug in the plugin's error handling and data validation. It often happens if the plugin expects a dictionary (parsed JSON) but receives a string or list instead. This can also explain why repository/owner selection is missing in the UI—if the API response is not as expected, the plugin can't populate the selection fields. source

Recent updates to the plugin (v0.3.3) focused on error handling and dependency cleanup, but did not address these core issues. For now, use a PAT for authentication, double-check that it has the required scopes, and be aware that some plugin features (like repo selection) may not work until the plugin's response validation and the Dify backend's OAuth support are improved.

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Join Discord Share on X

@dosubot[bot] commented on GitHub (Oct 5, 2025): <!-- Answer --> There are two main issues here: 1. The OAuth "invalid redirect_uri" error happens because the Dify backend does not currently support a generic OAuth callback endpoint for external plugins like GitHub. The plugin expects the redirect_uri to match exactly what is registered in your GitHub OAuth app, but Dify only wires up OAuth callbacks for a few internal sources (like Notion), so the handshake fails regardless of which callback URL you use. As a result, OAuth-based GitHub integration is not fully supported at this time, even though the plugin's README suggests otherwise. Using a Personal Access Token (PAT) with the correct scopes (`repo`, `user:email`, `read:user`) is the only viable option right now for authentication. [source](https://github.com/langgenius/dify-official-plugins/blob/142cd22df8e8351c5168f044ca53c8c2afc4853a/datasources/github/provider/github.py) [source](https://github.com/langgenius/dify/blob/c20e0ad90d5b5e86db3fa435c71cb1f30f21f68e/api/controllers/console/auth/data_source_oauth.py) 2. The "string indices must be integers, not 'str'" error is likely caused by the plugin treating a string as a dictionary or list, usually due to an unexpected or missing field in the GitHub API response or user input. This is a bug in the plugin's error handling and data validation. It often happens if the plugin expects a dictionary (parsed JSON) but receives a string or list instead. This can also explain why repository/owner selection is missing in the UI—if the API response is not as expected, the plugin can't populate the selection fields. [source](https://github.com/langgenius/dify-official-plugins/issues/1799) Recent updates to the plugin (v0.3.3) focused on error handling and dependency cleanup, but did not address these core issues. For now, use a PAT for authentication, double-check that it has the required scopes, and be aware that some plugin features (like repo selection) may not work until the plugin's response validation and the Dify backend's OAuth support are improved. <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/a32c8b29-bca0-418e-a1f2-aa8dcc6b34dc?feedback_type=other)</sup>&nbsp;&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify-official-plugins/issues/1805)
Author
Owner

@hiiamboris commented on GitHub (Oct 27, 2025):

nice way to handle bug reports 👎

@hiiamboris commented on GitHub (Oct 27, 2025): nice way to handle bug reports 👎
Author
Owner

@Sire commented on GitHub (Jan 14, 2026):

Still not working. Tried both fine grained and personal tokens. I'm abandoning dify.ai. The Google Drive plugin is not working either.

@Sire commented on GitHub (Jan 14, 2026): Still not working. Tried both fine grained and personal tokens. I'm abandoning dify.ai. The Google Drive plugin is not working either.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify-official-plugins#688