我试图用robolectric测试我的代码。问题是它有重复的引用。例如
java.lang.RuntimeException: java.lang.RuntimeException: Duplicate class org.apache.maven.artifact.Artifact found in modules maven-ant-tasks-2.1.3.jar (org.apache.maven:maven-ant-tasks:2.1.3) and maven-artifact-2.2.1.jar (org.apache.maven:maven-artifact:2.2.1)
Run Code Online (Sandbox Code Playgroud)
我使用了Gradel工件app:dependencies来获得以下报告。这里是重要的部分:
+--- org.robolectric:robolectric:4.3
| +--- org.robolectric:annotations:4.3
| +--- org.robolectric:junit:4.3
| | +--- org.robolectric:annotations:4.3
| | +--- org.robolectric:sandbox:4.3
| | | +--- org.robolectric:annotations:4.3
| | | +--- org.robolectric:utils:4.3
| | | | +--- org.robolectric:annotations:4.3
| | | | +--- org.robolectric:pluginapi:4.3
| | | | | +--- org.robolectric:annotations:4.3
| | | | | +--- org.apache.ant:ant:1.8.0
| | | | | | \--- org.apache.ant:ant-launcher:1.8.0
| | | …Run Code Online (Sandbox Code Playgroud) 最近我有时会使用 VS Code 和 IntelliJ。推荐扩展的 VS Code 功能非常适合项目的初始设置。
JetBrains 生态系统中是否有等效的插件?
目前我正在使用开源工具 ffmpeg / ffserver 建立一个屏幕共享平台。分享之初一切都很好。大约 1 1/2 分钟后,我在输出中得到以下异常。
[flv @ 0x3a47aa0] rc buffer underflow
[flv @ 0x3a47aa0] max bitrate possibly too small or try trellis with large lmax or increase qmax
我尝试设置非常高的 lmax 和 qmax,但这并没有改变任何事情。此外,我尝试增加比特率、缓冲区大小和比特率。
我在 ffmpeg 中使用以下命令:
ffmpeg -f x11grab -s 1920x1080 -r 20 -i :0.0+1680,0 "http://localserver.de:8080/input1.ffm"
Run Code Online (Sandbox Code Playgroud)
ffserver 的配置文件是:
HTTPPort 8080
HTTPBindAddress 0.0.0.0
MaxHTTPConnections 2000
MaxClients 1000
MaxBandwidth 50000
CustomLog -
<Feed input1.ffm>
File /var/ffserver/input1.ffm
FileMaxSize 20M
ACL allow *FROM IP* *TO IP*
</Feed>
<Stream screen1.swf>
Feed input1.ffm
Format …Run Code Online (Sandbox Code Playgroud)