Commit Graph

53 Commits

Author SHA1 Message Date
micbou
eaa53f25c0
Relax regexp in DebugInfo test 2019-01-30 14:12:24 +01:00
micbou
b0f18804f3
Update sign place regex pattern for newer versions 2018-12-25 14:35:51 +01:00
micbou
3151820ff5
Update diagnostic matches only in current window 2018-11-27 15:44:55 +01:00
micbou
88bdfc01f9
Fix Flake8 errors
Fix invalid escape sequences in string literals. Ignore E301 and W504.
2018-10-26 23:07:38 +02:00
micbou
115f360092
Update matches for all windows 2018-06-03 18:58:09 +02:00
zzbot
2dcb3e91ad
Auto merge of #3045 - micbou:flake8-ycm, r=puremourning
[READY] Enforce YCM coding style

See PR https://github.com/Valloric/ycmd/pull/1047.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/youcompleteme/3045)
<!-- Reviewable:end -->
2018-06-02 07:46:13 -07:00
zzbot
470518075d
Auto merge of #3035 - micbou:show-detailed-diagnostic-none, r=puremourning
[READY] Fix YcmShowDetailedDiagnostic command on line without diagnostic

The `YcmShowDetailedDiagnostic` command raises a `NoneType` exception on a line with no diagnostic;
```
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "YouCompleteMe/autoload\..\python\ycm\youcompleteme.py", line 663, in ShowDetailedDiagnostic
    if 'message' in detailed_diagnostic:
TypeError: argument of type 'NoneType' is not iterable
```

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/youcompleteme/3035)
<!-- Reviewable:end -->
2018-06-02 07:21:43 -07:00
micbou
6b4d705238
Add flake8-ycm to test requirements
Fix errors reported by flake8-ycm.
2018-05-30 02:53:28 +02:00
micbou
a7ec7a6cd9
Fix YcmShowDetailedDiagnostic command on line without a diagnostic
The YcmShowDetailedDiagnostic command raises a NoneType exception on a line
with no diagnostic.
2018-05-24 11:52:57 +02:00
micbou
638ee2e5f8
Fix debug info test on Python 2 with Clang support 2018-05-18 18:20:41 +02:00
micbou
d16d3cebc4
Allow users to change the options by restarting the server 2018-05-15 23:45:54 +02:00
micbou
1df76bbb39
Fix debug info test when ycmd is compiled with C-family support 2018-04-25 05:08:23 +02:00
micbou
f44723689c
Fix resending request when buffer is not yet parsed 2018-04-23 11:03:13 +02:00
micbou
6ec1b0b4a1
Refactor server exception handling 2018-04-13 01:35:17 +02:00
micbou
866693ef80
Refactor CompleteDone logic
Move CompleteDone logic to the CompletionRequest class.
2018-03-28 22:00:43 +02:00
micbou
c84e70737c
Improve diagnostic matches display 2018-02-18 21:32:00 +01:00
micbou
5e98da5b09
Improve diagnostic sign placement 2018-02-18 10:46:19 +01:00
micbou
8ab3f73b4d
Fix typo in tests name 2018-02-12 02:03:05 +01:00
Ben Jackson
292de25c72 Add support for Java diagnostics and asynchronous messages
This implements an asynchronous message system using a long-poll request
to the server.

The server provides an endpoint /receive_messages which blocks until
either a timeout occurs or we receive a batch of asynchronous messages.
We send this request asynchronously and poll it 4 times a second to see
if we have received any messages.

The messages may either be simply for display (such as startup progress)
or diagnostics, which override the diagnostics returned by
OnFileReqdyToParse.

In the former case, we simply display the message, accepting that this
might be overwritten by any other message (indeed, requiring this), and
for the latter we fan out diagnostics to any open buffer for the file in
question.

