From cccd59d3ccac0ccd424bc7708ed434bd6ff5bef4 Mon Sep 17 00:00:00 2001 From: Andrew Lindesay Date: Sat, 12 Oct 2024 15:42:12 +1300 Subject: [PATCH] Python code-gen; doc about setting The recently added Python code-generation handling system now has a setting to control the additional query. This PR contains a documentation tweak to point this out. --- docs/python/code-generators.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/python/code-generators.md b/docs/python/code-generators.md index 7e4b8cb3b0c..0c03c4a4557 100644 --- a/docs/python/code-generators.md +++ b/docs/python/code-generators.md @@ -16,5 +16,10 @@ See the Python example [simple_code_generator](/examples/python/simple_code_gene The Bazel Intelli-J plugin is able to work with generated Python code in this situation. You need to ensure that your code generator has no `srcs` attribute and that it has a tag `intellij-py-code-generator`. This tag signals to the plugin that the Rule's output is generated code. +During a full sync, the plugin will need to execute an additional Bazel `query` in order to locate rules with the tag. This is an unavoidable overhead of this approach and so that the cost of this is only borne by projects that require it, there is a setting to enable it. You will find the file to add the setting in the `.ijwb` directory in your project files. Inside this directory is a file with extension `.bazelproject`; add the following line into this file. + +``` +enable_python_codegen_support: true +```