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

TypeError: glob is not a function #68

Open
lemoncrafter opened this issue Apr 12, 2023 · 5 comments
Open

TypeError: glob is not a function #68

lemoncrafter opened this issue Apr 12, 2023 · 5 comments

Comments

@lemoncrafter
Copy link

When I run the example like this: hbs --helper ./src/template_helper/**/*.js --data src/data.json src/templates/**/*.hbs --output dist/
I get this error:

TypeError: glob is not a function
    at /home/user/hsb-example/node_modules/glob-promise/lib/index.js:7:5
    at new Promise (<anonymous>)
    at Object.module.exports [as default] (/home/user/hsb-example/node_modules/glob-promise/lib/index.js:6:10)
    at resolveModuleOrGlob$ (/home/user/hsb-example/node_modules/hbs-cli/lib/index.js:64:38)
    at tryCatch (/home/user/hsb-example/node_modules/babel-runtime/regenerator/runtime.js:72:40)
    at Generator.invoke [as _invoke] (/home/user/hsb-example/node_modules/babel-runtime/regenerator/runtime.js:334:22)
    at Generator.prototype.<computed> [as throw] (/home/user/hsb-example/node_modules/babel-runtime/regenerator/runtime.js:105:21)
    at tryCatch (/home/user/hsb-example/node_modules/babel-runtime/regenerator/runtime.js:72:40)
    at invoke (/home/user/hsb-example/node_modules/babel-runtime/regenerator/runtime.js:146:20)
    at /home/user/hsb-example/node_modules/babel-runtime/regenerator/runtime.js:156:13

Do you know what am I doing wrong?
I tried the example sometime ago and it worked but suddenly I started getting that error.
I any clue would be appreciated, thanks!

@keithamus
Copy link
Owner

I’m not sure what’s going wrong there, it looks like a dependency is breaking though. This package could definitely be updated to remove the Babel transpiled code which might help uncover the error a bit more clearly.

@sjdrc
Copy link

sjdrc commented Apr 24, 2023

I'm also hitting the exact same error

@keithamus
Copy link
Owner

I haven't been maintaining this package particularly. I was mostly using it close to a decade ago. I think it's suffering from some bit rot. If anyone would like to take over maintainership, please feel free to send over some PRs and I'll happily merge and pass the maintainer bit over.

@dimbleby
Copy link

dimbleby commented Jul 3, 2023

this can be repaired with

-        "glob-promise": "^1.0.4",
+        "glob-promise": "^6.0.3",

@yasammez
Copy link

Any updates on this?

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

5 participants