Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
SADE
SADE
Commits
9d363eed
Commit
9d363eed
authored
Jan 15, 2020
by
Mathias Goebel
🎠
Browse files
make error msg more verbose
parent
a3d99dff
Changes
1
Hide whitespace changes
Inline
Side-by-side
modules/textgrid/connect.xqm
View file @
9d363eed
...
...
@@ -24,7 +24,7 @@ declare namespace xhtml="http://www.w3.org/1999/xhtml";
: @param $uri – a textgrid uri
: @param $sid – a valid sessionId for TextGrid
: :)
declare function tgconnect:publish( $uri as xs:string, $sid as xs:string )
declare function tgconnect:publish( $uri as xs:string, $sid as xs:string )
{
tgconnect:publish
(
...
...
@@ -120,7 +120,7 @@ declare function tgconnect:publish( $uri as xs:string,
let $data :=
try { tgclient:getData($pubUri, $tgcrudUrl, $sid) }
catch * { error( QName("https://sade.textgrid.de/ns/error", "PUBLISH03"),
"getData failed with " || $err:code || ": " || $err:description
"getData failed
for " || $pubUri || "
with " || $err:code || ": " || $err:description
|| "Is your file conform to XML standard?") }
let $name := (: JING requires :)
if($data/*/namespace-uri() = "http://relaxng.org/ns/structure/1.0")
...
...
@@ -129,7 +129,7 @@ declare function tgconnect:publish( $uri as xs:string,
let $store :=
try { xmldb:store($targetPath||"/data", $name, $data, "text/xml") }
catch * { error( QName("https://sade.textgrid.de/ns/error", "PUBLISH04"),
"storing the data failed with " || $err:code || ": " || $err:description
"storing the data
for "|| $name ||"
failed with " || $err:code || ": " || $err:description
|| "Is your file conform to XML standard? Typical mistakes are empty xml:id attributes.") }
let $render := (: this is where you can start with prerendering.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment