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

Cant assume Saxon script found is from EXPath #49

Open
GoogleCodeExporter opened this issue Jun 8, 2015 · 4 comments
Open

Cant assume Saxon script found is from EXPath #49

GoogleCodeExporter opened this issue Jun 8, 2015 · 4 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1.Run the 0.4.0rc1 on Fedora Core 16

What do you see instead?
Creating Test Stylesheet...
Command line option -x requires a value


What version of the product are you using? On what operating system?
0.4.0rc1 on Fedora Core 16 AMD64

Please provide any additional information below.
The problem is at line 56 of the xspec.sh script. You cannot assume that if you 
find an executable called 'saxon' then it is from the EXPath project. In the 
case of Fedora 16, there is a 'saxon' executable installed in /usr/bin which is 
Saxon8 and is installed by YUM as a system package.

Cheers Adam.

Original issue reported on code.google.com by [email protected] on 14 May 2012 at 11:25

@GoogleCodeExporter
Copy link
Author

True.  I am not sure how to solve this problem though.  We could call "saxon 
--help" and see whether it is the EXPath script or not.  If it is that's ok, 
but if it's not, there's a risk we launch Java (and actually run the Saxon main 
class) just to test that, before actually calling Saxon for the transform.  
Sounds like a bit expensive.

What about a script variable that one can switch on or off by editing the 
script by hand?  I'm not a fan of editing the script by hand, but I'm not sure 
we have the choice here...

What do you think?

Thanks for the bug report!

Original comment by fgeorges on 14 May 2012 at 2:03

  • Changed state: Accepted
  • Added labels: Milestone-Release0.4

@GoogleCodeExporter
Copy link
Author

I think you shouldnt have to Edit the script by hand. Simply XSpec should not 
have a direct dependency on EXPath. I would probably add a flag to the command 
line arguments for xspec.sh so that you can specify an EXPath installation path 
(if you have it installed)

e.g. xspec.sh --with-expath=/path/to/expath.

Original comment by [email protected] on 14 May 2012 at 5:30

@GoogleCodeExporter
Copy link
Author

I agree editing the script by hand is not ideal.  But providing it via an 
option is not neither.  This is really an install-time property (that has to be 
set once for ever) rather than a run-time property (that has to be provided 
every time on the command line).

If there are several existing scripts to call Saxon (on different systems), the 
user will have anyway to tell one way or another which one to use at 
install-time.  What's the interface of /usr/bin/saxon from YUM?

Original comment by fgeorges on 14 May 2012 at 5:58

@GoogleCodeExporter
Copy link
Author

Im sorry I disagree. XSpec is not part of EXPath, so very simply it should not 
have a direct dependency on it. Yes EXPath is great, but not everyone uses it, 
I suspect there are many more XSpec users than EXPath users ;-)

I think a cmd line arg for the optional EXPath support is perfect, and that if 
people want that every time they can simply alias the cmd with the arg. If this 
is properly documented then it is not an issue for anyone.

It is a worse user experience if it doesnt work out of the box, and people have 
to mess around with XSpec to get it working in its normal vanilla mode (e.g. 
without EXPath).

BTW - I also think that you should just ship the Saxon-PE Jar with EXPath, as 
getting that setup is also a pain, I have had to configure 3 peoples machines 
today that are trying to learn XSpec because they are beginners and couldnt 
figure it out.

Original comment by [email protected] on 14 May 2012 at 7:23

innovimax pushed a commit to innovimax/xspec that referenced this issue Jan 17, 2017
* remove -j option in tests for shell and batch scripts expath#39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant