Re: [Django] #34883: Allow template tags to set extra data on templates.

2023-10-02 Thread Django
#34883: Allow template tags to set extra data on templates.
-+-
 Reporter:  Carlton Gibson   |Owner:  Carlton
 |  Gibson
 Type:  New feature  |   Status:  closed
Component:  Template system  |  Version:  5.0
 Severity:  Normal   |   Resolution:  fixed
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak ):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"35bbb2c9c01882b1d77b0b8c737ac646144833d4" 35bbb2c]:
 {{{
 #!CommitTicketReference repository=""
 revision="35bbb2c9c01882b1d77b0b8c737ac646144833d4"
 Fixed #34883 -- Allowed template tags to set extra data on templates.

 By setting a value in the `parser.extra_data` mapping, template tags
 pass additional data out of the parsing context.

 Any extra data set is exposed on the template via the matching
 `.extra_data` attribute.

 Library authors should use a key to namespace extra data. The 'django'
 namespace is reserved for internal use.
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018af0dc1070-4f84fd52-9de4-4876-aa93-0a36eff386e3-00%40eu-central-1.amazonses.com.


Re: [Django] #34883: Allow template tags to set extra data on templates.

2023-10-02 Thread Django
#34883: Allow template tags to set extra data on templates.
-+-
 Reporter:  Carlton Gibson   |Owner:  Carlton
 |  Gibson
 Type:  New feature  |   Status:  assigned
Component:  Template system  |  Version:  5.0
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * stage:  Accepted => Ready for checkin


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018af09bd841-9ed9608b-66a1-4259-8f1d-ba0b49c05fa4-00%40eu-central-1.amazonses.com.


Re: [Django] #34883: Allow template tags to set extra data on templates.

2023-09-29 Thread Django
#34883: Allow template tags to set extra data on templates.
-+-
 Reporter:  Carlton Gibson   |Owner:  Carlton
 |  Gibson
 Type:  New feature  |   Status:  assigned
Component:  Template system  |  Version:  5.0
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * stage:  Unreviewed => Accepted


Comment:

 Seems reasonable.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018ae22c99f2-8f41b39e-5a19-405c-b4fc-9fc8ef7a6d7d-00%40eu-central-1.amazonses.com.


Re: [Django] #34883: Allow template tags to set extra data on templates.

2023-09-29 Thread Django
#34883: Allow template tags to set extra data on templates.
-+-
 Reporter:  Carlton Gibson   |Owner:  Carlton
 |  Gibson
 Type:  New feature  |   Status:  assigned
Component:  Template system  |  Version:  5.0
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Carlton Gibson):

 * owner:  nobody => Carlton Gibson


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018ae212fb41-927886f0-0179-42c8-bbac-5efa620cb80b-00%40eu-central-1.amazonses.com.


Re: [Django] #34883: Allow template tags to set extra data on templates.

2023-09-29 Thread Django
#34883: Allow template tags to set extra data on templates.
-+--
 Reporter:  Carlton Gibson   |Owner:  nobody
 Type:  New feature  |   Status:  assigned
Component:  Template system  |  Version:  5.0
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--
Changes (by Carlton Gibson):

 * has_patch:  0 => 1


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018ae2084697-646dcd4d-117d-41cb-af37-007979f43fec-00%40eu-central-1.amazonses.com.


Re: [Django] #34883: Allow template tags to set extra data on templates.

2023-09-29 Thread Django
#34883: Allow template tags to set extra data on templates.
-+--
 Reporter:  Carlton Gibson   |Owner:  nobody
 Type:  New feature  |   Status:  assigned
Component:  Template system  |  Version:  5.0
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by Carlton Gibson):

 [https://github.com/django/django/pull/17325 PR]

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018ae2082242-6941ad68-5695-4cba-8320-c128f5646b0d-00%40eu-central-1.amazonses.com.


[Django] #34883: Allow template tags to set extra data on templates.

2023-09-29 Thread Django
#34883: Allow template tags to set extra data on templates.
---+--
   Reporter:  Carlton Gibson   |  Owner:  nobody
   Type:  New feature  | Status:  assigned
  Component:  Template system  |Version:  5.0
   Severity:  Normal   |   Keywords:
   Triage Stage:  Unreviewed   |  Has patch:  0
Needs documentation:  0|Needs tests:  0
Patch needs improvement:  0|  Easy pickings:  0
  UI/UX:  0|
---+--
 Custom template tags may need to pass additional data, beyond the node
 list, out of the parsing context, for later use, by (e.g.) the template
 loader, or other template clients.

 Currently this is only feasible by attaching data to the `origin` object,
 since that's the only object available to both the template and the
 parser, but this isn't pretty.

 I propose adding an additional attribute to the `Parser` that can be used
 by template tag authors to have extra data set on the template instance,
 that can then be used as needed.

 This ticket comes from the forum discussion on
 [https://forum.djangoproject.com/t/adding-template-fragments-or-partials-
 for-the-dtl/21500 Adding template fragments or partials for the DTL] — it
 is the necessary minimal first change to allow an official[*] API such
 that a library such as `django-template-partials` can pass named node
 lists out of the parser for later use. (I'd imagine it would be useful to
 other tag library authors once in play.)

 [*]: I say official, but I'm not sure whether to make this public — i.e.
 documented — it's pretty niche — those who need it'll find it. I'd be
 happy with a regression test making sure it didn't break but leaving it
 undocumented beyond that. Opinions welcome. 

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018ae204a738-7538be08-6270-4a41-8c6d-9e4ab849fcba-00%40eu-central-1.amazonses.com.