Git Product home page Git Product logo

mirai-setu's Introduction

正在重生中。。。。。。。。。。

mirai-setu

一个使用loliconAPImirai-console 的色图插件

声明

本插件为开发学习用, 请勿用于非法用途。部分搜索的图片可能会引发不适, 甚至导致账号封禁以及群封禁, 请谨慎使用。作者本人不承担任何责任。

本插件遵循mirai软件AGPLv3协议开源, 不参与一切商业活动。

由于作者学业压力较大, 不能保证插件的及时更新以及bug修复。

使用说明

  1. 环境配置
    • 插件兼容mirai-console2.0及以上版本。
    • mirai-console需要java环境, 建议使用java11以及以上的版本运行。
  2. 插件下载
    • 前往本项目的releases 下载插件
  3. 插件运行
    • 将本放入mirai-console的plugins的文件夹然后运行mirai-console。
  4. 关于lollicon的注意事项

    lolicon是一个公开的setu库的APi, 此API不属于本人, 如果此API出现问题, 恕我无力解决。图片获取是从i.pixiv.cat反向代理得到的, 可以不使用科学上网获取, 但是国内网络获取比较慢, 获取卡顿和失败是正常情况。如果有条件的话可以使用科学上网进行加速, 或者部署到没有限制的服务器上。
    • lolicon的APIKEy申请需要到Telegram上申请, 需要使用科学上网, 请自备工具。

注意事项

1.插件更新版本之后配置文件不会出现新的配置信息, 请删除配置文件让插件重新生成即可。

2.已知在使用缩略图(默认方法)发送图片的时候, 图片在pc端无法显示, 而且手机端无法直接转发图片, 修改为发送原图可以解决此问题。

3.图片发送模式群主和管理员以及bot管理员(在配置文件中可以增加)都可以使用指令修改。

指令

指令可以参考指令配置文件, 指令可以在配置文件进行修改, 表格只是默认命令, 可以自行修改命令

指令 功能
色图时间/涩图时间/色图来/涩图来 从lolicon随机获取一张setu
搜色图/搜涩图 <关键词> 根据关键词搜索一张setu
关闭插件/封印 关闭此群的涩图插件服务
青少年模式/普通模式 开启此群插件并切换为普通模式, 普通模式发送普通的setu(以不漏点为标准)
青壮年模式/R-18模式 开启此群插件并切换为R-18模式, R-18模式发送R-18的setu(被举报极易封号, 慎重使用)
混合模式 开启此群插件并切换为混合模式, 可能获取普通setu和R-18setu
以图搜图 SauceNAO搜图

指令授权教程

使用权限模式3,采用mirai-console官方提供的授权方法 。 (不区分大小写. 不区分 Bot).

被许可人类型 字符串表示示例 备注
控制台 console
任意其他客户端 client* 即 Bot 自己发消息给自己
精确群 g123456 表示群, 而不表示群成员
精确好友 f123456 必须通过好友消息
精确群临时会话 t123456.789 群 123456 内的成员 789. 必须通过临时会话
精确群成员 m123456.789 群 123456 内的成员 789. 同时包含临时会话
精确用户 u123456 同时包含群成员, 好友, 临时会话
任意群 g* g 意为 group
任意群的任意群员 m* m 意为 member
精确群的任意群员 m123456.* 群 123456 内的任意成员. 同时包含临时会话
任意临时会话 t* t 意为 temp. 必须通过临时会话
精确群的任意临时会话 t123456.* 群 123456 内的任意成员. 必须通过临时会话
任意好友 f* f 意为 friend
任意用户 u* u 意为 user. 任何人在任何环境
任意陌生人 s* s 意为 stranger. 任何人在任何环境
任意联系对象 * 即任何人, 任何群. 不包括控制台

配置文件

配置文件可以配置代理一些配置, 请参考配置文件注释

