fix(data): preserve more field in media metrics to fix image loading …#1359
Conversation
…issue - Modified __filter_list to accept keep_none_list parameter - Ensure more field is always present in log data even when all values are None - This fixes the frontend TypeError when accessing more[0] Fixes SwanHubX#1354
Summary of ChangesHello @Talljack, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request resolves a frontend Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request effectively resolves a frontend TypeError by modifying __filter_list to conditionally preserve lists containing only None values. The logic is sound. My review includes suggestions to improve the clarity of a docstring and to make the implementation of __filter_list more concise.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Updated the __filter_list static method to return None only when the input list is empty or all elements are None, unless keep_none_list is True. This refactoring simplifies the logic and improves code readability.

…issue
Fixes #1354
Description
Please include a concise summary, in clear English, of the changes in this pull request. If it closes an issue, please
mention it here.
Closes: #(issue)
🎯 PRs Should Target Issues
Before your create a PR, please check to see if there is an existing issue
for this change. If not, please create an issue before you create this PR, unless the fix is very small.
Not adhering to this guideline will result in the PR being closed.