Shougo / dein.vim

:zap: Dark powered Vim/Neovim plugin manager
MIT License
3.43k stars 196 forks source link

Report: hook_add / hook_source process duplicated at only once next start after plugin install completed. #425

Closed tsuyoshicho closed 3 years ago

tsuyoshicho commented 3 years ago

Warning: I will close the bug issue without the minimal init.vim and the reproduce ways.

The problem is low level, but I will report it.

Problems summary

Vim start with dein, hook_add / hook_source processed two count. Problem happen only once next start after plugin install completed.

Problem detail write to reproduce step section.

Expected

dein's hook run only once hook_add / hook_source (without user `call dein#call_hook('xxx') )

Environment Information (Required!)

VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Sep  2 2021 08:19:11)
MS-Windows 64 ビット GUI/コンソール 版 with OLE サポート
適用済パッチ: 1-3394

build in vim-tux project

Provide a minimal .vimrc with less than 50 lines (Required!)

https://github.com/tsuyoshicho/testvimrc.vim/tree/test/deinadddup

Minimal vimrc and reproduce log in this branch.

The reproduce ways from Vim starting (Required!)

  1. start vim with minimal reproduce branch testvimrc.vim 1st time boot, install plugins
  2. start vim with minimal reproduce branch testvimrc.vim 2nd time boot, problem reproduce
  3. type :echo g:test_mb_addcnt and :echo g:test_mb_srccnt
  4. contrast check :echo g:test_mb_postsrccnt
  5. start vim with minimal reproduce branch testvimrc.vim 3rd or more time boot, problem no reproduce

these g:test_mb_* variables define and work in test.toml

count up per process hook_* expect work: all set 1

Screen shot (if possible)

nothing.

Upload the log messages by :redir and :message (if errored)

https://github.com/tsuyoshicho/testvimrc.vim/blob/test/deinadddup/log/result.txt

PP g:test_mb_addcnt:
g:test_mb_addcnt = 2

PP g:test_mb_srccnt:
g:test_mb_srccnt = 2

PP g:test_mb_postsrccnt:
g:test_mb_postsrccnt = 1
tsuyoshicho commented 3 years ago

Thanks a lot!