未来计划

  • 适配SauceNAO搜图的功能

    • pixiv适配
  • 适配ascii2d搜图功能

  • 提供图片缓存到本地的功能

  • 提供GUI界面修改配置的功能

  • 绕过sni审查实现直连pixiv 有什么新奇的想法和建议也可以在issue留言给我

鸣谢

感谢Mirai团队

感谢lolicon提供的图片库

感谢fantasyzone提供的图片库

感谢 利姆露酱 提供的帮助

mirai-setu's People

Contributors

crt106 avatar rimuruchan avatar ruabbit0 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mirai-setu's Issues

适配lolicon v2,多tag搜索方案提议

将会适配lolicon v2的API,根据新增加的功能增加多tag搜索方案

搜涩图 萝莉 白丝 或者 搜涩图 萝莉&白丝
搜索同时包含萝莉和白丝的tag的图片

搜色图 萝莉|白丝
搜索包含萝莉或者白丝的tag的图片

希望可以增加十连等操作

1.即发送 “图图十连”/“图图x10” bot逐次返回十张图片。
2.希望可以让bot仅回复图片

如果没时间可以暂时放弃

增加定时开关功能

如题,有时候群友们一看起色图来就停不下来了,影响到正常聊天了,有群友建议增加一个指定某个群在某个时间段内使用的功能

搜色图关键词屏蔽

希望能添加一个针对搜色图的关键词屏蔽,某些词比如"搜色图 全裸"容易出现r18图片。

用户可以通过配置文件自行添加关键词来禁止相关搜索,并添加机器人的相应回复。

请问为什么我用mcl加载这个插件总会报错啊

