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
Intellij plugin #10
Comments
@moyix are you aware of any opensource implementation that we could use to build the Intellij plugin for fauxpilot? |
@Xelef2000 I know you have suggested for vscode plugin https://github.com/hieunc229/copilot-clone. Are you aware of anything equivalent for Intellij plugin? |
Seconding this. I do wonder if it might be possible to pull some hostsfile trickery with the existing intellij plugin to redirect requests to the local inference server instead. |
You may want to dig into the code of the Copilot IntelliJ plugin to see if they have a similar debug setting to |
I took a quick look at the plugin code -- the code does seem to look for Side note: Both intellij and neo-vim copilot plugins have a thin wrapper that effectively calls common JS code (the same as used by VSCode extension). When/if you do find the place to set these variables, here are the typical values for them if you're using Fauxpilot with default settings:
|
Has anyone found the overrideProxyUrl configuration on Intellij ? |
The advanced options appear in the Jetbrains' copilot plugin source code do not seem to work anywhere. Maybe it is just a residue from code project migration. Jetbrains IDE use something like XML for software settings, and Copilot plugin does not seem to offer interfaces for changing debug options in such config files. |
I've tried to replace |
anyone worked on Intellij plugin successfully? |
While the IntelliJ plugin does use the same agent.js to fetch completions from /engines/copilot-codex, it doesn't support Yes, you can override system proxy directly in IntelliJ itself, but Copilot throws errors related to self-signed certificates. As a last resort, I modified the plugin source code and got it working. Steps to follow:
Step 2 is required, since the IntelliJ plugin uses agent.js only when it cannot find the binaries. |
Hello @vibin, did you manage to get it working on the current version of PyCharm? it's currently 1 AM here and I've been trying everything from using an old version of the plugin to reading the source code of the plugin, without success... |
@bananasmoothii the approach which I mentioned should work for all Jetbrains IDEs - I don't think Pycharm is any different. I have tested in the following IDEs: IntelliJ Ultimate, IntelliJ Community, Android Studio, WebStorm |
When I wrote this, I was getting 404 errors but I then found out that it was because the sent prompt was too long, now I have issues where it sometimes takes 3 minutes to respond, although sometimes it takes less than a second. Then I have issues where the server apparently doesn't produce valid JSON, and when looking at the data I had a response with multiple |
hi @vibin , I'm glad to see the solution you proposed. I tried it locally. After I performed the second step (renaming the binary agent file in the /bin directory) and before performing the third step, I tried to start the IDE to verify the Copilot plug-in. When executing the agent.js file, I found that the status of the Copilot plug-in was abnormal, showing "not signed in to github". This seems inconsistent with what is stated in your scenario.
I am currently using IDEA version 21.3.3 and the GitHub Copilot plug-in version 1.2.9.2684. I am not sure whether this is related to the IDE and plug-in version. Can I ask you whether this solution can still be used? It would be great if you could tell me your IDE version and plug-in version. |
@wanyukang Yes, we use this solution in our org. It's tested and working for ~200 developers (IntelliJ, Android Studio) Have you tried signing into Github with the binary agent flow disabled? Regarding versions, I think anything latest or near to latest should be fine. For example, try copilot-intellij/1.4.3.3913 and JetBrains-IU/232.10227.8. IntelliJ 21.3.3 is 2 years old, so that could be an issue... |
@vibin Thanks for your quick reply. I did try to log into GitHub after disabling the binary, but instead of showing the login window, the plugin threw an error saying "GitHub Copilot: Failed to initiate the GitHub login process. Please try again." I plan to try upgrading my version of IDEA and the version of the GitHub Copilot plugin to see if this is the problem. |
I figured it out, it was a problem with the local nodeJS version. Since I am maintaining an old nodeJS project, my local default node version is node8, so when I manually run |
@wanyukang Good catch! Yes, most of our developers are on Node16 (we wrote a shell script which installs Node16 if it is not present on the system, before making changes to the plugin). |
One more thing, when checking whether the versions of IDEA and Github Copilot are affected, I updated Github Copilot to the latest version 1.4.4.3955. Then I read the code of Currently, there are only 3 supported parameters Combined with the solution proposed by @vibin to use |
Would be awesome to have an plugin for fauxpilot!
The text was updated successfully, but these errors were encountered: