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

Tests failed on AlpineLinux 32bit architecture #446

Closed
folliehiyuki opened this issue Jun 19, 2022 · 3 comments · Fixed by #472
Closed

Tests failed on AlpineLinux 32bit architecture #446

folliehiyuki opened this issue Jun 19, 2022 · 3 comments · Fixed by #472

Comments

@folliehiyuki
Copy link

Hi! I'm trying to package s5cmd for AlpineLinux. The attempt can be seen here.

Some problems I'm facing:

  • e2e tests are failing on 32bit architecture builds. Sample logs on x86
  • -race flag is specified in e2e/util_test.go line 216 which is not compatible with -buildmode=pie. Is there a way to configure it during the build process?

I'd love to get some advice. And thanks for s5cmd!

@kucukaslan
Copy link
Contributor

kucukaslan commented Jul 7, 2022

e2e tests are failing on 32bit architecture builds. Sample logs on x86

From the logs, it seems failing tests caused by the s3fakes package giving unaligned 64-bit atomic operation error.
The original repo fixed this error by changing the order of the fields of GoFakeS3 struct.

I guess we can fix it by making same change in @igungor's fork.

igungor pushed a commit to igungor/gofakes3 that referenced this issue Jul 22, 2022
Fixes unaligned 64-bit atomic operation error in 32-bit architectures.

Brings same fix from johannesboyne#48 to  fork
Updates peak/s5cmd#446
ilkinulas pushed a commit that referenced this issue Jul 29, 2022
* vendor: upgrade gofakes3 to v0.0.11

Upgraded gofakes version to v0.0.11 to solve unaligned bit error in 32 bit architectures.

Updates #446

* e2e: parse the flags, add "test.race.disabled" flag

The flags of e2e package was not being parsed, so It always used the default values. To fix it,  it will parse the flags in TestMain method.

Add "test.race.disabled" flag to e2e. package to allow users to disable race flag.
Updates #446

* makefile: use different test targets  to disable race flag in tests.

Since windows should not use race flag change the ci.yml accordingly.

* Makefile: infer test type from os

* revert ci.yml to original version

Remove white spaces.

* update according to review
@kucukaslan
Copy link
Contributor

kucukaslan commented Jul 29, 2022

Hi,
You can disable "race" flag1 by using make test_without_race instead of make test or go test ./... when the new release is out.

Footnotes

  1. that is used to build test binary.

@folliehiyuki
Copy link
Author

Thanks a bunch. Will try to build again when the new release is out.

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 a pull request may close this issue.

2 participants