Continuous warning because of missing context wrapper

Bug #1984267 reported by Takashi Kajinami
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fix Released
Lajos Katona

Bug Description

In Puppet OpenStack job we observe the following WARNING when networking-l2gw is enabled
2022-08-10 01:37:59.632 102553 WARNING neutron.objects.base [None req-af43a873-e1a2-47fc-a042-c05b097174d8 29ba9fe95d764558b26721100f5ba111 9638fb7183254ecf9d8a2d6d3a8226e0 - - default default] ORM session: SQL execution without transacti
on in progress, traceback:
  File "/usr/lib/python3.9/site-packages/eventlet/", line 221, in main
    result = function(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/eventlet/", line 837, in process_request
    proto.__init__(conn_state, self)
  File "/usr/lib/python3.9/site-packages/eventlet/", line 350, in __init__
  File "/usr/lib/python3.9/site-packages/networking_l2gw/db/l2gateway/", line 234, in get_l2_gateway
    gw_db = self._get_l2_gateway(context, id)
  File "/usr/lib/python3.9/site-packages/networking_l2gw/db/l2gateway/", line 46, in _get_l2_gateway
    gw = context.session.query(models.L2Gateway).get(gw_id)
  File "<string>", line 2, in get
  File "/usr/lib64/python3.9/site-packages/sqlalchemy/util/", line 402, in warned
    return fn(*args, **kwargs)
  File "/usr/lib64/python3.9/site-packages/sqlalchemy/orm/", line 943, in get
    return self._get_impl(ident, loading.load_on_pk_identity)
  File "/usr/lib64/python3.9/site-packages/sqlalchemy/orm/", line 947, in _get_impl
    return self.session._get_impl(
  File "/usr/lib64/python3.9/site-packages/sqlalchemy/orm/", line 2912, in _get_impl
    return db_load_fn(
  File "/usr/lib64/python3.9/site-packages/sqlalchemy/orm/", line 530, in load_on_pk_identity
  File "/usr/lib64/python3.9/site-packages/sqlalchemy/orm/", line 1693, in execute
    result = fn(orm_exec_state)

Changed in networking-l2gw:
status: New → Confirmed
assignee: nobody → Lajos Katona (lajos-katona)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to networking-l2gw (master)

Fix proposed to branch: master

Changed in networking-l2gw:
status: Confirmed → In Progress
Revision history for this message
Lajos Katona (lajos-katona) wrote :

Takashi, could you please check if this patch covers all the issues? By my testing it is ok.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-l2gw (master)

Submitter: "Zuul (22348)"
Branch: master

commit fbebe30031a3055c46fa45f85e85a37b4712a370
Author: elajkat <email address hidden>
Date: Thu Aug 18 15:12:28 2022 +0200

    Add context for all SQL transactions

    Follow the last efforts to make Neutron compatible with sqlalchemy-20
    (see [1]), and use the necessary context for all SQL transactions.


    Change-Id: I8923760e011aacb8523022e64a3cb38b7eaa89ba
    Closes-Bug: #1984267

Changed in networking-l2gw:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.