Forum Discussion
Github PowerBi connector - JSON error
- 1 year ago
I have resolved the issue writing some power query myself and found a workaround for the dynamic data source issues I had.
For those that are interested, I documented the approach here: https://www.linkedin.com/pulse/using-power-queries-directly-from-github-repository-van-der-vorst-wm6pe/
Thanks. I also found that it is not just comments causing the JSON error. When removing them from github, I still get the error but with the open bracket "(". I am just continue to try to make it work with Web.Contents and if I can't get that to work I will likely end up copying the function in directly (which does work, but means the management in github is no longer viable)
Hi, ferryv
Thank you for your prompt response. Your suggested approach is indeed a good alternative.
However, based on the new information you provided, we suspect there might be an issue with the processing in Power Query. Here are two recommendations:
1.First, we suggest using the Json.Document() function to convert the binary output of the Web.Contents() function to JSON. This aligns more closely with the official examples, as we cannot rule out errors caused by Text.FromBinary(). For details, please refer to the following documentation:
Web.Contents - PowerQuery M | Microsoft Learn
Json.Document - PowerQuery M | Microsoft Learn
2.Second, you can use the Try syntax to debug each step of your Power Query process:
For details, please refer to the following documentation:
https://learn.microsoft.com/en-us/power-query/error-handling#use-try-with-custom-logic
I hope my answer is helpful to you.
Best Regards,
Leroy Lu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.