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

[IMP] disable_invalid_filters: log filter probes #373

Merged

Conversation

chienandalu
Copy link
Member

To have a hint on possible bottleneck issues for filters with heavy queries. We can disable it setting the new verbose parameter to False.

cc @Tecnativa TT46020

check @pedrobaeza

@@ -2814,6 +2814,13 @@ def format_message(f):
with savepoint(env.cr):
# Strange artifact found in a filter
domain = f.domain.replace("%%", "%")
if verbose:
logger.info(
"Probing filter '%s' on model %s with domain %s",
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
"Probing filter '%s' on model %s with domain %s",
"Checking filter '%s' on model %s with domain %s",

Probing is not a valid gerund: https://translate.google.com/details?sl=en&tl=es&text=probing&op=translate

Copy link
Member Author

Choose a reason for hiding this comment

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

done

@chienandalu chienandalu force-pushed the imp-log-disable_invalid_filters-probing branch from f6e048f to 7075908 Compare June 14, 2024 10:44
@@ -2814,6 +2814,13 @@ def format_message(f):
with savepoint(env.cr):
# Strange artifact found in a filter
domain = f.domain.replace("%%", "%")
if verbose:
Copy link
Member

Choose a reason for hiding this comment

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

I think you should add the message at the beginning of the loop.

To have a hint on possible bottleneck issues for filters with heavy
queries. We can disable it setting the new `verbose` parameter to
`False`.
@chienandalu chienandalu force-pushed the imp-log-disable_invalid_filters-probing branch from 7075908 to fb69382 Compare June 14, 2024 12:02
@pedrobaeza pedrobaeza merged commit 565c58f into OCA:master Jun 14, 2024
2 checks passed
@pedrobaeza pedrobaeza deleted the imp-log-disable_invalid_filters-probing branch June 14, 2024 14:26
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.

2 participants