Conversation
…change attachment_ids is a stored compute, so the web client invalidates it on every onchange round trip that sends back one of its dependencies, even when the value did not change. Each pass called _render_qweb_pdf again: opening the send wizard once could run wkhtmltopdf several times, and every run needs a free HTTP worker to serve itself the report assets. Remember the values the attachments were generated from and reuse them when they are the same. Ticket 126274.
Contributor
jcadhoc
force-pushed
the
19.0-h-126274-jc
branch
from
September 24, 2026 13:59
bd15bc9 to
d097ae0
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Qué pasa
mail.compose.message.attachment_idses un computestore=True, readonly=False. El cliente web lo invalida en cada round-trip de onchange que devuelve alguna de sus dependencias (composition_mode,model,res_domain,res_ids,template_id), aunque el valor no haya cambiado:modified()invalida por nombre de campo, no compara valores.Cada pase volvía a llamar a
_render_qweb_pdfsobre los reportes de la plantilla. Abrir una sola vez el asistente de envío podía disparar varias corridas de wkhtmltopdf, y cada corrida necesita un worker HTTP libre para servirse los CSS del reporte (/web/assets/*report_assets*). En una instancia con pocos workers eso llega a trabar el puerto.Qué cambia
mail_uxrecuerda de qué valores se generaron los adjuntos (attachments_source_key+attachments_source_ids, técnicos) y los reusa cuando son los mismos. Si la plantilla o los registros cambian de verdad, se regeneran como antes.Los dos campos van invisibles en la vista del asistente a propósito: el cliente tiene que devolverlos en el round-trip para que haya con qué comparar.
Cómo se verifica
Contando llamadas a
_render_qweb_pdfsobre el asistente de envío de una orden de compra:first_call)onchange(['body']),['subject'],['partner_ids']onchange(['template_id'])con el mismo valoronchange(['res_ids']),['composition_mode'],['model']Merge
Pide
bump: suma un XML de datos sinnoupdate.Referencia interna: https://www.adhoc.inc/odoo/helpdesk.ticket/126274