2021-02-24 18:29:46 E/Mirai-setu: net.mamoe.yamlkt.YamlDecodingException: There must be a COLON between class key and value but found STRING for 'setu-config' masterid: 0 ^ at line 2, column 10 net.mamoe.yamlkt.YamlDecodingException: There must be a COLON between class key and value but found STRING for 'setu-config' masterid: 0 ^ at line 2, column 10 at net.mamoe.yamlkt.internal.YamlUtils__ContextualExceptionKt.contextualDecodingException(ContextualException.kt:154) at net.mamoe.yamlkt.internal.YamlUtils.contextualDecodingException(Unknown Source) at net.mamoe.yamlkt.internal.YamlUtils__ContextualExceptionKt.contextualDecodingException$default(ContextualException.kt:128) at net.mamoe.yamlkt.internal.YamlUtils.contextualDecodingException$default(Unknown Source) at net.mamoe.yamlkt.internal.YamlDecoder$BlockClassDecoder.decodeElementIndex(YamlDecoder.kt:279) at net.mamoe.mirai.console.internal.data.PluginDataImpl$updaterSerializer$1.deserialize(PluginDataImpl.kt:75) at net.mamoe.mirai.console.internal.data.PluginDataImpl$updaterSerializer$1.deserialize(PluginDataImpl.kt:47) at net.mamoe.yamlkt.Yaml.decodeFromString(Yaml.kt:151) at net.mamoe.mirai.console.internal.data.MultiFilePluginDataStorageImpl.load(MultiFilePluginDataStorageImpl.kt:39) at net.mamoe.mirai.console.plugin.jvm.AbstractJvmPlugin.reloadPluginConfig(AbstractJvmPlugin.kt:58) at com.blrabbit.mirai.MiraiSetuMain.onEnable(MiraiSetuMain.kt:45) at net.mamoe.mirai.console.internal.plugin.JvmPluginInternal.internalOnEnable$mirai_console(JvmPluginInternal.kt:113) at net.mamoe.mirai.console.internal.plugin.BuiltInJvmPluginLoaderImpl.enable(BuiltInJvmPluginLoaderImpl.kt:119) at net.mamoe.mirai.console.plugin.jvm.JvmPluginLoader$BuiltIn.enable(JvmPluginLoader.kt) at net.mamoe.mirai.console.plugin.jvm.JvmPluginLoader$BuiltIn.enable(JvmPluginLoader.kt:36) at net.mamoe.mirai.console.plugin.PluginManager.enablePlugin(PluginManager.kt:129) at net.mamoe.mirai.console.internal.plugin.PluginManagerImpl.enableAllLoadedPlugins$mirai_console(PluginManagerImpl.kt:172) at net.mamoe.mirai.console.internal.MiraiConsoleImplementationBridge.doStart$mirai_console(MiraiConsoleImplementationBridge.kt:202) at net.mamoe.mirai.console.MiraiConsoleImplementation$Companion.start(MiraiConsoleImplementation.kt:209) at net.mamoe.mirai.console.terminal.MiraiConsoleTerminalLoader.startAsDaemon(MiraiConsoleTerminalLoader.kt:153) at net.mamoe.mirai.console.terminal.MiraiConsoleTerminalLoader.startAsDaemon$default(MiraiConsoleTerminalLoader.kt:152) at net.mamoe.mirai.console.terminal.MiraiConsoleTerminalLoader.main(MiraiConsoleTerminalLoader.kt:48) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.base/java.lang.reflect.Method.invoke(Unknown Source) at org.itxtech.mcl.Utility.bootMirai(Utility.java:76) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.base/java.lang.reflect.Method.invoke(Unknown Source) at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:138) at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:226) at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:1692) at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:1013) at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:109) at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:412) at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3578) at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:107) at org.mozilla.javascript.ArrowFunction.call(ArrowFunction.java:43) at org.mozilla.javascript.InterfaceAdapter.invokeImpl(InterfaceAdapter.java:155) at org.mozilla.javascript.InterfaceAdapter.lambda$invoke$0(InterfaceAdapter.java:105) at org.mozilla.javascript.Context.call(Context.java:554) at org.mozilla.javascript.ContextFactory.call(ContextFactory.java:522) at org.mozilla.javascript.InterfaceAdapter.invoke(InterfaceAdapter.java:105) at org.mozilla.javascript.jdk18.VMBridge_jdk18$1.invoke(VMBridge_jdk18.java:126) at com.sun.proxy.$Proxy4.run(Unknown Source) at org.itxtech.mcl.script.ScriptManager.phaseBoot(ScriptManager.java:101) at org.itxtech.mcl.Loader.start(Loader.java:129) at org.itxtech.mcl.Loader.main(Loader.java:53)
环境是mcl1.0.5,32位jre11,安装了Onebot和mirai native

增加发送冷却时间

应群友的建议考虑增加冷却时间,发送一张图片之后等待一段时间之后再发送。

PCQQ图片接收不到

这次的0.2.3版本使用后我发现PCQQ收不到图片了,上一个版本还行,发图的速度是快了不少真不错
image
mirai使用的版本为2.4.0,希望能修复一下

涩图功能无法正常使用

E/Mirai-setu: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:128)
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:308)
at java.base/sun.security.ssl.Alert$AlertConsumer.consume(Alert.java:279)
at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:181)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:164)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1152)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1063)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:402)
at okhttp3.internal.connection.RealConnection.connectTls(RealConnection.kt:367)
at okhttp3.internal.connection.RealConnection.establishProtocol(RealConnection.kt:325)
at okhttp3.internal.connection.RealConnection.connect(RealConnection.kt:197)
at okhttp3.internal.connection.ExchangeFinder.findConnection(ExchangeFinder.kt:249)
at okhttp3.internal.connection.ExchangeFinder.findHealthyConnection(ExchangeFinder.kt:108)
at okhttp3.internal.connection.ExchangeFinder.find(ExchangeFinder.kt:76)
at okhttp3.internal.connection.RealCall.initExchange$okhttp(RealCall.kt:245)
at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.kt:32)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.kt:82)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.kt:83)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.kt:76)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.connection.RealCall.getResponseWithInterceptorChain$okhttp(RealCall.kt:197)
at okhttp3.internal.connection.RealCall$AsyncCall.run(RealCall.kt:502)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)

