Git Product home page Git Product logo

Comments (9)

heapwolf avatar heapwolf commented on June 9, 2024

can you provide any more details? (in particular, dep names)

thanks!

from jitsu.

joemccann avatar joemccann commented on June 9, 2024

express

Create an express app from CLI, make sure it works in a browser, then deploy it.

Jitsu does not "figure out" the deps in the app.js.

from jitsu.

Marak avatar Marak commented on June 9, 2024

Okay, I have confirmed this bug. I don't think it has anything to do with Express. It appears that jitsu is overwriting the deps in the package.json after it already finds them. Here is a dump of my output, I'll be creating a new ticket for this:

      prompt: scripts.start (server.js): app.js
      prompt: version (0.0.0): 
      warn:   About to write /Users/maraksquires/dev/express-test/package.json
      data:   
      data:   {
      data:       name: 'express-test',
      data:       scripts: { start: 'app.js' },
      data:       subdomain: 'express-test',
      data:       version: '0.0.0'
      data:   }
      data:   
      prompt: Is this ok? (yes): 
      warn:   No application exists for express-test
      info:   Analyzing your application dependencies in app.js
      info:   Found new dependencies. They will be added automatically
      data:   {
      data:       connect: '>= 1.4.0',
      data:       express: '>= 2.3.3',
      data:       mime: '>= 1.2.1',
      data:       qs: '>= 0.1.0'
      data:   }
      warn:   About to write /Users/maraksquires/dev/express-test/package.json
      data:   
      data:   {
      data:       dependencies: {
      data:           connect: '>= 1.4.0',
      data:           express: '>= 2.3.3',
      data:           mime: '>= 1.2.1',
      data:           qs: '>= 0.1.0'
      data:       },
      data:       name: 'express-test',
      data:       scripts: { start: 'app.js' },
      data:       subdomain: 'express-test',
      data:       version: '0.0.0'
      data:   }
      data:   
      prompt: Is this ok? (yes): 
      info:   Checking app availability express-test
      info:   Creating app express-test
      warn:   Your package.json version will be incremented for you automatically.
      warn:   About to write /Users/maraksquires/dev/express-test/package.json
      data:   
      data:   {
      data:       name: 'express-test',
      data:       scripts: { start: 'app.js' },
      data:       subdomain: 'express-test',
      data:       version: '0.0.0-1'
      data:   }
      data:   
      prompt: Is this ok? (yes): 
      warn:   Creating new snapshot for version 0.0.0-1
      info:   Done creating snapshot 0.0.0-1
      info:   Updating application express-test
      info:   Activating snapshot 0.0.0-1 for express-test
      info:   Starting app express-test
      info:   App express-test is now started at: http://express-test.nodejitsu.com on Port 80
      info:   Nodejitsu ok
      Marak-Squiress-MacBook-Pro:express-test maraksquires$ 

Notice the second time around it overwrites the deps?

from jitsu.

bmeck avatar bmeck commented on June 9, 2024

Starting to test against resolve-analyzer changes / ability against dep injection.

from jitsu.

bmeck avatar bmeck commented on June 9, 2024

talked to tj briefly, express now makes a package.json, which makes this fixed if we use newer express stuff ( expressjs/express@6e69c88 ) which should help minorly. Require-analyzer fixes did not solve this. Delving for a deeper solution.

from jitsu.

dominictarr avatar dominictarr commented on June 9, 2024

this is actually a problem with the back end. see https://github.com/nodejitsu/haibu/issues/14 and also a fix in nodejitsu/require-analyzer@30d2372 which handles how express starts the server. but the backend isn't using the most up to date haibu/carapace, so @joemccann : for now, you need to edit your app.js so that it reads

//if(!module.parent){
  app.listen(3000)
//}

this will be corrected soon.

from jitsu.

indexzero avatar indexzero commented on June 9, 2024

This is fixed in the test environment. Will be deployed to production in the next 48 hours. Checkout the awesome in this gist: https://gist.github.com/999883

from jitsu.

joemccann avatar joemccann commented on June 9, 2024

nice

from jitsu.

indexzero avatar indexzero commented on June 9, 2024

This has been deployed to production

from jitsu.

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.