get_hunks error with vim-airline plugin

Problem

After installing the latest version of vim-airline plugin for Vim, opening any file generates the following error:

Error detected while processing function airline#extensions#hunks#get_hunks..<SNR>57_get_hunks..<SNR>57_get_hunks_signify:
line    1:
E117: Unknown function: sy#repo#get_stats
Press ENTER or type command to continue
Error detected while processing function airline#extensions#hunks#get_hunks..<SNR>57_get_hunks..<SNR>57_get_hunks_signify:
line    1:
E15: Invalid expression: sy#repo#get_stats()
Press ENTER or type command to continue
Error detected while processing function airline#extensions#hunks#get_hunks..<SNR>57_get_hunks..<SNR>57_get_hunks_signify:
line    2:
E121: Undefined variable: hunks

Solution

This error is typically caused because one of your other Vim plugins is outdated. Most probably, the vim-signify or vim-gitgutter plugins. Try updating them and see if this error goes away.

If the error still persists, then the hunks feature can be safely disabled by adding this to your .vimrc:

let g:airline_enable_hunks = 0

Tried with: Vim 7.3 and Ubuntu 12.04 LTS

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s