Skip to content

Spurious SAM parser warning: Unannotated phrase found:  #205

@0x8000-0000

Description

@0x8000-0000

Considering this input:

$ cat test_phrase_condition.sam 
!annotation-lookup: case insensitive
!smart-quotes: on

example: Title

    section:(?some=time)
        {Hard}(?when=weekday){Easy}(?when=weekend) day ahead!
        {Pack the cooler!}(?when=weekend)

Produces this:

$ python3 ${HOME}/tools/sam/samparser.py html test_phrase_condition.sam


SAM parser information: Parsing /home/fiucha/tmp/test_phrase_condition.sam
SAM parser warning: Unannotated phrase found: {Hard} If you are trying to insert curly braces into the document, use \{Hard}.
SAM parser warning: Unannotated phrase found: {Easy} If you are trying to insert curly braces into the document, use \{Easy}.
SAM parser warning: Unannotated phrase found: {Pack the cooler!} If you are trying to insert curly braces into the document, use \{Pack the cooler!}.
Using css: None
Process completed with 0 errors.
<!DOCTYPE html>
<html>
<head>
<title>Title</title>
<meta charset = "UTF-8">
</head>
<body>
<div class="example">
<h1 class="title">Title</h1>

<div class="section" data-conditions="some=time">
<p class="p"><span class="phrase" data-conditions="when=weekday">Hard</span><span class="phrase" data-conditions="when=weekend">Easy</span> day ahead! <span class="phrase" data-conditions="when=weekend">Pack the cooler!</span></p>
</div>
</div>
</body>
</html>%                                 

The warning seems spurious since the phrases are clearly annotated - the conditions are present in the output.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions