-
Notifications
You must be signed in to change notification settings - Fork 393
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
Further explain xml syntax change for 3.6.0 #725
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR :)
docs/scenarios/actions.rst
Outdated
@@ -125,6 +125,9 @@ The following example is used to: | |||
</action> | |||
</recv> | |||
|
|||
.. note:: | |||
Release 3.6.0 added XML syntax checks and the characters & and < are | |||
not valid in XML files. Replace those with & < in strings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would say:
Release 3.6.0 added rudimentary XML syntax checks. Now the &
and < characters must be escaped even inside attribute values.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we explain how to escape them? Again I expect a lot of people to trip over this and many of them are not programmers and may have only ever used XML with SIPp. e.g. my entire SVT test organization.
Release 3.6.0 added rudimentary XML syntax checks. Now the &
and < characters must be escaped (& <) even inside attribute values.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can. How about:
Release 3.6.0 added rudimentary XML syntax checks. Now the & and <
characters must be escaped as & and < even inside attribute values.
docs/scenarios/variables.rst
Outdated
|
||
.. note:: | ||
Release 3.6.0 added XML syntax checks and the characters & and < are | ||
not valid in XML files. Replace those with & < in strings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
src/scenario.cpp
Outdated
@@ -1026,7 +1026,7 @@ scenario::scenario(char * filename, int deflt) | |||
/* Close scenario element */ | |||
xp_close_element(); | |||
if (xp_is_invalid()) { | |||
ERROR("Invalid XML in scenario"); | |||
ERROR("Invalid XML in scenario. Check for & and < in strings; replace with & <"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe:
Invalid XML in scenario. See: https://github.com/SIPp/sipp/issues/414
Because there could certainly be other reasons than unescaped lt and amp.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here's a commit/branch that adds line numbers in some cases:
It's not pretty, but it's fairly non-intrusive.
Please check it this meets your needs.
Looks good. Can you squash these changes? |
c30132f
to
78bb63e
Compare
I fixed that. Sorry about all the noise. I was editing the docs directly in github and they make a commit for each file edit. |
Thanks! |
Suggested and reviewed by Michael Stovenour (@mstovenour). Closes: #721 (along with #725)
Suggested and reviewed by Michael Stovenour (@mstovenour). Closes: #721 (along with #725)
No description provided.