diff options
| author | Evgeni Chasnovski <evgeni.chasnovski@gmail.com> | 2026-03-04 02:16:24 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-03 19:16:24 -0500 |
| commit | f00abc6a56693b030bed2e9771141067712e2b2a (patch) | |
| tree | be231bf0138170fcb0706fd934288aa65148f5d4 /runtime/syntax/python.vim | |
| parent | 6ddcc84a6cd725b386da5f6dea7f6512c1f501d3 (diff) | |
| download | rneovim-f00abc6a56693b030bed2e9771141067712e2b2a.tar.gz rneovim-f00abc6a56693b030bed2e9771141067712e2b2a.tar.bz2 rneovim-f00abc6a56693b030bed2e9771141067712e2b2a.zip | |
fix(pack): ensure `data` spec is passed in events during lockfile sync #38139
Problem: During initial "bootstrap" via lockfile synchronization, the
whole plugin specification is reconstructed from the lockfile data,
ignoring potential user changes added in the first `vim.pack.add()`.
This is enough in most situations since it is the only data needed
for actual installation.
However, this affects specification passed to `PackChanged[Pre]`
events. In particular, `data` field is missing which can be a problem
if there is a `PackChanged kind=install` hook that uses that field
(like with some kind of `build` method used during install).
And there might be different `version` set in `vim.pack.add()`.
Solution: Pass the `specs` input of the first `vim.pack.add()` down to
lockfile synchronization and use it to reconstruct plugin
specification for the to-be-installed plugin. If present among the
user's `specs`, it is used but with forced `src` from the lockfile (as
it is the one used during installation).
Note that this still has a caveat when using separate
`vim.pack.add()`, as only the specs from the first input (when the
lockfile synchronization happens) is taken into account.
Diffstat (limited to 'runtime/syntax/python.vim')
0 files changed, 0 insertions, 0 deletions