Opened 4 years ago

Closed 4 years ago

#32208 closed Bug (fixed)

add filter is unable to concatenate strings with lazy string

Reported by: Claude Paroz Owned by: Hasan Ramezani
Component: Template system Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

If you try to concatenate a string with a lazy string with the add template filter, the result is always the empty string because the add filter generates an exception (TypeError: can only concatenate str (not "__proxy__") to str).

Attachments (1)

32208-tests.diff (784 bytes ) - added by Mariusz Felisiak 4 years ago.
Tests.

Download all attachments as: .zip

Change History (7)

by Mariusz Felisiak, 4 years ago

Attachment: 32208-tests.diff added

Tests.

comment:1 by Mariusz Felisiak, 4 years ago

Triage Stage: UnreviewedAccepted

Thanks. I attached a test.

comment:2 by Blackeyeforreal, 4 years ago

Owner: changed from nobody to Blackeyeforreal
Status: newassigned

comment:3 by Blackeyeforreal, 4 years ago

Has patch: set

comment:4 by Mariusz Felisiak, 4 years ago

Patch needs improvement: set

comment:5 by Mariusz Felisiak, 4 years ago

Owner: changed from Blackeyeforreal to Hasan Ramezani
Patch needs improvement: unset
Triage Stage: AcceptedReady for checkin

comment:6 by Mariusz Felisiak <felisiak.mariusz@…>, 4 years ago

Resolution: fixed
Status: assignedclosed

In 577f2338:

Fixed #32208 -- Allowed adding lazy() objects.

Co-authored-by: Claude Paroz <claude@…>

Note: See TracTickets for help on using tickets.
Back to Top