Coder Social home page Coder Social logo

"The first argument must be one of type string or Buffer. Received type object", after clean wrangler generate of Scala worker about miniflare HOT 5 CLOSED

cloudflare avatar cloudflare commented on August 29, 2024
"The first argument must be one of type string or Buffer. Received type object", after clean wrangler generate of Scala worker

from miniflare.

Comments (5)

asimpletune avatar asimpletune commented on August 29, 2024 1

That did the trick. I guess the older APIs provided by the older version of node had different type expectations. Thanks!

from miniflare.

mrbbot avatar mrbbot commented on August 29, 2024

Hey! 👋 Are you able to share the full stack trace you're getting from the console?

from miniflare.

asimpletune avatar asimpletune commented on August 29, 2024

Sure, here's what's being logged:

miniflare index.js
[mf:inf] Worker reloaded! (295B)
[mf:inf] Listening on :8787
[mf:inf] - http://127.0.0.1:8787
[mf:inf] - http://192.168.0.8:8787
[mf:err] GET /: TypeError [ERR_INVALID_ARG_TYPE]: The first argument must be one of type string or Buffer. Received type object
    at write_ (_http_outgoing.js:618:11)
    at ServerResponse.write (_http_outgoing.js:586:15)
    at Miniflare._Miniflare_httpRequestListener (/Users/spence/.nvm/versions/node/v12.14.0/lib/node_modules/miniflare/src/index.ts:426:18)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
GET / 200 OK (95.16ms)

from miniflare.

mrbbot avatar mrbbot commented on August 29, 2024

Ah ok. I just generated a new project from the template I'm guessing you're using and it's working for me. I think this might be the same issue as #35 though, since you're using Node 12.14. Would you be able to try with Node >= 12.19?

from miniflare.

asimpletune avatar asimpletune commented on August 29, 2024

Sure, I'll give that a shot. Thanks for the fast response.

from miniflare.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.