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

Flaky tests due to network errors fetching properties #430

Closed
joepio opened this issue Jun 9, 2022 · 0 comments · Fixed by #431
Closed

Flaky tests due to network errors fetching properties #430

joepio opened this issue Jun 9, 2022 · 0 comments · Fixed by #431

Comments

@joepio
Copy link
Member

joepio commented Jun 9, 2022

Sometimes when runnign cargo nextest run, I get errors like these:

thread 'db::test::index_invalidate_cache' panicked at 'called `Result::unwrap()` on an `Err` value: AtomicError { message: "Failed setting propval for 'https://localhost/agents/w0ppEskueRjKC6S9tAawjtFJYtTWsndcHpQ96OlHq6Q=' because property 'https://atomicdata.dev/properties/publicKey' could not be found. Failed getting property https://atomicdata.dev/properties/publicKey. Error when fetching https://atomicdata.dev/properties/publicKey : https://atomicdata.dev/properties/publicKey: Network Error: Network Error: Error encountered in the status line: timed out reading response", error_type: OtherError }', lib/src/db/test.rs:436:52
thread 'parse::test::serialize_parse_roundtrip' panicked at 'called `Result::unwrap()` on an `Err` value: AtomicError { message: "Unable to import JSON-AD. Unable to parse resource. Failed getting property https://atomicdata.dev/properties/name. Error when fetching https://atomicdata.dev/properties/name : https://atomicdata.dev/properties/name: Network Error: Network Error: Error encountered in a header: timed out reading response", error_type: OtherError }', lib/src/parse.rs:246:36

Edit: seems like the issue is that create_agent fetches properties, because they aren't loaded yet. This should not be needed, because we know the datatypes are valid.

I should find a way to make tests fail when they do a network call

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.

1 participant