Unfortunately, Vim has bugs related to timers when there is something
displayed (such as a "confirm" prompt or other), so we suspend
background timers when doing subcommands to avoid vim bugs. NOTE: This
requires a new version of Vim (detected by the presence of the
particular functions used).
2018-02-10 16:29:27 +00:00
Boris Staletic
605ef42cd6 Drop Python 2.6 and Python 3.3 2018-01-30 18:34:50 +01:00
micbou
497a803188
Prompt the user to select a logfile with YcmToggleLogs
When no argument is given to the YcmToggleLogs command, instead of displaying
the list of available logfiles, prompt the user to open (or close if already
open) one of them.
2017-12-22 19:58:29 +01:00
micbou
2b8e86797c
Improve server crash notification at startup
Notify the user if the server crashed during server polling at startup.
2017-10-05 13:12:23 +02:00
micbou
880f8700b3
Echo diagnostic asynchronously 2017-10-04 16:59:47 +02:00
micbou
5d78e4c2c0
Improve path to python interpreter error handling 2017-09-21 21:17:32 +02:00
micbou
031edea89e
Improve error message when server crashes
Give the exact command that the user needs to type to open the server logfile
when the server unexpectedly crashes.
2017-08-18 18:15:20 +02:00
micbou
bdac8ed43e
Do not read server stderr
Reading ycmd stderr blocks Vim if a subserver process is still up even if ycmd
is not running.
2017-08-17 20:16:54 +02:00
micbou
f31102e317
Check if server is ready before running tests 2017-07-03 18:06:01 +02:00
Davit Samvelyan
a70755aa40 Removed current buffer caching approach. 2017-06-12 15:23:14 +04:00
Davit Samvelyan
e5b0565d1a Fixed bug: current buffer was not set correctly.
Other minor fixes.
2017-06-10 09:53:18 +04:00
Davit Samvelyan
22be4e777d Refactored diag interface, removed dummy sign. 2017-06-05 22:20:57 +04:00
Davit Samvelyan
8c6efb4214 Cache current buffer on buffer visit. 2017-06-04 12:09:49 +04:00
Davit Samvelyan
3a690fc8d4 Update based on the latest upstream changes. 2017-05-21 18:58:29 +04:00
Davit Samvelyan
0846673aa4 Latest upstream changes with buffer emulation.
Contains diagnostic interface improvents as well.
2017-05-21 18:26:50 +04:00
Davit Samvelyan
979f14acfd Moved change tracking to python. Per buffer diags 2017-05-21 11:47:27 +04:00
micbou
47f3f9d2c6
Fix diagnostic highlighting with invalid location extent
Ignore location extent when starting column is zero. Do not highlight warnings
as errors when location extent is invalid.
2017-04-06 17:53:23 +02:00
Andrey Pikas
ebc3856121 Merge branch 'master' into fork_master 2017-03-30 20:26:11 +03:00
micbou
e45a409ac9
Prioritize errors over warnings on the same line 2017-03-29 12:34:48 +02:00
micbou
f3ccafe3ae
Do not install aliases from future
Installing aliases from python-future is unreliable and slow.
2017-03-18 18:24:48 +01:00
Andrey Pikas
2495dffa59 Fix tests under Windows. 2017-03-12 23:06:05 +03:00
Andrey Pikas
822010fe4c Move import to the top of file. 2017-03-12 20:18:24 +03:00
Andrey Pikas
592b85516b Tests for checking that extra_conf_data sended to server from :DebugInfo and :YcmCompleter commands. 2017-03-12 19:03:07 +03:00
micbou
414782bc74
Add tests for diagnostic commands 2017-02-20 18:28:49 +01:00
micbou
8426191655
Update test 2017-01-24 22:43:41 +01:00
micbou
ab758e4c64
Include subservers logfiles in YcmToggleLogs 2017-01-21 13:42:58 +01:00
micbou
18aba7a582
Implement new debugging information API 2017-01-18 11:13:11 +01:00
micbou
01aa54ee2d
Add tests 2016-12-12 02:36:15 +01:00
micbou
b93c1fd47c
Add client logfile 2016-11-19 18:47:43 +01:00
micbou
fa10f33c2a
Move test_utils to tests folder
This remove the file from coverage.
2016-10-15 04:03:48 +02:00
micbou
8d015c95cc
Refactor tests using a YouCompleteMe instance 2016-10-14 02:18:51 +02:00
micbou
7b2155ab64 Refactor tests using a server instance
Create a Server_test class for tests that need a server instance.
2016-07-23 11:21:38 +02:00