Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gulp Build Issue with Inject #507

Open
Wasperex opened this issue Aug 13, 2019 · 4 comments
Open

Gulp Build Issue with Inject #507

Wasperex opened this issue Aug 13, 2019 · 4 comments

Comments

@Wasperex
Copy link

I recently installed blur-admin but I am having difficulties initiating the app via the gulp serve command. The problem seems to relate to the inject task that runs after the 'html' task in build.js. Below is the error that I keep getting:

$ gulp serve
assert.js:42
throw new errors.AssertionError({
^

AssertionError [ERR_ASSERTION]: Task function must be specified
at Gulp.set [as _setTask] (D:\Git Repo\blur-admin\node_modules\undertaker\lib\set-task.js:10:3)
at Gulp.task (D:\Git Repo\blur-admin\node_modules\undertaker\lib\task.js:13:8)
at Object. (D:\Git Repo\blur-admin\gulp\build.js:29:6)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)

I have tried updating the code with the latest syntax but this results in a different issue related to the 'inject' task definition. Here is the rewritten segment of the code:

gulp.task('html', gulp.series(['inject', 'partials']), function a ()

Here is the corresponding error message:
$ gulp serve
assert.js:42
throw new errors.AssertionError({
^

AssertionError [ERR_ASSERTION]: Task never defined: inject
at getFunction (D:\Git Repo\blur-admin\node_modules\undertaker\lib\helpers\normalizeArgs.js:15:5)
at map (D:\Git Repo\blur-admin\node_modules\arr-map\index.js:20:14)
at normalizeArgs (D:\Git Repo\blur-admin\node_modules\undertaker\lib\helpers\normalizeArgs.js:22:10)
at Gulp.series (D:\Git Repo\blur-admin\node_modules\undertaker\lib\series.js:13:14)
at Object. (D:\Git Repo\blur-admin\gulp\build.js:29:24)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)

I am wondering whether this is an issue with any of my package versions or with the task definitions.

@boethius
Copy link

boethius commented Sep 2, 2019

I have run into the same issue, also updated the syntax for the gulp task doesn't work.

@boethius
Copy link

boethius commented Sep 3, 2019

this gulp.task('html', gulp.series(['inject', 'partials']), function a () needs to be
gulp.task('html', gulp.series('inject', 'partials', function (){ ... }));

@kuccilim
Copy link

@boethius, would you mind to share gulp/* folder to me?
Few days ago updated Blur Admin to gulp 4 and node 10, til now has not successful build/serve this project.

@pradeepupadhyay
Copy link

@boethius, would you mind to share gulp/* folder to me?
Few days ago updated Blur Admin to gulp 4 and node 10, til now has not successful build/serve this project.

Any Success @kuccilim ? I have just updated my gulp and stuck on same issue :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants