titaniumnetwork-dev / Ultraviolet-App

Example application of Ultraviolet which can be deployed in production.
https://docs.titaniumnetwork.org/proxies/ultraviolet
MIT License
290 stars 4.46k forks source link

Heroku deployment NodeJS error #10

Closed fowntain closed 1 year ago

fowntain commented 2 years ago

Expected Behavior

The app should deploy to heroku successfully without errors

Current Behavior

Giving NodeJS error. Here's the full build app logs:

-----> Building on the Heroku-22 stack
-----> Determining which buildpack to use for this app
-----> Node.js app detected

-----> Creating runtime environment

       NPM_CONFIG_LOGLEVEL=error
       NODE_VERBOSE=false
       NODE_ENV=production
       NODE_MODULES_CACHE=true

-----> Installing binaries
       engines.node (package.json):  >=16.0.0
       engines.npm (package.json):   >=7.0.0

       Resolving node version >=16.0.0...
       Downloading and installing node 19.1.0...
       Bootstrapping npm >=7.0.0 (replacing 8.19.3)...
       npm 9.1.2 installed

-----> Installing dependencies
       Installing node modules
       npm ERR! code ENOENT
       npm ERR! syscall open
       npm ERR! path /tmp/Ultraviolet/package.json
       npm ERR! errno -2
       npm ERR! enoent ENOENT: no such file or directory, open '/tmp/Ultraviolet/package.json'
       npm ERR! enoent This is related to npm not being able to find a file.
       npm ERR! enoent 

       npm ERR! A complete log of this run can be found in:
       npm ERR!     /tmp/npmcache.KxxYa/_logs/2022-11-22T13_27_45_053Z-debug-0.log
-----> Build failed

       We're sorry this build is failing! You can troubleshoot common issues here:
       https://devcenter.heroku.com/articles/troubleshooting-node-deploys

       Some possible problems:

       - Dangerous semver range (>) in engines.node
         https://devcenter.heroku.com/articles/nodejs-support#specifying-a-node-js-version

       Love,
       Heroku

 !     Push rejected, failed to compile Node.js app.
 !     Push failed

Steps to Reproduce

  1. Fork this repo
  2. Attempt to deploy to heroku WITH proper username
  3. Watch the build app logs
e9x commented 1 year ago

The build logs show an error that would fundamentally break every deployment on Heroku. If Heroku can't keep track of package.json then this must be a bug.