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

enable --force-upload to upload npm packages #266

Merged

Conversation

07souravkunda
Copy link
Collaborator

@07souravkunda 07souravkunda commented Mar 4, 2022

Description

  • --force-upload will now forcefully upload npm packages as well
  • fix: upload error was being masked by status bar
  • Showing stacktrace of request errors if any

logs 1
logs 2
logs 3

nagpalkaran95
nagpalkaran95 previously approved these changes Mar 4, 2022
@@ -24,6 +25,7 @@ const createBuild = (bsConfig, zip) => {

request.post(options, function (err, resp, body) {
if (err) {
logger.info(utils.formatRequest(err, resp, body));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

logger.error in case of errors

bin/helpers/utils.js Show resolved Hide resolved
@nagpalkaran95 nagpalkaran95 changed the title Force upload, masking error fix enable --force-upload to upload npm packages Mar 8, 2022
@@ -105,14 +105,15 @@ let reportGenerator = (bsConfig, buildId, args, rawArgs, cb) => {
let messageType = null;
let errorCode = null;
let build;


if (err) {
message = err;
messageType = Constants.messageTypes.ERROR;
errorCode = 'api_failed_build_report';

logger.error('Generating the build report failed.');
logger.error(message);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this

@@ -135,6 +136,7 @@ let reportGenerator = (bsConfig, buildId, args, rawArgs, cb) => {
message = Constants.userMessages.API_DEPRECATED;
logger.info(message);
}
logger.error(utils.formatRequest(err, resp, body));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this

@@ -146,6 +148,7 @@ let reportGenerator = (bsConfig, buildId, args, rawArgs, cb) => {
response = {message: message};
}
logger.error(response.message);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this..this is redundant after statement we added

@@ -160,6 +163,7 @@ let reportGenerator = (bsConfig, buildId, args, rawArgs, cb) => {
message = Constants.userMessages.BUILD_GENERATE_REPORT_FAILED.replace('<build-id>', buildId);
logger.error(message);
}
logger.error(utils.formatRequest(err, resp, body));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move this to line 164 and remove what's there on 164

@nagpalkaran95 nagpalkaran95 merged commit 98f6cdb into browserstack:master Mar 9, 2022
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

Successfully merging this pull request may close these issues.

None yet

2 participants