2021-01-15 15:45:51 V/Bot.3077186705: [SCP基金会(914156063)] coderwu(1340701723) -> [mirai:source:[1160],[1607710078]]???
2021-01-15 15:45:53 V/Bot.3077186705: [SCP基金会(914156063)] Do vis(2390218955) -> [mirai:source:[1161],[428605271]][mirai:image:{62677F00-D061-7C3B-42DA-814D2CEE033C}.gif]
2021-01-15 15:45:58 V/Bot.3077186705: [SCP基金会(914156063)] 忆梦(1743311657) -> [mirai:source:[1162],[1283430323]][mirai:image:{6728712E-15CA-111B-E17D-4A82A1A55669}.gif]
2021-01-15 15:47:19 V/Bot.3077186705: [SCP基金会(914156063)] coderwu(1340701723) -> [mirai:source:[1163],[2057081375]]搜涩图 四宫辉夜
2021-01-15 15:47:22 I/Mirai-setu: 剩余调用次数 264
2021-01-15 15:47:22 V/Bot.3077186705: Group(914156063) <- pid:82434269\ntitle: Kaguya sama\nauthor: MarineSnow\nurl: https://i.pixiv.cat/img-original/img/2020/06/20/01/26/13/82434269_p0.png\ntags: [かぐや様は告らせたい, 辉夜大小姐想让我告白天才们的恋爱头脑战, 四宮かぐや, 四宫辉夜, かぐや様, 水着, 泳装, 女の子, 女孩子, 海, sea, おっぱい, 欧派, おへそ, 肚脐, 赤ビキニ, 红色比基尼]
2021-01-15 15:47:23 V/Bot.3077186705: Group(914156063) <- Received fatal alert: handshake_failure
2021-01-15 15:47:23 E/Mirai-setu: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:128)
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:308)
at java.base/sun.security.ssl.Alert$AlertConsumer.consume(Alert.java:279)
at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:181)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:164)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1152)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1063)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:402)
at okhttp3.internal.connection.RealConnection.connectTls(RealConnection.kt:367)
at okhttp3.internal.connection.RealConnection.establishProtocol(RealConnection.kt:325)
at okhttp3.internal.connection.RealConnection.connect(RealConnection.kt:197)
at okhttp3.internal.connection.ExchangeFinder.findConnection(ExchangeFinder.kt:249)
at okhttp3.internal.connection.ExchangeFinder.findHealthyConnection(ExchangeFinder.kt:108)
at okhttp3.internal.connection.ExchangeFinder.find(ExchangeFinder.kt:76)
at okhttp3.internal.connection.RealCall.initExchange$okhttp(RealCall.kt:245)
at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.kt:32)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.kt:82)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.kt:83)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.kt:76)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.connection.RealCall.getResponseWithInterceptorChain$okhttp(RealCall.kt:197)
at okhttp3.internal.connection.RealCall$AsyncCall.run(RealCall.kt:502)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)

stream was reset: PROTOCOL_ERROR

图片发不出来,返回的是stream was reset: PROTOCOL_ERROR
机器人登录的协议是ANDROID_PAD,是不是这样不支持发图

报错,但是我也不知道为什么

