You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by dawidpogorzelski <gi...@git.apache.org> on 2018/08/21 09:35:49 UTC

[GitHub] libcloud pull request #1233: address_data is missing subnetwork

GitHub user dawidpogorzelski opened a pull request:

    https://github.com/apache/libcloud/pull/1233

    address_data is missing subnetwork

    ## When a static IP of type INTERNAL is created in GCE, address_data is missing required subnetwork parameter
    
    ### Description
    
    this is a quick work around for the above problem which results in this traceback:
    
    ```
    File "/src/apache-libcloud/libcloud/compute/drivers/gce.py", line 2921, in ex_create_address
      data=address_data)
    File "/src/apache-libcloud/libcloud/common/base.py", line 772, in async_request
      response = request(**kwargs)
    File "/src/apache-libcloud/libcloud/compute/drivers/gce.py", line 121, in request
      response = super(GCEConnection, self).request(*args, **kwargs)
    File "/src/apache-libcloud/libcloud/common/google.py", line 808, in request
      *args, **kwargs)
    File "/src/apache-libcloud/libcloud/common/base.py", line 637, in request
      response = responseCls(**kwargs)
    File "/src/apache-libcloud/libcloud/common/base.py", line 155, in __init__
      self.object = self.parse_body()
    File "/src/apache-libcloud/libcloud/common/google.py", line 288, in parse_body
      raise InvalidRequestError(message, self.status, code)
    InvalidRequestError: {u'domain': u'global', u'message': u"Invalid value for field 'resource.subnetwork': ''. No default subnetwork was found for an address with type INTERNAL.", u'reason': u'invalid'}
     ```
    
    ### Status
    
    Replace this: describe the PR status. Examples:
    
    - needs review/opinion


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/dawidpogorzelski/libcloud patch-1

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/libcloud/pull/1233.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1233
    
----
commit 75ab4f791949fcf582c3717658317d8a0be5f3f7
Author: Dawid Pogorzelski <da...@...>
Date:   2018-08-21T09:32:35Z

    address_data is missing subnetwork
    
    this is a quick work around for 
    ```
    File "/src/apache-libcloud/libcloud/compute/drivers/gce.py", line 2921, in ex_create_address
      data=address_data)
    File "/src/apache-libcloud/libcloud/common/base.py", line 772, in async_request
      response = request(**kwargs)
    File "/src/apache-libcloud/libcloud/compute/drivers/gce.py", line 121, in request
      response = super(GCEConnection, self).request(*args, **kwargs)
    File "/src/apache-libcloud/libcloud/common/google.py", line 808, in request
      *args, **kwargs)
    File "/src/apache-libcloud/libcloud/common/base.py", line 637, in request
      response = responseCls(**kwargs)
    File "/src/apache-libcloud/libcloud/common/base.py", line 155, in __init__
      self.object = self.parse_body()
    File "/src/apache-libcloud/libcloud/common/google.py", line 288, in parse_body
      raise InvalidRequestError(message, self.status, code)
    InvalidRequestError: {u'domain': u'global', u'message': u"Invalid value for field 'resource.subnetwork': ''. No default subnetwork was found for an address with type INTERNAL.", u'reason': u'invalid'}
     ```

----


---