EC2ResponseError

EC2ResponseError: 400 Bad Request <?xml version='1.0' encoding='UTF-8'?> <Response><RequestID>d025e837-fd9e-4fcd-b6cb-b7e99db2d000</RequestID><Errors><Error><Code>InvalidVpnConnectionID.NotFound</Code><Message>The vpnConnection ID 'vpn-0C2DFE55' does not exist</Message></Error></Errors></Response> search by Google

_errorResultSet : ResultSet
[<boto.exception._EC2Error object at 0x7fe3fd5b7850>]
_error_message : NoneType
None
args : tuple
(400, 'Bad Request', b"<?xml version='1.0' encoding='UTF-8'?>\n<Response><RequestID>d025e837-fd9e-4fcd-b6cb-b7e99db2d000</RequestID><Errors><Error><Code>InvalidVpnConnectionID.NotFound</Code><Message>The vpnConnection ID 'vpn-0C2DFE55' does not exist</Message></Error></Errors></Response>")
body : str
<?xml version='1.0' encoding='UTF-8'?> <Response><RequestID>d025e837-fd9e-4fcd-b6cb-b7e99db2d000</RequestID><Errors><Error><Code>InvalidVpnConnectionID.NotFound</Code><Message>The vpnConnection ID 'vpn-0C2DFE55' does not exist</Message></Error></Errors></Response>
box_usage : NoneType
None
error_code : str
InvalidVpnConnectionID.NotFound
errors : list
[('InvalidVpnConnectionID.NotFound', "The vpnConnection ID 'vpn-0C2DFE55' does not exist")]
message : str
The vpnConnection ID 'vpn-0C2DFE55' does not exist
reason : str
Bad Request
request_id : str
d025e837-fd9e-4fcd-b6cb-b7e99db2d000
status : int
400

