padawan-php / deoplete-padawan Goto Github PK
View Code? Open in Web Editor NEWPadawan.php source for deoplete.
License: MIT License
Padawan.php source for deoplete.
License: MIT License
Hello,
When i save a files php, my status bar (neovim) say :
"Padawan.php error: Expecting value: line1 column 1 (char 0)"
Why ? please help me, thanks you.
Error detected while processing function deoplete#sources#padawan#Generate:
line 16:
E117: Unknown function: jobstart
E488: Trailing characters
I think I've broken it in #9
I have this errors in neovim all the time.
I don't now if it's related to deoplete or padawant it self, but always happen when autocomplete it's triggered.
[deoplete] timeout=3
Padawan.php server started automatically
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 223, in urlopen
Padawan.php server started automatically
[deoplete] return opener.open(url, data, timeout)
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 526, in open
[deoplete] response = self._open(req, data)
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 544, in _open
[deoplete] '_open', req)
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 504, in _call_chain
[deoplete] result = func(*args)
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 1346, in http_open
[deoplete] return self.do_open(http.client.HTTPConnection, req)
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/urllib/request.py", line 1321, in do_open
[deoplete] r = h.getresponse()
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 1331, in getresponse
[deoplete] response.begin()
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 297, in begin
[deoplete] version, status, reason = self._read_status()
[deoplete] File "/usr/local/Cellar/python3/3.6.3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/http/client.py", line 266, in _read_status
[deoplete] raise RemoteDisconnected("Remote end closed connection without"
[deoplete] http.client.RemoteDisconnected: Remote end closed connection without response
[deoplete] Could not get completions from: padawan. Use :messages for error details.
[deoplete] Traceback (most recent call last):
"src/Dot.php" 178L, 3907C written
[deoplete] File "/Users/yriveiro/.config/nvim/plugged/deoplete.nvim/rplugin/python3/deoplete/deoplete.py", line 135, in gather_results
[deoplete] ctx['candidates'] = source.gather_candidates(ctx)
[deoplete] File "/Users/yriveiro/.config/nvim/plugged/deoplete-padawan/rplugin/python3/deoplete/sources/deoplete_padawan.py", line 107, in gather_candidates
[deoplete] result = self.do_request('complete', params, contents)
[deoplete] File "/Users/yriveiro/.config/nvim/plugged/deoplete-padawan/rplugin/python3/deoplete/sources/deoplete_padawan.py", line 159, in do_request
I'm using Neovim 0.2.1 on OSX (El Capitan) 10.11.6
Continuation of the following:
padawan-php/padawan.php#67 (comment)
@mkusher, your right, prefix is not sent by the deoplete-padawan. The column is always set at the beginning of the word. [...]
@cprn, which version of padawan you are using? [...]
[...] It will work as expected with padawan from the master branch when I fix the issue @mkusher has addressed.
Version of deoplete-padawan
:
d74aad4 Update README.md
This program seems not to generate index when files are updated.
Is it possible to re-generate index on 'BufWritePost'?
thank you.
I have trouble debugging this.
if has('nvim')
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
Plug 'pbogut/deoplete-padawan'
endif
:CheckHealth
shows no problems with python or ruby.padawan generate
finished without errorsnvim
, running deoplete#sources#padawan#StartServer()
seems to create a file in /tmp/padawan-server.log, and it shows up as a running process.deoplete#sources#padawan#RestartServer()
adds the following to the log file:POST /kill
Goodbye
Response time: 0.0035698413848877
tail: /tmp/padawan-server.log: file truncated
ERR_EMPTY_RESPONSE
, and drops a GET /
in the log.Whenever I type $object->
or Class::
or something like that, it just shows "Connection to padawan.php timed out", which is an error generated by this plugin.
Any idea on how to debug this further? Thanks!
Given:
namespace This\Is\Name\Space;
When:
use This\Is\Sp|
Should recommend full namespace, instead you have to type:
use This\Is\NamSp|
That's because input position is set right after backslash instead of beginning of the name space.
I installed plugins, according to instruction, install padawan-php, index and start server, but in editor nothing happened. May be i should use some hotkeys?
My config:
set number
set linebreak
set showbreak=+++
set textwidth=100
set showmatch
set visualbell
set noswapfile
set hlsearch
set smartcase
set ignorecase
set incsearch
set autoindent
set expandtab
set shiftwidth=4
set smartindent
set smarttab
set softtabstop=4
set ruler
set undolevels=1000
set backspace=indent,eol,start
let mapleader = ","
if (has("termguicolors"))
set termguicolors
endif
call plug#begin()
Plug 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' }
Plug 'scrooloose/syntastic'
Plug 'jacoborus/tender'
Plug 'jlanzarotta/bufexplorer'
Plug 'stephpy/vim-php-cs-fixer'
Plug 'vim-airline/vim-airline'
Plug 'Shougo/deoplete.nvim'
Plug 'padawan-php/deoplete-padawan'
call plug#end()
"Syntax and colorscheme
syntax enable
colorscheme tender
"php-cs-fixer
let g:php_cs_fixer_level = "psr2" " which level ?
let g:php_cs_fixer_config = "default" " configuration
"let g:php_cs_fixer_config_file = '.php_cs' " configuration file
let g:php_cs_fixer_php_path = "php" " Path to PHP
" If you want to define specific fixers:
"let g:php_cs_fixer_fixers_list = "linefeed,short_tag,indentation"
let g:php_cs_fixer_enable_default_mapping = 1 " Enable the mapping by default (<leader>pcd)
let g:php_cs_fixer_dry_run = 0 " Call command with dry-run option
let g:php_cs_fixer_verbose = 0 " Return the output of command if 1, else an inline information.
"syntastic
set statusline+=%#warningmsg#
set statusline+=%{SyntasticStatuslineFlag()}
set statusline+=%*
let g:syntastic_php_checkers=['phpcs', 'php']
let g:syntastic_php_phpcs_exec='~/.composer/vendor/bin/phpcs'
let g:syntastic_php_phpcs_args='--standard=PSR2 -n'
let g:syntastic_always_populate_loc_list = 1
let g:syntastic_auto_loc_list = 1
let g:syntastic_check_on_open = 1
" let g:syntastic_aggregate_errors = 1
let g:syntastic_check_on_wq = 0
Hello.
I noticed sometimes padawan.php server response is too slow.
But, when I use sublime version plugin, padawan responses fast.
So, I compared these plugin's request by using tcpdump.
And I remove quote_plus call, then padawan server became responses fast.
But I struggling to research why padawan's response to be slow when I use quote_plus.
Do you have some idea?
I'm getting the following error when trying to autocomplete:
Connection to padawan.php timed out
From the log I'm seeing this when I run start/stop/start padawan server, so it seems like it is running correctly:
$ tail -f /tmp/padawan-server.log
Started http server on 127.0.0.1:15155
POST /kill
Started http server on 127.0.0.1:15155
but i don't see anything else being logged.
anything i can do to debug more? i'm new to php/padawan.
Example:
$foo = new Foo;
// does autocomplete
$qux = $foo->bar()->baz();
// doesnt autocomplete
$qux = $foo
->bar()
->baz();
I'm not sure whether the issue in in deoplete-padawan
, but I would like it to work. Any ideas?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.