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

Handling UnknownExtraConf error correctly #8

Open
hassec opened this issue Jul 9, 2015 · 5 comments
Open

Handling UnknownExtraConf error correctly #8

hassec opened this issue Jul 9, 2015 · 5 comments

Comments

@hassec
Copy link
Contributor

hassec commented Jul 9, 2015

Right now the file .ycm_extra_conf.py needs to be specified in the server configuration file or the location needs to be whitelisted for the ycmd-server to load it.
The Server automatically searches recursivly for these conf-files and responds with an http-error 500 of type UnknownExtraConf which includes the path of the first file found.
I think we should include a popup to ask the user if the file should be loaded.

In Addition one could maybe include a command to (re)load a conf-file that lies in the current project folder to partly solve #2.

@LuckyGeck
Copy link
Owner

Yeh, this idea is cool. But i don't understand, when we will get this type of notification. Maybe there is any documentation on this particular call?

@hassec
Copy link
Contributor Author

hassec commented Jul 10, 2015

the whole UnkownExtraConf was discussed here abingham/emacs-ycmd#19.
But somethingelse you could try is to play with the example client that comes with ycmd.
If you comment out the Load_Extra_Conf command watch the response the server sends.
So to do this we would need to add an errorhandler to the urlopen command and catch http errors.
If it's an error 500 and has the type UnkownExtraConf we promt the user and ask if file should be loaded.
For every other error we just procced as usual and notify via statusbar.

Hope this helps. If not feel free to ask again :)

@hassec
Copy link
Contributor Author

hassec commented Jul 15, 2015

Did you have a chance to look into this yet?
If so what are your thoughts on how you would go about implementing this?

@LuckyGeck
Copy link
Owner

Sorry, I had no time to look through this yet. I suppose, that I'll have some free time at the end of this week.

@hassec
Copy link
Contributor Author

hassec commented Jul 15, 2015

Alright no Problem, I haven't had a lot of time either but I'm hoping that I might have time to try out a few things this weekend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants