Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
diegomarquezp committed Jul 3, 2024
1 parent 5fd8f9e commit 635d92a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
5 changes: 3 additions & 2 deletions library_generation/owlbot/synthtool/gcp/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@
class CommonTemplates:
def __init__(self, template_path: Optional[Path] = None):
if LOCAL_TEMPLATES is None:
logger.error("env var SYNTHTOOL_TEMPLATES must be set")
sys.exit(1)
logger.error("env var SYNTHTOOL_TEMPLATES must be set")
sys.exit(1)
logger.debug(f"Using local templates at {LOCAL_TEMPLATES}")
self._template_root = Path(LOCAL_TEMPLATES)
self._templates = templates.Templates(self._template_root)
Expand Down Expand Up @@ -151,6 +151,7 @@ def _get_default_branch_name(repository_name: str) -> str:
# the majority of our repositories:
return os.getenv("DEFAULT_BRANCH", "master")


def load_partials(files: List[str] = []) -> Dict:
"""
hand-crafted artisanal markdown can be provided in a .readme-partials.yml.
Expand Down
4 changes: 3 additions & 1 deletion library_generation/owlbot/synthtool/languages/java.py
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,9 @@ def common_templates(
)
)

templates = gcp.common.CommonTemplates(template_path=template_path).java_library(**kwargs)
templates = gcp.common.CommonTemplates(template_path=template_path).java_library(
**kwargs
)

# skip README generation on Kokoro (autosynth)
if os.environ.get("KOKORO_ROOT") is not None:
Expand Down
1 change: 0 additions & 1 deletion library_generation/owlbot/synthtool/sources/templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,3 @@ def render(self, subdir: PathOrStr = ".", **kwargs) -> Path:
print(f"Skipping: {template_name}")

return self.dir

1 change: 1 addition & 0 deletions library_generation/owlbot/synthtool/transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
logger = logging.getLogger()
logger.setLevel(logging.DEBUG)


class MissingSourceError(Exception):
pass

Expand Down

0 comments on commit 635d92a

Please sign in to comment.