Giter VIP home page Giter VIP logo

Comments (4)

RomanIakovlev avatar RomanIakovlev commented on June 18, 2024

Hi, thanks for reporting this! I'm not sure why Gradle behaves in such a way, but I'll try to reproduce it with build system other than sbt and see if it works.

from timeshape.

RomanIakovlev avatar RomanIakovlev commented on June 18, 2024

I've finally come around to check what's going on with this issue, and it seems I cannot reproduce it. I've created a new Gradle project (using Gradle 5.2.1), so that my build.gradle.kts file looks like this:

plugins {
    java
}

group = "net.iakovlev"
version = "1.0-SNAPSHOT"

repositories {
    mavenCentral()
}

dependencies {
    testCompile("junit", "junit", "4.12")
    compile("net.iakovlev", "timeshape", "2019b.7")
}

configure<JavaPluginConvention> {
    sourceCompatibility = JavaVersion.VERSION_1_8
}

And then in the main method I initialize Timeshape and make a call to it:

import net.iakovlev.timeshape.TimeZoneEngine;

import java.time.ZoneId;
import java.util.Optional;

public class Main {
    public static void main(String[] args) {
        TimeZoneEngine engine = TimeZoneEngine.initialize();
        final Optional<ZoneId> query = engine.query(51.12, 13.41);
        System.out.println(query);
    }
}

I ran it on Windows and Linux (WSL, Ubuntu Xenial), and it works in both cases. I see you have done it on Mac, so maybe there's something going on there, but I can't test on Mac easily.

I'd appreciate if you'd be able to have another look at the issue. Maybe it's caused by something else, not Timeshape configuration? It you still encounter this problem with Timeshape 2019b.7, it would be great to have a minimal reproducible build.

from timeshape.

ben-manes avatar ben-manes commented on June 18, 2024

Sorry, but I haven't thought much about this in almost a year. Going back to that commit, it seems that I was on Gradle 5.0. Can you check against that version to see if maybe Gradle added support as it seemed to be their issue?

When I run ./gradlew dependencies with and without my added dependency, the output looks identical.

Removing the addition and running the server, it seems to work nicely.

INFO  [2019-10-27 18:31:12,967] [net.iakovlev.timeshape.Index] Initialized index with 439 time zones

So I think this can be closed as won't fix as Gradle must have added support?

from timeshape.

RomanIakovlev avatar RomanIakovlev commented on June 18, 2024

Thanks a lot for your quick reply! I've tested on Gradle 5.0 as well, and it also worked with my simple example. Maybe some Heisenbug? Anyway, closing this issue now, and, if this happens again, please feel free to open another one.

from timeshape.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.