2021-05-22 08:38:35 E/main: Exception in coroutine
javax.net.ssl.SSLHandshakeException: Remote host terminated the handshake
at java.base/sun.security.ssl.SSLSocketImpl.handleEOF(SSLSocketImpl.java:1598)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1426)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1324)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:440)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:411)
at okhttp3.internal.connection.RealConnection.connectTls(RealConnection.kt:367)
at okhttp3.internal.connection.RealConnection.establishProtocol(RealConnection.kt:325)
at okhttp3.internal.connection.RealConnection.connect(RealConnection.kt:197)
at okhttp3.internal.connection.ExchangeFinder.findConnection(ExchangeFinder.kt:249)
at okhttp3.internal.connection.ExchangeFinder.findHealthyConnection(ExchangeFinder.kt:108)
at okhttp3.internal.connection.ExchangeFinder.find(ExchangeFinder.kt:76)
at okhttp3.internal.connection.RealCall.initExchange$okhttp(RealCall.kt:245)
at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.kt:32)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.kt:82)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.kt:83)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.kt:76)
at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.kt:100)
at okhttp3.internal.connection.RealCall.getResponseWithInterceptorChain$okhttp(RealCall.kt:197)
at okhttp3.internal.connection.RealCall$AsyncCall.run(RealCall.kt:502)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: java.io.EOFException: SSL peer shut down incorrectly
at java.base/sun.security.ssl.SSLSocketInputRecord.read(SSLSocketInputRecord.java:483)
at java.base/sun.security.ssl.SSLSocketInputRecord.readHeader(SSLSocketInputRecord.java:472)
at java.base/sun.security.ssl.SSLSocketInputRecord.decode(SSLSocketInputRecord.java:160)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:110)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1418)
... 23 more

报错提示

出现错误, 请联系管理员检查后台或重试
Unexpected JSON token at offset 332: Encountered an unknown key 'ext'.
Use 'ignoreUnknownKeys = true' in 'Json {}' builder to ignore unknown keys.

控制台日志:
at kotlinx.serialization.json.internal.JsonExceptionsKt.JsonDecodingException(JsonExceptions.kt:24)

at kotlinx.serialization.json.internal.JsonExceptionsKt.JsonDecodingException(JsonExceptions.kt:32)

at kotlinx.serialization.json.internal.JsonReader.fail(JsonReader.kt:333)

at kotlinx.serialization.json.internal.JsonReader.fail$default(JsonReader.kt:332)

at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeObjectIndex(StreamingJsonDecoder.kt:145)

at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeElementIndex(StreamingJsonDecoder.kt:88)

at moe.ruabbit.mirai.setu.LoliconResponse$SetuImageInfo$$serializer.deserialize(LoliconResponse.kt:12)

at moe.ruabbit.mirai.setu.LoliconResponse$SetuImageInfo$$serializer.deserialize(LoliconResponse.kt:12)

at kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:63)

at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeSerializableValue(StreamingJsonDecoder.kt:33)

at kotlinx.serialization.encoding.AbstractDecoder.decodeSerializableValue(AbstractDecoder.kt:41)

at kotlinx.serialization.encoding.AbstractDecoder.decodeSerializableElement(AbstractDecoder.kt:63)

at kotlinx.serialization.encoding.CompositeDecoder$DefaultImpls.decodeSerializableElement$default(Decoding.kt:479)

at kotlinx.serialization.internal.ListLikeSerializer.readElement(CollectionSerializers.kt:80)

at kotlinx.serialization.internal.AbstractCollectionSerializer.readElement$default(CollectionSerializers.kt:51)

at kotlinx.serialization.internal.AbstractCollectionSerializer.merge(CollectionSerializers.kt:36)

at kotlinx.serialization.internal.AbstractCollectionSerializer.deserialize(CollectionSerializers.kt:43)

at kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:63)

at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeSerializableValue(StreamingJsonDecoder.kt:33)

at kotlinx.serialization.encoding.AbstractDecoder.decodeSerializableValue(AbstractDecoder.kt:41)

at kotlinx.serialization.encoding.AbstractDecoder.decodeNullableSerializableElement(AbstractDecoder.kt:72)

at moe.ruabbit.mirai.setu.LoliconResponse$$serializer.deserialize(LoliconResponse.kt:5)

at moe.ruabbit.mirai.setu.LoliconResponse$$serializer.deserialize(LoliconResponse.kt:5)

at kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:63)

at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeSerializableValue(StreamingJsonDecoder.kt:33)

at kotlinx.serialization.json.Json.decodeFromString(Json.kt:85)

