GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Multiple syntax issues with latest generator release 0.44.0 · Issue #848 · googleapis/gapic-generator-python

This repository was archived by the owner on Aug 25, 2026. It is now read-only.
This repository was archived by the owner on Aug 25, 2026. It is now read-only.

Multiple syntax issues with latest generator release 0.44.0 #848

Copy link
Copy link
Closed
#1133
#849
Closed
Multiple syntax issues with latest generator release 0.44.0#848
#1133
#849
Copy link
Assignees
busunkim96

Description

@parthea
parthea
opened on Apr 27, 2021
Issue body actions

There are various PRs opened by owl-bot that are failing for various syntax issues which we believe to be a result of the generator update. I'm going to use this issue to compile a list of the issues that I'm seeing.

For example,
python-area120-tables . See googleapis/python-area120-tables#36
The error is :

2021-04-27T03:52:51.581184531ZStep #5: error: cannot format /workspace/python-area120-tables/google/area120/tables_v1alpha1/types/tables.py: Cannot parse: 637:8: message=struct.Value,

There is a syntax error where there is a comma missing in the arguments for proto.MapField
See here.

class Row(proto.Message):
    r"""A single row in a table.
    Attributes:
        name (str):
            The resource name of the row. Row names have the form
            ``tables/{table}/rows/{row}``. The name is ignored when
            creating a row.
        values (Sequence[google.area120.tables_v1alpha1.types.Row.ValuesEntry]):
            The values of the row. This is a map of
            column key to value. Key is user entered
            name(default) or the internal column id based on
            the view in the request.
    """

    name = proto.Field(
        proto.STRING,
        number=1,
    )
    values = (
        proto.STRING,
        proto.MESSAGE,
        number=2 <---- comma missing here.
        message=struct.Value,
    )

The current client doesn't have a syntax error. See here.

Activity

  1. parthea
    changed the title [-]Multiple issue with latest generator release 0.44.0[/-] [+]Multiple issues with latest generator release 0.44.0[/+] on Apr 27, 2021
  2. parthea
    assigned
    parthea
    and
    busunkim96
    and unassigned
    parthea
    on Apr 27, 2021
  3. parthea
    changed the title [-]Multiple issues with latest generator release 0.44.0[/-] [+]Multiple syntax issues with latest generator release 0.44.0[/+] on Apr 27, 2021
  4. parthea commented on Apr 27, 2021

    @parthea
    parthea
    on Apr 27, 2021
    ContributorAuthor
    More actions

    python-billing . See googleapis/python-billing#63
    The error is

    Info
    2021-04-27T03:52:07.360775961ZStep #5: error: cannot format /workspace/python-billing/google/cloud/billing_v1/services/cloud_billing/client.py: unindent does not match any outer indentation level (<tokenize>, line 1034)
    

    See
    https://github.com/googleapis/python-billing/blob/c4f9cd09da1f3043185093f8bd7d5d8e3a51e1f3/owl-bot-staging/v1/google/cloud/billing_v1/services/cloud_billing/client.py#L1034

             if isinstance(request, dict): <-- this line has a syntax error. There is an extra space in front of the if statement.
                # The request isn't a proto-plus wrapped type,
                # so it must be constructed via keyword expansion.
                request = iam_policy.GetIamPolicyRequest(**request)
            elif not request:
                # Null request, just make one.
                request = iam_policy.GetIamPolicyRequest()
                 if resource is not None:
                    request.resource = resource
    
  5. parthea commented on Apr 27, 2021

    @parthea
    parthea
    on Apr 27, 2021
    ContributorAuthor
    More actions

    python-bigquery-connection . See googleapis/python-bigquery-connection#63
    The error is

    2021-04-27T03:52:49.693371925ZStep #5: error: cannot format /workspace/python-bigquery-connection/google/cloud/bigquery_connection_v1/services/connection_service/client.py: unindent does not match any outer indentation level (<tokenize>, line 853)
    

    See https://github.com/googleapis/python-bigquery-connection/blob/aed7cf2d0797c86b1eec45aab638fc422d03a1dc/owl-bot-staging/v1/google/cloud/bigquery_connection_v1/services/connection_service/client.py#L853
    This looks to be the same issue as python-billing where there is an extra space in front of the if statement.

             if isinstance(request, dict):<-- this line has a syntax error. There is an extra space in front of the if statement.
                # The request isn't a proto-plus wrapped type,
                # so it must be constructed via keyword expansion.
                request = iam_policy.GetIamPolicyRequest(**request)
            elif not request:
                # Null request, just make one.
                request = iam_policy.GetIamPolicyRequest()
                 if resource is not None:
                    request.resource = resource
    
  6. gcf-merge-on-green
    closed this as completedin #849on Apr 28, 2021
  7. gcf-merge-on-green
    added a commit that references this issue on Apr 28, 2021

    fix: fix syntax errors and failing unit tests (#849)

    This issue will close once commit 9046261 is merged into the 'main' branch.
    9046261
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @busunkim96
    busunkim96

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.