You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
A refused c-bind key on <c-slot> or <c-fill> raises RuntimeError instead of VueCodeError #559
A c-bind mapping on <c-slot> or <c-fill> that holds a key Vue would read as code, such as ":row" or "v-slot", is refused at render. That part is right. But the render raises a plain RuntimeError. On HTML elements and component tags, the same mistake raises VueCodeError (a TypeError subclass exported from citry), whose docstring promises it for every c-bind key that Vue would read as code.
So code that catches VueCodeError, and any docs that point to it, miss the slot case.
What to do
Raise VueCodeError for these keys on <c-slot> and <c-fill>, keep the message, and add a test for each tag. Check the other raise RuntimeError calls next to it for the same mistake (for example a : prop written with {{ ... }}), and update the VueCodeError docstring if the list of places it covers changes.
Pointers
packages/py/citry/citry/nodes/__init__.py, the c-bind handling for <c-slot> (around raise RuntimeError(unsupported)) and for <c-fill>
packages/py/citry/citry/attrs.py, class VueCodeError
Docs: docs_site/content/vue/slots.md, "Errors when rendering"
Error mode
The render already fails, so nothing reaches the page. Only the exception type changes. Code catching RuntimeError keeps working only if it also catches TypeError, so this needs a changelog line.
Activity
fix: refuse more Vue-code names on c-slot and read c-bind keys as exa…
fix: raise VueCodeError for a Vue-code c-bind key on c-slot and c-fill (
fix: refuse more Vue-code names on c-slot and read c-bind keys as exa…
fix: raise VueCodeError for a Vue-code c-bind key on c-slot and c-fill (