at moe.ruabbit.mirai.setu.LoliconRequester.parseSetu(LoliconRequester.kt:218)

at moe.ruabbit.mirai.setu.LoliconRequester.requestSetu(LoliconRequester.kt:35)

at moe.ruabbit.mirai.setu.LoliconRequester$requestSetu$1.invokeSuspend(LoliconRequester.kt)

at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)

at io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:188)

at io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:144)

at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)

at io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:90)

at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)

at io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:188)

at io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:144)

at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)

at io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:90)

at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)

at io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:188)

at io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:144)

at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)

at io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:90)

at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)

at io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:188)

at io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:144)

at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)

at io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:90)

at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)

at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)

at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)

at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)

at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)

at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)

使用FantasyZoneApi报错

随机报错,时不时正常
信息如下
2021-05-22 13:59:26 E/main: Exception in coroutine
kotlinx.serialization.json.internal.JsonDecodingException: Unexpected JSON token at offset 31: Expected string literal but 'null' literal was found.
Use 'coerceInputValues = true' in 'Json {}` builder to coerce nulls to default values.
JSON input: .....
"id": null,
"title": null,
"description": null,.....
at kotlinx.serialization.json.internal.JsonExceptionsKt.JsonDecodingException(JsonExceptions.kt:24)
at kotlinx.serialization.json.internal.JsonExceptionsKt.JsonDecodingException(JsonExceptions.kt:32)
at kotlinx.serialization.json.internal.JsonReader.fail(JsonReader.kt:338)
at kotlinx.serialization.json.internal.JsonReader.takeStringQuoted(JsonReader.kt:166)
at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeString(StreamingJsonDecoder.kt:213)
at kotlinx.serialization.encoding.AbstractDecoder.decodeStringElement(AbstractDecoder.kt:58)
at cn.blrabbit.mirai.setu.FantasyZoneResponse$$serializer.deserialize(FantasyZoneResponse.kt)
at cn.blrabbit.mirai.setu.FantasyZoneResponse$$serializer.deserialize(FantasyZoneResponse.kt:6)
at kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:63)
at kotlinx.serialization.json.internal.StreamingJsonDecoder.decodeSerializableValue(StreamingJsonDecoder.kt:32)
at kotlinx.serialization.json.Json.decodeFromString(Json.kt:85)
at cn.blrabbit.mirai.setu.FantasyZoneRequester.requestSetu(FantasyZoneRequester.kt:156)
at cn.blrabbit.mirai.setu.FantasyZoneRequester$requestSetu$1.invokeSuspend(FantasyZoneRequester.kt)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:188)
at io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:144)
at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)
at io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:90)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)

发送图片不显示图片信息

使用指令获取图片时只会发送图片
关于作者之类的信息无法发送
以及以图搜图时信息也无法发送(控制台已经有输出了,但群内没有)
但是切换模式等信息可以正常发送

我这边帮忙把代码适配了V2。

最近刚刚入门,发现这个插件的代码比较简单入门易懂。
在经过一段时间的摸索后,我把插件的源代码从V1适配到了V2,不过目前我还不知道怎么进行多Tag进行搜图,不过API还是匹配到V2上了。
而且原来的1.2.2的以图搜图没有功能权限,我这边也增加上去了(我那群封印插件但是天天以图搜图玩)

如果作者同意的话,我这边可以发出来。

mirai2.0

在最新版上无法使用,请适配一下,谢谢 还有要是搜出来的图片要是可以同时保存在本地就好了

下载出错

使用i.pximg.net时图片发不出来
出现错误, 请联系管理员检查后台或重试
Connect timeout has been expired [url=https://i.pximg.net/img-original/img/2021/03/08/00/00/09/88291905_p0.jpg, connect_timeout=unknown ms]

增加每日色图上限设定

如题,群友们太热 情了Orz
能在配置文件里设置每日从lolicon获取的总色图量,包含涩图和搜涩图
(当然能分别控制坠好

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.