dave2wave opened a new issue, #205:
URL: https://github.com/apache/tooling-trusted-release/issues/205

   When I click on the name of a committee on the committees page I get an 
error on rendering the page:
   
   ```
   Parent instance <Project at 0x73acd3a74e10> is not bound to a Session; lazy 
load operation of attribute 'committee' cannot proceed (Background on this 
error at: https://sqlalche.me/e/20/bhk3)
   
   An error occurred while processing your request. This has been logged and 
will be addressed.
   
   Status Code: 500
   
   Technical Details
   
   Traceback (most recent call last):
     File "/opt/atr/.venv/lib/python3.13/site-packages/quart/app.py", line 
1500, in full_dispatch_request
       result = await self.dispatch_request(request_context)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/opt/atr/.venv/lib/python3.13/site-packages/quart/app.py", line 
1597, in dispatch_request
       return await self.ensure_async(handler)(**request_.view_args)  # type: 
ignore[return-value]
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/opt/atr/atr/routes/__init__.py", line 375, in wrapper
       future = coro.send(None)
     File "/opt/atr/atr/routes/__init__.py", line 490, in wrapper
       return await func(*args, **kwargs)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/opt/atr/atr/routes/committees.py", line 54, in view
       return await template.render(
              ^^^^^^^^^^^^^^^^^^^^^^
       ...<6 lines>...
       )
       ^
     File "/opt/atr/atr/template.py", line 41, in render_sync
       return await _render_in_thread(template, context_vars, app_instance)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/opt/atr/atr/template.py", line 56, in _render_in_thread
       rendered_template = await asyncio.to_thread(template.render, context)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/usr/local/lib/python3.13/asyncio/threads.py", line 25, in to_thread
       return await loop.run_in_executor(None, func_call)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/usr/local/lib/python3.13/concurrent/futures/thread.py", line 59, in 
run
       result = self.fn(*self.args, **self.kwargs)
     File "/opt/atr/.venv/lib/python3.13/site-packages/jinja2/environment.py", 
line 1288, in render
       return asyncio.run(self.render_async(*args, **kwargs))
              ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/usr/local/lib/python3.13/asyncio/runners.py", line 195, in run
       return runner.run(main)
              ~~~~~~~~~~^^^^^^
     File "/usr/local/lib/python3.13/asyncio/runners.py", line 118, in run
       return self._loop.run_until_complete(task)
              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
     File "/usr/local/lib/python3.13/asyncio/base_events.py", line 725, in 
run_until_complete
       return future.result()
              ~~~~~~~~~~~~~^^
     File "/opt/atr/.venv/lib/python3.13/site-packages/jinja2/environment.py", 
line 1318, in render_async
       return self.environment.handle_exception()
              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
     File "/opt/atr/.venv/lib/python3.13/site-packages/jinja2/environment.py", 
line 942, in handle_exception
       raise rewrite_traceback_stack(source=source)
     File "/opt/atr/atr/templates/committee-view.html", line 1, in top-level 
template code
       {% extends "layouts/base.html" %}
       ^^^^^^^^^^^^^^^^^^^^^^^^^
     File "/opt/atr/atr/templates/layouts/base.html", line 49, in top-level 
template code
       {% block content %}
       ^^^^^^^^^^^^^
     File "/opt/atr/atr/templates/committee-view.html", line 36, in block 
'content'
       <a href="{{ as_url(routes.projects.view, name=project.name) }}">{{ 
project.display_name }}</a>
       ^^^^^^^^^^^^^
     File "/opt/atr/.venv/lib/python3.13/site-packages/jinja2/environment.py", 
line 490, in getattr
       return getattr(obj, attribute)
     File "/opt/atr/atr/models/sql.py", line 451, in display_name
       if self.committee and self.committee.is_podling:
          ^^^^^^^^^^^^^^
     File 
"/opt/atr/.venv/lib/python3.13/site-packages/sqlalchemy/orm/attributes.py", 
line 566, in __get__
       return self.impl.get(state, dict_)  # type: ignore[no-any-return]
              ~~~~~~~~~~~~~^^^^^^^^^^^^^^
     File 
"/opt/atr/.venv/lib/python3.13/site-packages/sqlalchemy/orm/attributes.py", 
line 1086, in get
       value = self._fire_loader_callables(state, key, passive)
     File 
"/opt/atr/.venv/lib/python3.13/site-packages/sqlalchemy/orm/attributes.py", 
line 1121, in _fire_loader_callables
       return self.callable_(state, passive)
              ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^
     File 
"/opt/atr/.venv/lib/python3.13/site-packages/sqlalchemy/orm/strategies.py", 
line 922, in _load_for_state
       raise orm_exc.DetachedInstanceError(
       ...<3 lines>...
       )
   sqlalchemy.orm.exc.DetachedInstanceError: Parent instance <Project at 
0x73acd3a74e10> is not bound to a Session; lazy load operation of attribute 
'committee' cannot proceed (Background on this error at: 
https://sqlalche.me/e/20/bhk3)
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@tooling.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tooling.apache.org
For additional commands, e-mail: dev-h...@tooling.apache.org

Reply via email to