XProc 3.0 transformation

Having trouble installing <oXygen/>? Got a bug to report? Post it all here.
daliboris
Posts: 22
Joined: Thu Feb 11, 2010 5:00 pm

XProc 3.0 transformation

Post by daliboris » Sat Apr 03, 2021 9:33 pm

Hello,

I'm trying to create a custom framework for XProc 3.0 before the official one will be available.

I'm using oXygen 23 and Morgana XProc IIIse on Windows 10.

I have a problem with transformation. I set custom XProc Engine this way up:
Name: MorganaXProc-IIIse
Working Directory: D:\Programy\XML\Morgana
Command line: D:\Programy\XML\Morgana\Morgana.bat ${xproc}

Later in my Framework, I use these settings for my default Transformation scenario:
XProc URL: ${currentFileURL}
Processor: MorganaXProc-IIIse

Unfortunately, each time I run the XProc transformation scenario, it ends with an "Access denied." error:

System ID: D:\Data\Dropbox\RIDICS\Prace\2020\BiblOl\XProc\Directory-processing.xpl
Scenario: XProc 3.0 (Saxon 10)
XProc file: D:\Data\Dropbox\RIDICS\Prace\2020\BiblOl\XProc\Directory-processing.xpl
Document type: XProc 3.0
Engine name: MorganaXProc-IIIse
Severity: warning
Description: Access denied

What am I doing wrong? Is there any way to run XProc 3.0 transformation from oXygen's IDE?

Thank you for your support.

Mircea
Posts: 90
Joined: Tue Mar 25, 2003 11:21 am

Re: XProc 3.0 transformation

Post by Mircea » Mon Apr 05, 2021 11:08 am

Hello,

It seems that the place where you are writing the result is not allowing it.
Please check the writing rights on the result paths.

Regards,
Mircea.
Mircea Enachescu
<oXygen> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com

daliboris
Posts: 22
Joined: Thu Feb 11, 2010 5:00 pm

Re: XProc 3.0 transformation

Post by daliboris » Wed Apr 07, 2021 6:58 pm

Hi Mircea,

of course I checked it.

I'm calling the same Morgana's BAT file from Windows' CMD (without administrator privileges) and it works OK.

Maybe there are some other parameters within settings in oXygen where I left some values, which generates non existing path (which is then denied).

Can I check what exactly is oXygen calling/produced when I hit transformation scenarion button? Information window is not usefull in this case:

Code: Select all

[ 17:54:33] - XPROC Transformation 'XProc 3.0' started
[ 17:54:33] - XPROC Transformation 'XProc 3.0' ended in 0.0 seconds
Best,

Boris

Mircea
Posts: 90
Joined: Tue Mar 25, 2003 11:21 am

Re: XProc 3.0 transformation

Post by Mircea » Fri Apr 09, 2021 11:28 am

Hi Boris,

Unfortunatelly we cannot reproduce the problem. We do not have an adaptor that works with Morgana 3.
Do you have an Morgana XProc 3.0 adaptor for Oxygen ? Can you point us to it so we can give it a try ?
Most probably the problem is from the adaptor, since we only provide an API to be implemented by the connector.

Regarding to other XProc 3.0 processor, we do not have one right now, since we provide suport only for Calabash. As soon as Calabash will add suport for it, we will also have it.

Regards,
Mircea.
Mircea Enachescu
<oXygen> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com

daliboris
Posts: 22
Joined: Thu Feb 11, 2010 5:00 pm

Re: XProc 3.0 transformation

Post by daliboris » Fri Apr 09, 2021 11:58 am

Thank you, Mircea.

That's the point. Morgana XProc 3.0 has no adaptor yet. I was just trying to run bat command with some parameters.

Which transformation scenario can I use to do this? My guess is ANT. Am I right?

Regards,

Boris

Mircea
Posts: 90
Joined: Tue Mar 25, 2003 11:21 am

Re: XProc 3.0 transformation

Post by Mircea » Fri Apr 09, 2021 12:54 pm

Hello Boris,

You can either configure Morgana as an external tool (from Tools/External Tools, and pass the ${cf} argument which provides the path of the current selected file), or if you create a proper Ant Build file, you can create an Ant Transformation Scenario.

Regards,
Mircea.
Mircea Enachescu
<oXygen> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com

daliboris
Posts: 22
Joined: Thu Feb 11, 2010 5:00 pm

