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

called getFullRequestData() before export #8333

Merged

Conversation

hrajwade96
Copy link
Contributor

Fixes bug -
Not able to see response content in exported har for few requests.

List which issues are fixed by this PR.
#8253

Please add a note to packages/devtools_app/release_notes/NEXT_RELEASE_NOTES.md if your change requires release notes. Otherwise, add the 'release-notes-not-required' label to the PR.

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read the Flutter Style Guide recently, and have followed its advice.
  • I signed the CLA.
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or there is a reason for not adding tests.

build.yaml badge

If you need help, consider asking for help on Discord.

@hrajwade96
Copy link
Contributor Author

@kenzieschmoll please check this, if this looks ok can we add this as a hotfix in beta?

await item.getFullRequestData();
}
}
}

Choose a reason for hiding this comment

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

Would it make sense to await them all in one operation instead of awaiting each call to getFullRequestData before requesting the next? So something like:

Future<void> _fetchFullDataBeforeExport() =>
    Future.wait(filteredData.value.whereType<DartIOHttpRequestData>());

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, this will optimise it, I had thought of doing it earlier but I missed changing it.
Thanks @julemand101

Changed it to -

`Future _fetchFullDataBeforeExport() =>

  Future.wait(
    filteredData.value
        .whereType<DartIOHttpRequestData>()
        .map((item) => item.getFullRequestData()),
  );`

@hrajwade96
Copy link
Contributor Author

@kenzieschmoll do you have any feedback on this? if not can this be merged @bkonyi

@bkonyi
Copy link
Contributor

bkonyi commented Sep 30, 2024

@kenzieschmoll do you have any feedback on this? if not can this be merged @bkonyi

I think this is safe to be merged without explicit approval from @kenzieschmoll but we should update the release notes at packages/devtools_app/release_notes/NEXT_RELEASE_NOTES.md to include this bug fix.

@hrajwade96 hrajwade96 requested a review from a team as a code owner September 30, 2024 15:28
@kenzieschmoll kenzieschmoll merged commit 89e6c7e into flutter:master Sep 30, 2024
23 checks passed
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.

4 participants