[Biojava-dev] Biojava with Java 8

Andreas Prlic andreas at sdsc.edu
Thu Jul 31 17:34:32 UTC 2014


.. and to add something I just noticed. Since we are in the process of
switching our project hosting to OSS Sonatype and Maven Central, our
current trunk builds are available from here at the moment:

https://oss.sonatype.org/content/repositories/snapshots/org/biojava/

A


On Wed, Jul 30, 2014 at 2:21 PM, Andreas Prlic <andreas at sdsc.edu> wrote:

> next version will be 4.0.0. There was some refactoring in the protein
> structure modules which require some minor API changes, hence the version
> increase
>
> A
>
>
>
>
>
> On Wed, Jul 30, 2014 at 2:15 PM, Terry Casstevens <tmc46 at cornell.edu>
> wrote:
>
>> Hi Andreas,
>>
>> Thank you very much!
>>
>> Which version 3.1.0 or 4.0.0 will be the next public release?  We are
>> hoping to update our biojava and forester libraries.  Which level do
>> you recommend we use?
>>
>> Thank you,
>>
>> Terry
>>
>>
>> On Wed, Jul 30, 2014 at 11:20 AM, Andreas Prlic <andreas at sdsc.edu> wrote:
>> > Hi Terry,
>> >
>> > Agreed, the fix is not windows specific. We have not set a release date
>> yet.
>> > However you don't need to wait for it. If you use maven you can switch
>> to
>> > our latest SNAPSHOT builds. Just add this to your project pom.xml
>> >
>> >   <dependencies>
>> >                 ...
>> >                 <dependency>
>> >                         <groupId>org.biojava</groupId>
>> >                         <artifactId>biojava3-core</artifactId>
>> >                         <version>4.0.0-SNAPSHOT</version>
>> >                 </dependency>
>> >                 <!-- other biojava jars as needed -->
>> >         </dependencies>
>> >       <repositories>
>> >               ...
>> >               <repository>
>> >                       <id>biojava-maven-repo</id>
>> >                       <name>BioJava repository</name>
>> >                       <url>http://www.biojava.org/download/maven/</url>
>> >               </repository>
>> >       </repositories>
>> >
>> > alternatively you could manually download the jar files from the
>> repository
>> > as well...
>> >
>> > Andreas
>> >
>> >
>> > On Wed, Jul 30, 2014 at 8:07 AM, Terry Casstevens <tmc46 at cornell.edu>
>> wrote:
>> >>
>> >> Hi Andreas,
>> >>
>> >> Thank you for your reply.  Looking at the github repository, it does
>> >> look like the last change to SimpleLocation will fix our problem.
>> >> Although, I don't think it's specific to Windows.  I think it's a
>> >> change in Java 8 (maybe with default methods on Interfaces).
>> >>
>> >> Your Location Interface creates an static instance of SimpleLocation
>> >> which ends up calling a SimpleLocation constructor that uses
>> >> EMPTY_LOCS.  And EMPTY_LOCS, a static variable in SimpleLocation,
>> >> doesn't seem to be initialized at that time.   The change to use new
>> >> ArrayList<Location>() instead of EMPTY_LOCS gets around that.
>> >>
>> >> Do you know when another release would be available?
>> >>
>> >> Thank you,
>> >>
>> >> Terry
>> >>
>> >>
>> >> On Tue, Jul 29, 2014 at 5:03 PM, Andreas Prlic <andreas at sdsc.edu>
>> wrote:
>> >> > Hi Terry,
>> >> >
>> >> > The NoClassDefFoundError sounds a bit more like a configuration
>> error,
>> >> > than
>> >> > a BioJava specific issue. Are you using the latest version of the
>> source
>> >> > from github? One of our students here submitted a few patches
>> recently
>> >> > that
>> >> > make the current trunk code work on Java 1.8 without problems (as
>> well
>> >> > as on
>> >> > windows). Might be easiest to get a checkout from there.
>> >> >
>> >> > https://github.com/biojava/biojava
>> >> >
>> >> > Having said that, there was a lot of change in the code since the
>> last
>> >> > release and we should probably think about preparing another release
>> >> > soon.
>> >> >
>> >> > Andreas
>> >> >
>> >> >
>> >> >
>> >> > On Tue, Jul 29, 2014 at 11:01 AM, Terry Casstevens <
>> tmc46 at cornell.edu>
>> >> > wrote:
>> >> >>
>> >> >> Dear Spencer,
>> >> >>
>> >> >> I would very much appreciate your help with this.  I think it will
>> >> >> effect your other users also.
>> >> >>
>> >> >> I am the software lead of the Buckler Lab at Cornell University, and
>> >> >> we use the biojava library in our software.
>> >> >>
>> >> >> I'm hoping to move to your latest released jars, but I don't think
>> >> >> this is specific to that version.
>> >> >> biojava3-alignment-3.0.8.jar
>> >> >> biojava3-phylo-3.0.8.jar
>> >> >> biojava3-core-3.0.8.jar
>> >> >>
>> >> >> We have everything working when compiling and running our code with
>> >> >> Java
>> >> >> 7.
>> >> >>
>> >> >> But when running with Java 8 (compiling with Java 7 or Java 8), we
>> are
>> >> >> getting NoClassDefFoundError.
>> >> >>
>> >> >>
>> >> >> This will show you the problem.  Compile this with Java 7, and run
>> it
>> >> >> under Java 7 and Java 8.  You will see that it works in Java 7 and
>> not
>> >> >> in Java 8.
>> >> >>
>> >> >> public static void main(String[] args) {
>> >> >>         SimpleLocation location = new SimpleLocation(1, 7);
>> >> >> }
>> >> >>
>> >> >>
>> >> >> I believe your problem is in
>> >> >> org.biojava3.core.sequence.location.template.Location.  This line is
>> >> >> causing the problem in Java 8.
>> >> >>
>> >> >> public static final Location EMPTY =
>> >> >>             new SimpleLocation(Integer.MIN_VALUE, Integer.MAX_VALUE,
>> >> >> Strand.UNDEFINED);
>> >> >>
>> >> >>
>> >> >>
>> >> >> Best,
>> >> >>
>> >> >> Terry
>> >> >> _______________________________________________
>> >> >> biojava-dev mailing list
>> >> >> biojava-dev at mailman.open-bio.org
>> >> >> http://mailman.open-bio.org/mailman/listinfo/biojava-dev
>> >> >
>> >> >
>> >> >
>> >> >
>> >
>> >
>> >
>> >
>>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.open-bio.org/pipermail/biojava-dev/attachments/20140731/ac5b333c/attachment.html>


More information about the biojava-dev mailing list