Re: XProc 3.0 transformation

Post by daliboris » Sat Apr 10, 2021 5:40 pm

Hello Mircea,

thank you for your suggestions.

I tried set up an ANT transformation scenario.

Unfortunately I have problems to run it from oXygen IDE.

ANT build.xml file is part of my XProc 3.0 framework. It looks like this

Code: Select all

<project basedir="." name="xproc" default="run">
  <target name="run">
      <echo>Running: ${xpf}</echo>
  <exec executable="cmd.exe">
    <arg value="/c"/>
    <arg value="D:\Programy\XML\Morgana\Morgana.bat"/>
    <arg value="${xpf}"/>
    <arg value="-xslt-connector=saxon10"/>
  </exec>
</target>
</project>
$xpf is an input variable: path to the XProc 3.0 file.

When I run it from oXygen, results looks like this

Code: Select all

Executing:
"c:\program files\oxygen xml editor\23\jre/bin/java" -Dfile.encoding=UTF-8 -Xmx512m -Djava.awt.headless=true -classpath "C:\Program Files\Oxygen XML Editor\23\tools\ant/lib/ant-launcher.jar" "-Dant.home=C:\Program Files\Oxygen XML Editor\23\tools\ant" org.apache.tools.ant.launch.Launcher -f "D:/Data/Dropbox/Nastaveni/oXygen/Frameworks/xproc/ant/build.xml" "-Dxpf=D:\Data\Dropbox\RIDICS\Prace\2020\BiblOl\XProc\Directory-processing.xpl" "-Dwebhelp.trial.license=no"

Buildfile: D:\Data\Dropbox\Nastaveni\oXygen\Frameworks\xproc\ant\build.xml

run:
     [echo] Running: D:\Data\Dropbox\RIDICS\Prace\2020\BiblOl\XProc\Directory-processing.xpl
     [exec] [quasar] ERROR: java/lang/Object
     [exec] java.lang.IllegalArgumentException
     [exec] 	at co.paralleluniverse.asm.ClassReader.<init>(Unknown Source)
     [exec] 	at co.paralleluniverse.asm.ClassReader.<init>(Unknown Source)
    .......
     [exec] 	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
     [exec] 	at com.xml_project.morganaxproc3.XProcEngine.<clinit>(Unknown Source)

The process finished with exit code: 1
When I run the same command from command line the result is successful:

Code: Select all

D:\Programy>"c:\program files\oxygen xml editor\23\jre/bin/java" -Dfile.encoding=UTF-8 -Xmx512m -Djava.awt.headless=true -classpath "C:\Program Files\Oxygen XML Editor\23\tools\ant/lib/ant-launcher.jar" "-Dant.home=C:\Program Files\Oxygen XML Editor\23\tools\ant" org.apache.tools.ant.launch.Launcher -f "D:/Data/Dropbox/Nastaveni/oXygen/Frameworks/xproc/ant/build.xml" "-Dxpf=D:\Data\Dropbox\RIDICS\Prace\2020\BiblOl\XProc\Directory-processing.xpl" "-Dwebhelp.trial.license=no"
Buildfile: D:\Data\Dropbox\Nastaveni\oXygen\Frameworks\xproc\ant\build.xml

run:
     [echo] Running: D:\Data\Dropbox\RIDICS\Prace\2020\BiblOl\XProc\Directory-processing.xpl
     [exec] =================================
     [exec] MorganaXProc-IIIse 0.9.5.5-beta
     [exec] Copyright 2011-2021 by <xml-project /> Achim Berndzen
     [exec] =================================
     [exec]
     [exec] [16:15:16.349] Group editions
     ....
     BUILD SUCCESSFUL
Total time: 6 seconds
What am I doing wrong? Where can be differences between running ANT from the oXygen IDE and from the Windows command line?

Regards,

Boris

Mircea
Posts: 90
Joined: Tue Mar 25, 2003 11:21 am

Re: XProc 3.0 transformation

Post by Mircea » Tue Apr 13, 2021 11:55 am

Hello Boris,

We tested an XProc transformation using the build file you provided with a local Morgana copy.
We cannot reproduce the problem you encountered.
This means that we need more complex testing environment from you, i.e. a sample XProc file.
Please send it on our email address: support [at] oxygenxml.com

Regards,
Mircea.
Mircea Enachescu
<oXygen> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com

Post Reply