Use-package: :after doesn't work after update

Created on 20 Mar 2017  路  5Comments  路  Source: jwiegley/use-package

After update to the latest version, the :after keyword doesn't work any more.

A test snippet would be

(package-initialize)

(require 'use-package)

(use-package company
  :ensure t
  :demand t
  :init
  (setq company-transformers '(company-sort-by-backend-importance company-sort-by-statistics))

  (use-package company-statistics
    :ensure t
    :after company
    :init 
    (print "==========")
    :config (company-statistics-mode)
    (print "^^^^^^^^^^^^^^^^^^")))
:

Got "==========" output on starting Emacs but no "^^^^^^^^^^^^^^^^^^". Also a error Symbol鈥檚 function definition is void: company-sort-by-statistics alerts since company-statistics is no load and (featurep 'company-statistics)' returnsnil`.

Any help will be appreciated!

Most helpful comment

@raxod502 has addressed this in #439.

All 5 comments

Macroexpand shows the following code:

(eval-after-load 'magit-mode
    ''(require 'evil-magit nil t))

where require is quoted twice. Might this be a reason?

@4lex1v I think you nailed it.

ELISP> (featurep 'helm)
t
ELISP> (eval-after-load 'helm ''(message "test"))
(message "test")
ELISP> (eval-after-load 'helm '(message "test"))
"test"

@raxod502 has addressed this in #439.

@Yevgnen this can be closed as it's been solved.

Thanks

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sondr3 picture sondr3  路  14Comments

alphapapa picture alphapapa  路  14Comments

DamienCassou picture DamienCassou  路  8Comments

sheepduke picture sheepduke  路  3Comments

komolovf picture komolovf  路  8Comments