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

test(sharness): improve CAR tests to remove some potential races #7154

Merged
merged 1 commit into from
Apr 14, 2020

Conversation

Stebalien
Copy link
Member

  • Instead of ensuring that we GC nothing, verify that the repo validates.
  • Avoid a race between removing the fifos and trying to read from them.
  • Avoid all 'bash -c' invocations. Instead, make liberal use of subshells and wait.

Hopefully fixes #7123.

* Instead of ensuring that we GC nothing, verify that the repo validates.
* Avoid a race between removing the fifos and trying to read from them.
* Avoid all 'bash -c' invocations. Instead, make liberal use of subshells and
  wait.

Hopefully fixes #7123.
Copy link
Contributor

@ribasushi ribasushi left a comment

Choose a reason for hiding this comment

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

Let's merge this as is
I think I found the lock - it is in the part that got removed
I'm, putting together another PR, but it might take (quite) a while

@ribasushi
Copy link
Contributor

This is what the test was supposed to look like, and that doesn't currently work even though it should. Looking...

        # part 2 goes first and blocks waiting on ipfs
        cat ../t0054-dag-car-import-export-data/lotus_devnet_genesis_shuffled_nulroot.car > pipe_devnet &

        # ipfs import starts and blocks on part 1
        ipfsi 0 dag import \
          pipe_testnet \
          pipe_devnet \
          ../t0054-dag-car-import-export-data/combined_naked_roots_genesis_and_128.car \
        2>&1 &

        # part 1 unblocks everything
        cat ../t0054-dag-car-import-export-data/lotus_testnet_export_128_shuffled_nulroot.car > pipe_testnet &

        # remove pipes right away
        rm -f pipe_devnet pipe_testnet

@Stebalien Stebalien merged commit 2560e46 into master Apr 14, 2020
@Stebalien Stebalien deleted the fix/car-sharness branch April 14, 2020 05:35
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.

Strage sharness failure in CAR tests
2 participants