Project

Profile

Help

Bug #2392

closed

java.lang.RuntimeException: Cannot instantiate a Configuration

Added by O'Neil Delpratt almost 9 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Category:
.NET API
Sprint/Milestone:
Start date:
2015-06-06
Due date:
% Done:

100%

Estimated time:
Legacy ID:
Applies to branch:
9.6
Fix Committed on Branch:
9.6
Fixed in Maintenance Release:
Platforms:

Description

Reported by user:

On 9.6.0.6 .Net, the following snippet does not work:

       Processor proc;

       using( FileStream cfgstream = File.OpenRead("p:\\config.xml")) {

           proc = new Processor( cfgstream );

       }

Unhandled Exception: java.lang.RuntimeException: Cannot instantiate a Configuration ---> java.lang.NullPointerException

  at java.lang.Class.newInstance0(CallerID )

  at java.lang.Class.newInstance(CallerID )

  at net.sf.saxon.Configuration.newConfiguration()

  --- End of inner exception stack trace ---

  at net.sf.saxon.Configuration.newConfiguration()

  at net.sf.saxon.Configuration.readConfiguration(Source source)

  at Saxon.Api.Processor..ctor(Stream configurationFile)

Something has changed on 9.6.0.6?

It used to work on 9.6.0.5 .Net.


Related issues

Related to Saxon - Bug #2111: setConfigurationProperty prevents propagation of ModuleURIResolverClosedMichael Kay2014-07-23

Actions
Actions #1

Updated by T Hata almost 9 years ago

Even new Processor(true) didn't work.

Actions #2

Updated by O'Neil Delpratt almost 9 years ago

  • Related to Bug #2111: setConfigurationProperty prevents propagation of ModuleURIResolver added
Actions #3

Updated by O'Neil Delpratt almost 9 years ago

  • Status changed from New to In Progress

This bug issue is related to #2111. It seems to be causing a regression in the 9.6.0.6 maintenance release.

Actions #4

Updated by O'Neil Delpratt almost 9 years ago

  • Category set to .NET API
  • Status changed from In Progress to Resolved
  • % Done changed from 0 to 100
  • Fixed in version set to 9.6.0.6

This bug has been fixed and committed to subversion. The fix only applies to .NET and is critical therefore it has been included in the recent Saxon 9.6.0.6 maintenance release.

The problem was the call on the Verifier class was made too early in the configuration. This only affects the DotNet code. The fix was made in the EnterpriseConfiguration and ProfessionalConfiguration classes.

Actions #5

Updated by O'Neil Delpratt almost 9 years ago

The fix applied in comment #4 to the class EnterpriseConfiguration breaks the build96 because there are references to dotnet class files.

Fix: I have added some preprocessor directives to the classes EnterpriseConfiguration and ProfessionalConfiguration to avoid this problem.

Actions #6

Updated by O'Neil Delpratt over 8 years ago

  • Status changed from Resolved to Closed
  • Fixed in version changed from 9.6.0.6 to 9.6.0.7

Bug fix applied in the Saxon 9.6.0.7 maintenance release.

Actions #7

Updated by O'Neil Delpratt over 8 years ago

  • Applies to branch 9.6 added
  • Fix Committed on Branch 9.6 added
  • Fixed in Maintenance Release 9.6.0.7 added
Actions #8

Updated by O'Neil Delpratt over 8 years ago

  • Sprint/Milestone set to 9.6.0.7

Please register to edit this issue

Also available in: Atom PDF