Traceback

  1. /usr/local/lib/python3.7/unittest/case.py in testPartExecutor (arguments )

    self : _Outcome
    <unittest.case._Outcome object at 0x7fe3ef431b90>
    test_case : VpnConnections
    test_create_vpnc_negative (c2tests.vpc.vpn_connections.VpnConnections)
    isTest : bool
    True
    1. @contextlib.contextmanager
    2. def testPartExecutor(self, test_case, isTest=False):
    3. old_success = self.success
    4. self.success = True
    5. try:
    6. yield
    7. except KeyboardInterrupt:
    8. raise
    9. except SkipTest as e:
    10. self.success = False

    Locals

    exc_info : NoneType
    None
    old_success : bool
    True

    Globals

    __unittest : bool
    True
    _subtest_msg_sentinel : object
    <object object at 0x7fe415310fc0>
    DIFF_OMITTED : str
    Diff is %s characters long. Set self.maxDiff to None to see it.
  2. /usr/local/lib/python3.7/unittest/case.py in run (arguments )

    self : VpnConnections
    test_create_vpnc_negative (c2tests.vpc.vpn_connections.VpnConnections)
    result : DiagnosticsTestResult
    <xmlrunner.extra.diagnosticstestrunner.DiagnosticsTestResult run=1 errors=0 failures=0>
    1. with outcome.testPartExecutor(self):
    2. self.setUp()
    3. if outcome.success:
    4. outcome.expecting_failure = expecting_failure
    5. with outcome.testPartExecutor(self, isTest=True):
    6. testMethod()
    7. outcome.expecting_failure = False
    8. with outcome.testPartExecutor(self):
    9. self.tearDown()

    Locals

    expecting_failure : bool
    False
    expecting_failure_class : bool
    False
    expecting_failure_method : bool
    False
    orig_result : DiagnosticsTestResult
    <xmlrunner.extra.diagnosticstestrunner.DiagnosticsTestResult run=1 errors=0 failures=0>
    outcome : _Outcome
    <unittest.case._Outcome object at 0x7fe3ef431b90>
    testMethod : method
    <bound method VpnConnections.test_create_vpnc_negative of <c2tests.vpc.vpn_connections.VpnConnections testMethod=test_create_vpnc_negative>>

    Globals

    __unittest : bool
    True
    _subtest_msg_sentinel : object
    <object object at 0x7fe415310fc0>
    DIFF_OMITTED : str
    Diff is %s characters long. Set self.maxDiff to None to see it.
  3. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/vpc/vpn_connections.py in test_create_vpnc_negative (arguments )

    self : VpnConnections
    test_create_vpnc_negative (c2tests.vpc.vpn_connections.VpnConnections)
    1. vpnc = self.create_vpn_connection(
    2. constants.VPNC_TYPE_IPSEC_1, self.cgw_id, self.vgw_id,
    3. tunnel_options=[{"TunnelInsideCidr": "169.254.255.0/30"}]
    4. )
    5. self.wait_for_vpnc_creation(vpnc)
    6. vpnc_again = self.create_vpn_connection(
    7. constants.VPNC_TYPE_IPSEC_1,
    8. self.cgw_id, self.vgw_id,

    Locals

    vpnc : VpnConnection
    VpnConnection:vpn-0C2DFE55

    Globals

    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    VTYSH_TEMPLATE : str
    vtysh <<EOF configure terminal ! router bgp {0} no bgp ebgp-requires-policy no bgp network import-check neighbor {1} remote-as {2} neighbor {1} activate neighbor {1} ebgp-multihop neighbor {1} timers 10 30 network {3} exit EOF
  4. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/vpc/vpn_connections.py in wait_for_vpnc_creation (arguments )

    self : VpnConnections
    test_create_vpnc_negative (c2tests.vpc.vpn_connections.VpnConnections)
    conn : VPCConnection
    <c2tests.profile.VPCConnection object at 0x7fe3fead8bd0>
    *vpncs : tuple
    (VpnConnection:vpn-0C2DFE55,)
    1. self.log.info("Done waiting for BGP sync.")
    2. def wait_for_vpnc_creation(self, *vpncs, conn=None):
    3. if conn is None:
    4. conn = self.vpcconn
    5. utils.wait_for_vpnc_creation(conn, *vpncs)
    6. def wait_for_vpnc_deletion(self, *vpncs, conn=None):
    7. if conn is None:
    8. conn = self.vpcconn

    Locals

    Globals

    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    VTYSH_TEMPLATE : str
    vtysh <<EOF configure terminal ! router bgp {0} no bgp ebgp-requires-policy no bgp network import-check neighbor {1} remote-as {2} neighbor {1} activate neighbor {1} ebgp-multihop neighbor {1} timers 10 30 network {3} exit EOF
  5. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wait_for_vpnc_creation (arguments )

    conn : VPCConnection
    <c2tests.profile.VPCConnection object at 0x7fe3fead8bd0>
    *vpncs : tuple
    (VpnConnection:vpn-0C2DFE55,)
    1. if diff:
    2. raise Error(f"VPN connection {diff.pop()} has disappeared.")
    3. return True
    4. wait_long(check_state)
    5. def wait_for_vpnc_deletion(conn, *vpncs):
    6. """Wait while VPN connection stopping and deleting."""

    Locals

    vpnc_map : dict
    {'vpn-0C2DFE55': VpnConnection:vpn-0C2DFE55}

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  6. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wait_long (arguments )

    func : function
    <function wait_for_vpnc_creation.<locals>.check_state at 0x7fe3ef4c83b0>
    *args : tuple
    ()
    **kwargs : dict
    {}
    1. def wait_long(func, *args, **kwargs):
    2. """Fail unless func return success within the long timeout"""
    3. return wait(5 * constants.MINUTE_SECONDS, func, *args, **kwargs)
    4. def wait_long_enough(func, *args, **kwargs):
    5. """Fail unless func return success within the enough long timeout."""

    Locals

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  7. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in wait (arguments )

    timeout : int
    300
    func : function
    <function wait_for_vpnc_creation.<locals>.check_state at 0x7fe3ef4c83b0>
    *args : tuple
    ()
    **kwargs : dict
    {}
    1. def wait(timeout, func, *args, **kwargs):
    2. """Fail unless func return success within specified number of seconds"""
    3. endtime = time.time() + float(timeout)
    4. while time.time() < endtime:
    5. result = func(*args, **kwargs)
    6. if result:
    7. return result
    8. time.sleep(min(timeout, 0.1))

    Locals

    endtime : float
    1708647631.908632
    result : bool
    False

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  8. /root/c2tests/.venv/lib/python3.7/site-packages/c2tests/utils.py in check_state (arguments )

    1. vpnc_map = {vpnc.id: vpnc for vpnc in vpncs}
    2. def check_state():
    3. got_ids = set()
    4. for vpnc in conn.get_all_vpn_connections(list(vpnc_map)):
    5. got_ids.add(vpnc.id)
    6. if vpnc.state == constants.VPNC_STATE_PENDING:
    7. return False

    Locals

    conn : VPCConnection
    <c2tests.profile.VPCConnection object at 0x7fe3fead8bd0>
    got_ids : set
    set()
    vpnc_map : dict
    {'vpn-0C2DFE55': VpnConnection:vpn-0C2DFE55}

    Globals

    _DD : str
    /bin/dd
    _QEMU_IMG : str
    /usr/bin/qemu-img
    LOG : RootLogger
    <RootLogger root (DEBUG)>
    md5 : builtin_function_or_method
    <built-in function openssl_md5>
    RULES : list
    [{'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'tcp', 'from_port': '22', 'to_port': '22'}, {'cidr_ip': '0.0.0.0/0', 'ip_protocol': 'icmp', 'from_port': '-1', 'to_port': '-1'}]
  9. /root/c2tests/.venv/src/boto/boto/vpc/__init__.py in get_all_vpn_connections (arguments )

    self : VPCConnection
    VPCConnection:api.dev.c2.croc.ru
    vpn_connection_ids : list
    ['vpn-0C2DFE55']
    filters : NoneType
    None
    dry_run : bool
    False
    1. if filters:
    2. self.build_filter_params(params, filters)
    3. if dry_run:
    4. params['DryRun'] = 'true'
    5. return self.get_list('DescribeVpnConnections', params,
    6. [('item', VpnConnection)])
    7. def create_vpn_connection(
    8. self, type, customer_gateway_id, vpn_gateway_id,
    9. ipv4_network_cidr_local=None, ipv4_network_cidr_remote=None,

    Locals

    params : dict
    {'VpnConnectionId.1': 'vpn-0C2DFE55'}

    Globals

    RegionData : dict
    {'ap-southeast-2': 'ec2.ap-southeast-2.amazonaws.com', 'ap-south-1': 'ec2.ap-south-1.amazonaws.com', 'ca-central-1': 'ec2.ca-central-1.amazonaws.com', 'sa-east-1': 'ec2.sa-east-1.amazonaws.com', 'cn-north-1': 'ec2.cn-north-1.amazonaws.com.cn', 'ap-northeast-2': 'ec2.ap-northeast-2.amazonaws.com', 'ap-southeast-1': 'ec2.ap-southeast-1.amazonaws.com', 'eu-central-1': 'ec2.eu-central-1.amazonaws.com', 'us-west-2': 'ec2.us-west-2.amazonaws.com', 'us-east-1': 'ec2.us-east-1.amazonaws.com', 'eu-west-1': 'ec2.eu-west-1.amazonaws.com', 'us-east-2': 'ec2.us-east-2.amazonaws.com', 'us-gov-west-1': 'ec2.us-gov-west-1.amazonaws.com', 'us-west-1': 'ec2.us-west-1.amazonaws.com', 'eu-west-2': 'ec2.eu-west-2.amazonaws.com', 'ap-northeast-1': 'ec2.ap-northeast-1.amazonaws.com'}
  10. /root/c2tests/.venv/src/boto/boto/connection.py in get_list (arguments )

    self : VPCConnection
    VPCConnection:api.dev.c2.croc.ru
    action : str
    DescribeVpnConnections
    params : dict
    {'VpnConnectionId.1': 'vpn-0C2DFE55'}
    markers : list
    [('item', <class 'boto.vpc.vpnconnection.VpnConnection'>)]
    path : str
    /
    parent : VPCConnection
    VPCConnection:api.dev.c2.croc.ru
    verb : str
    GET
    1. xml.sax.parseString(body, h)
    2. return rs
    3. else:
    4. boto.log.error('%s %s' % (response.status, response.reason))
    5. boto.log.error('%s' % body)
    6. raise self.ResponseError(response.status, response.reason, body)
    7. def get_object(self, action, params, cls, path='/',
    8. parent=None, verb='GET'):
    9. if not parent:

    Locals

    body : bytes
    <?xml version='1.0' encoding='UTF-8'?> <Response><RequestID>d025e837-fd9e-4fcd-b6cb-b7e99db2d000</RequestID><Errors><Error><Code>InvalidVpnConnectionID.NotFound</Code><Message>The vpnConnection ID 'vpn-0C2DFE55' does not exist</Message></Error></Errors></Response>
    response : HTTPResponse
    <boto.connection.HTTPResponse object at 0x7fe3ef431250>

    Globals

    config : Config
    <boto.pyami.config.Config object at 0x7fe407f452d0>
    DEFAULT_CA_CERTS_FILE : str
    /root/c2tests/.venv/src/boto/boto/cacerts/cacerts.txt
    HAVE_HTTPS_CONNECTION : bool
    True
    ON_APP_ENGINE : bool
    False
    PORTS_BY_SECURITY : dict
    {True: 443, False: 80}
    UserAgent : str
    Boto/2.46.1 Python/3.7.9 Linux/3.10.0-862.2.3.el7.x86_64

Environment

Time of report generation
2024-02-23 03:15:46
Python version
3.7.9 (default, Sep 21 2022, 19:11:27) [GCC 4.8.5 20150623 (Red Hat 4.8.5-44)]
Path to executable
/root/c2tests/.venv/bin/python
Working directory
/root/c2tests
Arguments vector
  1. /root/c2tests/.venv/bin/c2tests
  2. run
  3. -s
  4. ec2
  5. s3
  6. vpc