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

File apexnitro.cred.json is overwriten when running apex-nitro launch #350

Open
JoseArostegui opened this issue Dec 15, 2020 · 5 comments
Open

Comments

@JoseArostegui
Copy link

Issue Description

File apexnitro.cred.json is emptied with default values:
{
"path": "sql",
"username": "your_username",
"password": "your_password",
"connectionString": "your_connection_string"
}
.... as soon as I run apex-nitro launch, and overwrites my data entered before.

APEX Nitro Version

v5.0.2

Operating System

Windows 10

Node Version

v14.15.1

Browser

Chrome Version 87.0.4280.66 (Official Build) (64-bit)

APEX Version

20.2

Web Server

ORDS 19.2.0.r1991647, Tomcat 8

apexnitro.config.json:
{
  "mode": "basic",
  "appName": "HeroGON",
  "appUrl": "https://xxxxxx.josearostegui.com/ords/f?p=1000",
  "srcFolder": "./src",
  "launch": {
    "port": 4000,
    "ghostMode": false,
    "notify": true,
    "open": true,
    "openBuilder": false
  },
  "upload": {
    "destination": "application",
    "credentialsPath": "./apexnitro.cred.json"
  }
}

Running apex-nitro launch, the credentials file is recreated:

C:\Users\cjleon\Desktop\HERO\src\trunk\Hero-Applications\Applications\GON\gon-apex-nitro>apex-nitro launch
APEX Nitro
C:\Users\cjleon\Desktop\HERO\src\trunk\Hero-Applications\Applications\GON\gon-apex-nitro\apexnitro.cred.json created.
(node:280) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'path' of undefined
    at Object.getConfig (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\lib\util\util.js:36:12)
    at Object.module.exports [as launch] (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\lib\commands\launch.js:19:22)
    at Command.<anonymous> (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\bin\apex-nitro.js:70:13)
    at Command.listener [as _actionHandler] (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\node_modules\commander\index.js:426:31)
    at Command._parseCommand (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\node_modules\commander\index.js:1002:14)
    at Command._dispatchSubcommand (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\node_modules\commander\index.js:953:18)
    at Command._parseCommand (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\node_modules\commander\index.js:970:12)
    at Command.parse (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\node_modules\commander\index.js:801:10)
    at Object.<anonymous> (C:\Users\cjleon\AppData\Roaming\npm\node_modules\apex-nitro\bin\apex-nitro.js:80:11)
    at Module._compile (internal/modules/cjs/loader.js:1063:30)
(Use `node --trace-warnings ...` to show where the warning was created)
(node:280) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:280) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Thanks,
Jose.

@vincentmorneau
Copy link
Collaborator

Thanks Jose and sorry for being slow to respond. I will take a look.

@JoseArostegui
Copy link
Author

This is very strange.... don't know what is the exact patter to reproduce. My dev team colleague has suffered it, but, suddenly it stops to happen without any apparent change in his side!
Thanks a lot.

@vincentmorneau
Copy link
Collaborator

And now it works?

@JoseArostegui
Copy link
Author

Yes, by now. We've been able to upload files to static applications files, but it skips the .js.

It's happening to he and me.

@vincentmorneau
Copy link
Collaborator

Right, that's the other issue. Thanks.

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

2 participants