Treat --- as text when not valid config delimiter - #47
Merged
Conversation
## Summary PromptL now intelligently treats `---` as regular text when it cannot be a valid config section delimiter, eliminating unnecessary errors. Previously, any occurrence of `---` in a document would be parsed as a config delimiter, forcing users to escape it as `\---` even in cases where it clearly couldn't be config (e.g., after the config section was already closed, or when there was content before it). With this change: - `---` appearing after a config section has been closed is treated as text - `---` appearing after any substantive content (text, tags, mustache expressions) is treated as text - Comments and whitespace before `---` still allow it to be parsed as config This aligns parsing behavior with the specification that config must be at the top of the file, making prompt authoring more intuitive.
csansoon
force-pushed
the
ignore-non-config-dashes
branch
from
February 2, 2026 10:41
7cf9026 to
d6dda7c
Compare
andresgutgon
approved these changes
Feb 2, 2026
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.
Summary
PromptL now intelligently treats
---as regular text when it cannot be a valid config section delimiter, eliminating unnecessary errors.Previously, any occurrence of
---in a document would be parsed as a config delimiter, forcing users to escape it as\---even in cases where it clearly couldn't be config (e.g., after the config section was already closed, or when there was content before it).With this change:
---appearing after a config section has been closed is treated as text---appearing after any substantive content (text, tags, mustache expressions) is treated as text---still allow it to be parsed as configThis aligns parsing behavior with the specification that config must be at the top of the file, making prompt authoring more intuitive.