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

.travis.yml: Fix cmd errors #592

Merged
merged 5 commits into from
May 11, 2018
Merged

.travis.yml: Fix cmd errors #592

merged 5 commits into from
May 11, 2018

Conversation

gaocegege
Copy link
Member

@gaocegege gaocegege commented May 11, 2018

Close #586

Signed-off-by: Ce Gao gaoce@caicloud.io


This change is Reviewable

Signed-off-by: Ce Gao <gaoce@caicloud.io>
@TravisBuddy
Copy link

Travis tests have failed

Hey @gaocegege,
Please read the following log in order to understand the failure reason.
It'll be awesome if you fix what's wrong and commit the changes.

3rd Build

gometalinter --config=linter_config.json --vendor ./...
dashboard/backend/handler/api_handler.go:224:32:warning: error return value not checked (response.WriteHeaderAndEntity(http.StatusOK, string(logs))) (errcheck)
dashboard/backend/handler/api_handler.go:232:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/main.go:29:21:warning: error return value not checked (http.ListenAndServe(p, nil)) (errcheck)
test/e2e/main.go:233:21:warning: should use time.Until instead of t.Sub(time.Now()) (S1024) (gosimple)
dashboard/backend/handler/api_handler.go:130:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:133:32:warning: error return value not checked (response.WriteHeaderAndEntity(http.StatusOK, jobs)) (errcheck)
dashboard/backend/handler/api_handler.go:208:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:221:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:144:23:warning: error return value not checked (response.WriteError(http.StatusNotFound, err)) (errcheck)
dashboard/backend/handler/api_handler.go:188:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:197:32:warning: error return value not checked (response.WriteHeaderAndEntity(http.StatusCreated, j)) (errcheck)
dashboard/backend/handler/api_handler.go:235:32:warning: error return value not checked (response.WriteHeaderAndEntity(http.StatusOK, l)) (errcheck)
dashboard/backend/handler/api_handler.go:146:23:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:161:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:173:22:warning: error return value not checked (response.WriteError(http.StatusBadRequest, err)) (errcheck)
dashboard/backend/handler/api_handler.go:194:22:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, err)) (errcheck)
dashboard/backend/handler/api_handler.go:165:32:warning: error return value not checked (response.WriteHeaderAndEntity(http.StatusOK, tfJobDetail)) (errcheck)
dashboard/backend/handler/api_handler.go:184:23:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, nsErr)) (errcheck)

travis_time:end:20fe9770:start=1526019558699007167,finish=1526019630313553126,duration=71614545959

@coveralls
Copy link

coveralls commented May 11, 2018

Coverage Status

Coverage decreased (-0.06%) to 49.292% when pulling fe91641 on gaocegege:fix into f0c21f8 on kubeflow:master.

Signed-off-by: Ce Gao <gaoce@caicloud.io>
Signed-off-by: Ce Gao <gaoce@caicloud.io>
@TravisBuddy
Copy link

Travis tests have failed

Hey @gaocegege,
Please read the following log in order to understand the failure reason.
It'll be awesome if you fix what's wrong and commit the changes.

3rd Build

gometalinter --config=linter_config.json -s test --vendor ./...
dashboard/backend/handler/api_handler.go:211:32:warning: error return value not checked (response.WriteHeaderAndEntity(http.StatusCreated, j)) (errcheck)
dashboard/backend/main.go:29:21:warning: error return value not checked (http.ListenAndServe(p, nil)) (errcheck)
test/e2e/main.go:233:21:warning: should use time.Until instead of t.Sub(time.Now()) (S1024) (gosimple)
dashboard/backend/handler/api_handler.go:148:23:warning: error return value not checked (response.WriteError(http.StatusNotFound, err)) (errcheck)
dashboard/backend/handler/api_handler.go:183:22:warning: error return value not checked (response.WriteError(http.StatusBadRequest, err)) (errcheck)
dashboard/backend/handler/api_handler.go:194:23:warning: error return value not checked (response.WriteError(http.StatusInternalServerError, nsErr)) (errcheck)

travis_time:end:1556cc0a:start=1526020926703919763,finish=1526021009393747852,duration=82689828089

@TravisBuddy
Copy link

Travis tests have failed

Hey @gaocegege,
Please read the following log in order to understand the failure reason.
It'll be awesome if you fix what's wrong and commit the changes.

2nd Build

gometalinter --config=linter_config.json -s test --vendor ./...
dashboard/backend/main.go:30::error: possible formatting directive in Fatal call (vet)
test/e2e/main.go:233:21:warning: should use time.Until instead of t.Sub(time.Now()) (S1024) (gosimple)

3rd Build

gometalinter --config=linter_config.json -s test --vendor ./...
test/e2e/main.go:233:21:warning: should use time.Until instead of t.Sub(time.Now()) (S1024) (gosimple)
dashboard/backend/main.go:30::error: Fatal call has possible formatting directive %v (vet)

travis_time:end:27c09cd5:start=1526021483529975744,finish=1526021559182983047,duration=75653007303

Signed-off-by: Ce Gao <gaoce@caicloud.io>
@gaocegege gaocegege changed the title WIP: .travis.yml: Fix cmd errors .travis.yml: Fix cmd errors May 11, 2018
@gaocegege
Copy link
Member Author

/assign @ScorpioCPH

Copy link
Member

@ScorpioCPH ScorpioCPH left a comment

Choose a reason for hiding this comment

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

LGTM with some nits.

}
}

func (apiHandler *APIHandler) handleDeploy(request *restful.Request, response *restful.Response) {
clt := apiHandler.cManager.TFJobClient
tfJob := new(v1alpha1.TFJob)
if err := request.ReadEntity(tfJob); err != nil {
response.WriteError(http.StatusBadRequest, err)
if newErr := response.WriteError(http.StatusBadRequest, err); newErr != nil {
Copy link
Member

Choose a reason for hiding this comment

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

nit: how about use err2, If there is a third error, we can use err3 :)

Copy link
Member Author

Choose a reason for hiding this comment

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

SGTM

Signed-off-by: Ce Gao <gaoce@caicloud.io>
@gaocegege
Copy link
Member Author

Updated PTAL @ScorpioCPH

@ScorpioCPH
Copy link
Member

/lgtm
/approve

@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ScorpioCPH

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit 2918f08 into kubeflow:master May 11, 2018
yph152 pushed a commit to yph152/tf-operator that referenced this pull request Jun 18, 2018
* .travis.yml: Fix cmd errors

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* dashboard: Fix

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* backend: Fix

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* *: Fix

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* api: Fix err variable name

Signed-off-by: Ce Gao <gaoce@caicloud.io>
jetmuffin pushed a commit to jetmuffin/tf-operator that referenced this pull request Jul 9, 2018
* .travis.yml: Fix cmd errors

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* dashboard: Fix

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* backend: Fix

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* *: Fix

Signed-off-by: Ce Gao <gaoce@caicloud.io>

* api: Fix err variable name

Signed-off-by: Ce Gao <gaoce@caicloud.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants