• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mendersoftware / mender-artifact
76%
master: 76%

Build:
Build:
LAST BUILD BRANCH: license-header-fixes
DEFAULT BRANCH: master
Repo Added 16 Sep 2020 01:19PM UTC
Files 46
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH MEN-8428-mender-artifact-does-not-reenable-echo
branch: MEN-8428-mender-artifact-does-not-reenable-echo
CHANGE BRANCH
x
Reset
  • MEN-8428-mender-artifact-does-not-reenable-echo
  • 3.10.0-build3
  • 3.11.0
  • 3.11.0-build1
  • 3.11.0-build2
  • 3.11.0-build3
  • 3.11.0-build4
  • 3.11.1
  • 3.11.1-build3
  • 3.11.1-build4
  • 3.11.1-build5
  • 3.11.1-build6
  • 3.11.2
  • 3.11.2-build1
  • 3.11.2-build2
  • 3.11.3
  • 3.11.3-build2
  • 3.11.3-build3
  • 3.11.3-build4
  • 3.11.3-build5
  • 3.11.x-fix-ci
  • 3.4.1
  • 3.4.1-build1
  • 3.4.1-build2
  • 3.4.2
  • 3.4.2-build3
  • 3.4.2-build5
  • 3.5.0
  • 3.5.0-build1
  • 3.5.0-build2
  • 3.5.1
  • 3.5.1-build1
  • 3.5.1-build10
  • 3.5.1-build11
  • 3.5.1-build2
  • 3.5.1-build4
  • 3.5.1-build6
  • 3.5.1-build7
  • 3.5.1-build8
  • 3.5.1-build9
  • 3.5.2
  • 3.5.2-build1
  • 3.5.2-build2
  • 3.5.2-build3
  • 3.5.3
  • 3.5.3-build1
  • 3.5.3-build2
  • 3.6.0
  • 3.6.0-build1
  • 3.6.0-build2
  • 3.6.0-build3
  • 3.6.0-build4
  • 3.6.0-build5
  • 3.6.1
  • 3.6.1-build1
  • 3.6.1-build2
  • 3.6.1-build3
  • 3.6.1-build4
  • 3.6.1-build5
  • 3.6.1-build6
  • 3.6.1-build7
  • 3.6.1-build8
  • 3.6.1-build9
  • 3.7.0
  • 3.7.0-build2
  • 3.7.0-build4
  • 3.7.0-build8
  • 4.0.0
  • 4.0.0-build1
  • 4.0.0-build2
  • 4.0.0-build3
  • 4.0.0-build5
  • 4.0.0-build6
  • 4.0.0-build7
  • 4.0.0-build8
  • 4.1.0
  • 4.1.0-build1
  • 4.1.1
  • MEN-3410
  • MEN-4977
  • MEN-7225
  • MEN-7876-enable-tty-echo-always
  • MEN-8127-add-module-image-progressbar
  • MEN-8141-update-go-mod-version
  • MEN-8141-update-golang-compat-test
  • MEN-8382_mender-artifact_fails_on_calling_mender-update_show-provides
  • MEN-8382_new-mender-artifact_fails_on_calling_mender-update_show-provides
  • MEN-8429_mender-artifact-waits-indefinitely-if-ssh-connection-fails-silently
  • MEN-8491-compatible-types
  • MEN-8588-artifact-multiple-payloads
  • QA-1020-docker-retry
  • QA-1166-mender-artifact-ccc-release
  • SEC-1676-oauth-jws
  • add-docs-release-template
  • add-golang-license-template
  • artifact-validation
  • azure-keyvault
  • bump-license
  • cherry-3.11.x-MEN-7876-enable-tty-echo-always
  • cherry-3.11.x-bump-license
  • cherry-4.0.x-MEN-7876-enable-tty-echo-always
  • ci-publish-on-tags
  • ci-remove-virtual-client-trigger
  • ci-sort
  • dependabot/docker/alpine-3.21.0
  • dependabot/docker/alpine-3.21.2
  • dependabot/docker/alpine-3.21.3
  • dependabot/docker/alpine-3.22.0
  • dependabot/docker/alpine-3.22.1
  • dependabot/go_modules/github.com/go-jose/go-jose/v3-3.0.4
  • dependabot/go_modules/github.com/golang-jwt/jwt/v5-5.2.2
  • dependabot/go_modules/github.com/googleapis/gax-go/v2-2.14.1
  • dependabot/go_modules/github.com/klauspost/compress-1.18.0
  • dependabot/go_modules/github.com/lestrrat-go/jwx-1.2.31
  • dependabot/go_modules/github.com/mendersoftware/progressbar-0.0.3
  • dependabot/go_modules/github.com/stretchr/testify-1.11.0
  • dependabot/go_modules/github.com/stretchr/testify-1.11.1
  • dependabot/go_modules/github.com/ulikunitz/xz-0.5.13
  • dependabot/go_modules/github.com/ulikunitz/xz-0.5.14
  • dependabot/go_modules/github.com/ulikunitz/xz-0.5.15
  • dependabot/go_modules/github.com/urfave/cli-1.22.17
  • dependabot/go_modules/golang.org/x/crypto-0.31.0
  • dependabot/go_modules/golang.org/x/sys-0.28.0
  • dependabot/go_modules/golang.org/x/sys-0.29.0
  • dependabot/go_modules/golang.org/x/sys-0.30.0
  • dependabot/go_modules/google.golang.org/protobuf-1.36.1
  • dependabot/go_modules/google.golang.org/protobuf-1.36.2
  • dependabot/go_modules/google.golang.org/protobuf-1.36.3
  • dependabot/go_modules/google.golang.org/protobuf-1.36.6
  • dependabot/go_modules/google.golang.org/protobuf-1.36.7
  • deprecate-ioutils
  • feature-partial_updates
  • fix-signature-len-check
  • improve-error
  • install-brew
  • license-header-fixes
  • macos-fsck-error
  • makefile-unify
  • master
  • master-brew_build_component
  • master-fix_test_mac
  • master-glci_brew_install
  • master-mac_binaries
  • master-mac_unit_tests_e2fsprogs
  • mender-artifact
  • nil-check
  • qa-1017
  • release-please--branches--master
  • test-homebrew-developer
  • travis_and_coveralls
  • update-codeowners-20250820-145040

12 Aug 2025 09:45AM UTC coverage: 76.088% (-0.1%) from 76.223%
1979500311

Pull #728

gitlab-ci

michalkopczan
fix: mender-artifact does not reenable echo on ssh error

Original idea was to handle reenabling echo thanks to EchoSigHandler, but it was failing sometimes.
The issue was that EchoSigHandler, when finishing its execution, sends an error to errChan. We need
to wait on errChan until we get something on it - meaning that the EchoSigHandler finished,
and we can safely exit the application.

However, before my changes, if there was an error returned before reaching
if s.sigChan != nil { signal.Stop(s.sigChan) s.cancel() if err := <-s.errChan; err != nil { return err } }

So, for example, here:
_, err = recvSnapshot(f, command.Stdout) if err != nil { _ = command.Cmd.Process.Kill() return "", err }

Then we never waitied on errChan. Application was closed, EchoSigHandler never got the chance to
reenable echo (sometimes it did, sometimes it didn't), and we were left with echo disabled.

Adding a separate function that waits for errChan, and deferring it, we have the problem solved.

Ticket: MEN-8428
Changelog: Make mender-artifact corretly reenable echo on any error

Signed-off-by: Michal Kopczan <michal.kopczan@northern.tech>
Pull Request #728: fix: mender-artifact does not reenable echo on ssh error

0 of 50 new or added lines in 3 files covered. (0.0%)

4 existing lines in 2 files now uncovered.

5982 of 7862 relevant lines covered (76.09%)

137.89 hits per line

Relevant lines Covered
Build:
Build:
7862 RELEVANT LINES 5982 COVERED LINES
137.89 HITS PER LINE
Source Files on MEN-8428-mender-artifact-does-not-reenable-echo
  • Tree
  • List 46
  • Changed 3
  • Source Changed 0
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
1979500311 MEN-8428-mender-artifact-does-not-reenable-echo fix: mender-artifact does not reenable echo on ssh error Original idea was to handle reenabling echo thanks to EchoSigHandler, but it was failing sometimes. The issue was that EchoSigHandler, when finishing its execution, sends an error to errCha... Pull #728 12 Aug 2025 09:50AM UTC michalkopczan gitlab-ci
76.09
1977910214 MEN-8428-mender-artifact-does-not-reenable-echo fix: mender-artifact does not reenable echo on ssh error Original idea was to handle reenabling echo thanks to EchoSigHandler, but it was failing sometimes. The issue was that EchoSigHandler, when finishing its execution, sends an error to errCha... Pull #728 11 Aug 2025 01:22PM UTC michalkopczan gitlab-ci
76.11
1977727610 MEN-8428-mender-artifact-does-not-reenable-echo fix: mender-artifact does not reenable echo on ssh error Ticket: MEN-8428 Changelog: Make mender-artifact corretly reenable echo on any error Original idea was to handle reenabling echo thanks to EchoSigHandler, but it was failing sometimes. The... Pull #728 11 Aug 2025 11:45AM UTC michalkopczan gitlab-ci
76.11
1966727575 MEN-8428-mender-artifact-does-not-reenable-echo fix: mender-artifact does not reenable echo on ssh error Ticket: MEN-8428 Changelog: Make mender-artifact corretly reenable echo on any error Signed-off-by: Michal Kopczan <michal.kopczan@northern.tech> Pull #728 05 Aug 2025 07:24AM UTC michalkopczan gitlab-ci
76.11
See All Builds (1042)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc