Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editing RewriteRule with multiline template is not possible #256

Open
edwardsph opened this issue Jun 8, 2016 · 0 comments
Open

Editing RewriteRule with multiline template is not possible #256

edwardsph opened this issue Jun 8, 2016 · 0 comments

Comments

@edwardsph
Copy link
Contributor

If a template has a header defined e.g.

/usepa/app/pipelines/company-data.xpl?results&id={id}
Accept: application/rdf+xml

When it is loaded back into the edit page, the newline becomes a space. Even if you correct this and try and save it again you can't because the SPARQL is built around the corrupted string:

PREFIX dc:<http://purl.org/dc/terms/>
PREFIX xsd:<http://www.w3.org/2001/XMLSchema#>

DELETE WHERE {
    <https://usepa.3roundstones.net/usepa/app/purls/company-rewrite>
        calli:copy "^[^\\?]+\\?id=.*$ /usepa/app/pipelines/company-data.xpl?results&id={id} Accept: application/rdf+xml".
};
INSERT {
    <https://usepa.3roundstones.net/usepa/app/purls/company-rewrite>
        calli:copy """^\\?id=.*$ /usepa/app/pipelines/company-data.xpl?results&id={id}
Accept: application/rdf+xml""";
        dc:modified "2016-06-08T14:36:36.286Z"^^xsd:dateTime.
}
WHERE {
};

Giving the error:

Triple 
/usepa/app/purls/company-rewrite
/rdf/2009/framework#copy
"^[^\?]+\?id=.*$ /usepa/app/pipelines/company-data.xpl?results&id={id} Accept: application/rdf+xml"^^</2001/XMLSchema#string> 
must match one of 
[
</usepa/app/purls/company-rewrite>
</rdf/2009/framework#copy>
"^[^\\?]+\\?id=.*$ /usepa/app/pipelines/company-data.xpl?results&id={id}\nAccept: application/rdf+xml"^^</2001/XMLSchema#string>
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant