简体   繁体   English

RuntimeException:Sikulix致命错误:loadlib:opencv_java342.dll不在任何libs文件夹中

[英]RuntimeException: Sikulix fatal error: loadlib: opencv_java342.dll not in any libs folder

Project structure (full project can be downloaded here ): 项目结构(完整项目可在此处下载): sikuli RuntimeException:Sikulix致命错误:loadlib:opencv_java342.dll不在任何libs文件夹中

Launcher.java class: Launcher.java类:

import org.sikuli.script.Pattern;

public class Launcher {
    public static void main(String[] args)
    {
        Pattern p1 = new Pattern(Launcher.class.getResource("sample.png"));
    }
}

build.gradle file: build.gradle文件:

plugins {
    id 'java'
}

group 'com.myproj'
version '1.0-SNAPSHOT'

sourceCompatibility = 1.8

repositories {
    mavenCentral()
    maven {
        url "http://oss.sonatype.org/content/groups/public"
    }
}

dependencies {
    testCompile group: 'junit', name: 'junit', version: '4.12'
    compile group: 'com.sikulix', name: 'sikulixapi', version: '1.1.4-SNAPSHOT'
}

Program throws following runtime error: 程序引发以下运行时错误:

loadlib: opencv_java342.dll not in any libs folder
Exception in thread "main" java.lang.ExceptionInInitializerError
    at org.sikuli.script.Pattern.<init>(Pattern.java:125)
    at Launcher.main(Launcher.java:7)
Caused by: java.lang.RuntimeException: Sikulix fatal error: loadlib: opencv_java342.dll not in any libs folder
    at org.sikuli.script.Sikulix.terminate(Sikulix.java:58)
    at org.sikuli.script.RunTime.terminate(RunTime.java:60)
    at org.sikuli.script.RunTime.libsLoad(RunTime.java:915)
    at org.sikuli.script.RunTime.loadLibrary(RunTime.java:1105)
    at org.sikuli.script.Finder2.<clinit>(Finder2.java:33)
    ... 2 more
Disconnected from the target VM, address: '127.0.0.1:9172', transport: 'socket'

Process finished with exit code 1

Interesting thing is that my code worked in the morning smoothly. 有趣的是,我的代码在早上顺利运行。 And when I got back home in the evening something went wrong. 当我晚上回到家时,出了点问题。 Can't run it anymore.. Thank you for any help! 不能再运行了。谢谢您的帮助!

What I've tried: 我试过的

  • reload sikulixapi package using Gradle from scratch 从头开始使用Gradle重新加载sikulixapi软件包
  • download 3.4.2 opencv and load it in runtime like suggested here 下载3.4.2 opencv并按此处建议的那样在运行时中加载它
  • add opencv_java342.dll directly to the project as described here 直接添加opencv_java342.dll以项目为描述这里
  • even tried to launch the project on different Windows machine to exclude environment issues - still fails 甚至尝试在其他Windows计算机上启动项目以排除环境问题-仍然失败

It happened, that there was a bug in the latest snapshot. 碰巧,最新快照中有一个错误。 Full conversation with developers can be found here . 与开发人员的完整对话可以在这里找到。

So, in this situation you have at least two options: 因此,在这种情况下,您至少有两个选择:

  1. Wait until developers fix the issue and introduce new snapshot. 等到开发人员解决此问题并引入新的快照。 Bugs/questions can be reported here . 错误/问题可以在这里报告。
  2. Tell gradle/maven to use previous stable version of sikulixapi library. 告诉gradle / maven使用sikulixapi库的先前稳定版本。 Full list of currently available snapshots can be found here . 当前可用快照的完整列表可以在此处找到。 Gradle example: 摇篮示例:

      dependencies { compile group: 'com.sikulix', name: 'sikulixapi', version: '1.1.4-20181214.081346-62' } 

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Java代码中使用的sikulix api在Linux上的opencv_java错误 - sikulix api used in java code has error with opencv_java on linux 'RunTime:loadLib:libopencv_java430.so(失败)可能依赖库丢失'错误,而在红色运行 sikuli 测试脚本有 7.6 - 'RunTime:loadLib: libopencv_java430.so (failed) probably dependent libs missing' error while running sikuli test script in Red had 7.6 出现致命错误java.lang.RuntimeException:无法启动活动 - Getting Error Fatal java.lang.RuntimeException: Unable to start activity Docker + Java + OpenCV,没有 opencv_java342 在 Z93F725Z44823D1C48B 中 - Docker + Java + OpenCV, no opencv_java342 in java.library.path 致命异常:AsyncTask#1 java.lang.RuntimeException:执行doInBackground()错误时发生错误 - FATAL EXCEPTION: AsyncTask #1 java.lang.RuntimeException: An error occurred while executing doInBackground() error 致命异常:主java.lang.RuntimeException: - FATAL EXCEPTION: Main java.lang.RuntimeException: Sikuli中的“致命错误”,libs dir不在系统路径上 - “Fatal error” in Sikuli, libs dir is not on system path 致命异常:AsyncTask#1:java.lang.RuntimeException:执行doInBackground()时发生错误 - FATAL EXCEPTION: AsyncTask #1:java.lang.RuntimeException: An error occured while executing doInBackground() 致命异常:main; 面向对象; JAVA中的RuntimeException - FATAL EXCEPTION: main ; OOP ; RuntimeException in JAVA Java RunTimeException和ClassNotFoundException错误 - Java RunTimeException and ClassNotFoundException Error
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM