|
b1e7643b09
|
build(deps): 将 telegrambots 从 6.5.0 更新至 6.7.0
更新 Api 版本以支持新的 Api 改动.
|
2023-08-02 17:45:35 +08:00 |
|
|
4537e08107
|
fix(config): 将 local 列为 Maven 仓库 Id 的保留字.
local 是 Aether 中代表 LocalRepository 的仓库 Id, 因此拒绝用户使用 local 作为远端仓库的 Id.
|
2023-08-02 17:45:31 +08:00 |
|
dependabot[bot]
|
aece8221f1
|
build(deps): bump org.jetbrains.kotlin:kotlin-reflect (#68)
Bumps [org.jetbrains.kotlin:kotlin-reflect](https://github.com/JetBrains/kotlin) from 1.8.21 to 1.9.0.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v1.8.21...v1.9.0)
---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-reflect
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-08-02 17:08:50 +08:00 |
|
dependabot[bot]
|
0bc77ada5f
|
build(deps): bump org.jetbrains.kotlinx:kotlinx-coroutines-core (#58)
Bumps [org.jetbrains.kotlinx:kotlinx-coroutines-core](https://github.com/Kotlin/kotlinx.coroutines) from 1.6.4 to 1.7.1.
- [Release notes](https://github.com/Kotlin/kotlinx.coroutines/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.coroutines/blob/master/CHANGES.md)
- [Commits](https://github.com/Kotlin/kotlinx.coroutines/compare/1.6.4...1.7.1)
---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-coroutines-core
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-05-30 10:44:16 +08:00 |
|
dependabot[bot]
|
3afe3b52ed
|
build(deps): bump org.jetbrains.kotlin:kotlin-reflect (#56)
Bumps [org.jetbrains.kotlin:kotlin-reflect](https://github.com/JetBrains/kotlin) from 1.8.20 to 1.8.21.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/master/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v1.8.20...v1.8.21)
---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-reflect
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-05-16 10:14:34 +08:00 |
|
dependabot[bot]
|
2e1fae87b3
|
build(deps): bump ch.qos.logback:logback-classic from 1.4.6 to 1.4.7 (#50)
Bumps [ch.qos.logback:logback-classic](https://github.com/qos-ch/logback) from 1.4.6 to 1.4.7.
- [Release notes](https://github.com/qos-ch/logback/releases)
- [Commits](https://github.com/qos-ch/logback/compare/v_1.4.6...v_1.4.7)
---
updated-dependencies:
- dependency-name: ch.qos.logback:logback-classic
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-05-16 09:33:17 +08:00 |
|
dependabot[bot]
|
2641901240
|
build(deps): bump io.mockk:mockk from 1.13.4 to 1.13.5 (#48)
Bumps [io.mockk:mockk](https://github.com/mockk/mockk) from 1.13.4 to 1.13.5.
- [Release notes](https://github.com/mockk/mockk/releases)
- [Commits](https://github.com/mockk/mockk/compare/v1.13.4...1.13.5)
---
updated-dependencies:
- dependency-name: io.mockk:mockk
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-04-20 17:54:51 +08:00 |
|
dependabot[bot]
|
73e20ab737
|
build(deps): bump ch.qos.logback:logback-classic from 1.4.5 to 1.4.6 (#44)
Bumps [ch.qos.logback:logback-classic](https://github.com/qos-ch/logback) from 1.4.5 to 1.4.6.
- [Release notes](https://github.com/qos-ch/logback/releases)
- [Commits](https://github.com/qos-ch/logback/compare/v_1.4.5...v_1.4.6)
---
updated-dependencies:
- dependency-name: ch.qos.logback:logback-classic
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-04-12 18:56:57 +08:00 |
|
dependabot[bot]
|
03d24fbfe3
|
build(deps): bump org.jetbrains.kotlin:kotlin-reflect (#45)
Bumps [org.jetbrains.kotlin:kotlin-reflect](https://github.com/JetBrains/kotlin) from 1.8.10 to 1.8.20.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/v1.8.20/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v1.8.10...v1.8.20)
---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-reflect
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-04-12 18:56:36 +08:00 |
|
dependabot[bot]
|
f233a25323
|
build(deps): bump org.slf4j:slf4j-api from 2.0.6 to 2.0.7 (#43)
Bumps [org.slf4j:slf4j-api](https://github.com/qos-ch/slf4j) from 2.0.6 to 2.0.7.
- [Release notes](https://github.com/qos-ch/slf4j/releases)
- [Commits](https://github.com/qos-ch/slf4j/commits)
---
updated-dependencies:
- dependency-name: org.slf4j:slf4j-api
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-03-23 21:28:20 +08:00 |
|
dependabot[bot]
|
a624fcd37d
|
build(deps): bump com.google.code.gson:gson from 2.9.0 to 2.10.1 (#36)
Bumps [com.google.code.gson:gson](https://github.com/google/gson) from 2.9.0 to 2.10.1.
- [Release notes](https://github.com/google/gson/releases)
- [Changelog](https://github.com/google/gson/blob/master/CHANGELOG.md)
- [Commits](https://github.com/google/gson/compare/gson-parent-2.9.0...gson-parent-2.10.1)
---
updated-dependencies:
- dependency-name: com.google.code.gson:gson
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-02-21 18:38:18 +08:00 |
|
|
3ea0f4eacb
|
feat(metrics): 指标信息增加 bot_id label.
由于 bot_name 不能作为机器人的唯一标识, 因此增加 bot_id 为监控平台提供唯一标识.
|
2023-02-21 18:32:35 +08:00 |
|
|
1e0eebbd7e
|
build(deps): 更新日志相关依赖(Slf4j 2.0.6, Logback-classic 1.4.5, Kotlin-logging 3.0.5).
Slf4j: 2.0.3 -> 2.0.6
Logback-classic: 1.4.4 -> 1.4.5
Kotlin-logging: 3.0.2 -> 3.0.5
|
2023-02-21 15:51:28 +08:00 |
|
dependabot[bot]
|
c013dafdd7
|
build(deps): bump io.mockk:mockk from 1.13.2 to 1.13.4 in /scalabot-app (#26)
Bumps [io.mockk:mockk](https://github.com/mockk/mockk) from 1.13.2 to 1.13.4.
- [Release notes](https://github.com/mockk/mockk/releases)
- [Commits](https://github.com/mockk/mockk/compare/1.13.2...v1.13.4)
---
updated-dependencies:
- dependency-name: io.mockk:mockk
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-02-21 15:08:06 +08:00 |
|
dependabot[bot]
|
e0bfd8796c
|
build(deps): bump org.jetbrains.kotlin:kotlin-reflect in /scalabot-app (#29)
Bumps [org.jetbrains.kotlin:kotlin-reflect](https://github.com/JetBrains/kotlin) from 1.6.20 to 1.8.10.
- [Release notes](https://github.com/JetBrains/kotlin/releases)
- [Changelog](https://github.com/JetBrains/kotlin/blob/v1.8.10/ChangeLog.md)
- [Commits](https://github.com/JetBrains/kotlin/compare/v1.6.20...v1.8.10)
---
updated-dependencies:
- dependency-name: org.jetbrains.kotlin:kotlin-reflect
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
|
2023-02-21 15:07:45 +08:00 |
|
|
bf2ea9a367
|
refactor(launch): 在启动时输出 JVM 和 Kotlin 的版本号.
在日志中添加版本信息, 方便在反馈问题时可以了解出现问题所使用的环境.
|
2023-02-19 16:12:15 +08:00 |
|
|
712378b3ff
|
build(dependencies): 更新 telegrambots 依赖项.
将 telegrambots 依赖项更新至 6.5.0, 支持新版 Api;
已确认 telegrambots 6.5.0 版本升级了jackson-databind 版本,
因此移除 jackson-databind 的显性依赖声明.
|
2023-02-08 10:12:33 +08:00 |
|
|
961382fb56
|
build(dependencies): 更新 TelegramBots 依赖项的版本号.
将 TelegramBots 依赖版本升级至 6.3.0, 支持新的 Telegram Bot API.
|
2022-12-16 01:15:09 +08:00 |
|
|
34d9ece6d7
|
feat(logging): 支持通过参数控制日志输出级别.
通过添加新的 -D 参数 `scalabot.log.level`, 使得用户可以根据需要, 调整日志输出级别, 通过日志来自行(或协助开发者)排查问题,
对于与网络有关的 Debug 级别日志, 则由 `scalabot.log.network.verbose` 参数进行控制;
另外, 由于开发过程中可通过该参数修改日志级别, 因此移除 `logback-test.xml` 文件.
|
2022-11-11 18:17:05 +08:00 |
|
|
30a2cb34d5
|
refactor(launch): 将 AppPaths 从 Launcher 解耦.
解耦后有助于后续改进, 以及单元测试的编写.
|
2022-11-07 11:16:41 +08:00 |
|
|
c94e0476b5
|
refactor(metrics): 为指标增加 namespace 名称.
遵循 OpenMetrics 规范指南, 为运行指标添加 namespace 名称, 防止指标混乱.
BREAKING CHANGE: 运行指标名称变更,
如果用户启用了运行指标功能, 请注意修改使用指标的名称.
|
2022-10-28 01:33:03 +08:00 |
|
|
6e5cd07c51
|
build(dependencies): 更新依赖项版本.
更新与日志和测试有关的依赖项版本.
|
2022-10-25 17:18:24 +08:00 |
|
|
90110335f5
|
fix: 更新 jackson-databind 依赖版本以缓解 CVE-2022-42004 漏洞.
CVE-2022-42004 漏洞报告指出, 由于 jackson-databind 的有关错误, 导致对象序列化过程可能存在数据错误的问题,
目前 jackson-databind 已发布 2.13.4.2 版本以解决该问题, 由于引入 jackson-databind 的 telegrambots 库尚未发布针对该问题的修复版本,
故在本项目中引入新版依赖项, 以确保用户不受该问题影响.
该版本已在 TelegramBots 项目(版本 6.1.0)中进行测试, 测试通过.
------------------------------------------
https://devhub.checkmarx.com/cve-details/CVE-2022-42004/
|
2022-10-20 01:41:48 +08:00 |
|
|
437cee499a
|
build(dependencies): 更新依赖项版本.
更新版本有利于维持项目安全性.
|
2022-09-19 01:14:31 +08:00 |
|
|
ff396425a7
|
refactor: 补充缺失代码.
由于先前的修改导致代码缺失, 我现在同意暂存功能很好用了.
|
2022-08-18 01:06:54 +08:00 |
|
|
580d9122e5
|
refactor(utils): 把日志记录器的获取方式改的优雅一点(对于测试来说).
由于 Kover 一直不把无代码高阶函数忽略掉, 所以稍微改一下这个日志记录器的获取方法, 让测试覆盖数据好看点(doge).
|
2022-08-17 23:01:06 +08:00 |
|
|
2a607f1129
|
fix(extension): 修复 ExtensionClassLoader 无法过滤非扩展包内 BotExtensionFactory 对象的问题.
按照 ServiceLoader 的规范, 文件应该是在 META-INF/services/{class} 这里的, 但当时忘记这个设计了, 导致直接判断 name == class, 然后失效.
修复好了.
|
2022-08-15 02:00:34 +08:00 |
|
|
255a02c93c
|
refactor(config): 重构 AppPaths 的构造方法, 应对将来 Kotlin 更新中的特性.
先前的方法是利用了初始化与调用的顺序, 来实现的 Supplier 互补(虽然在代码中, 确实存在未初始化调用的情况, 但实际运行的时候, 会先初始化, 再调用 Supplier),
但是未来 Kotlin 的更新中,编译器会把这个操作视为未初始化错误, 所以在这次改动中修复掉这个 bug 操作.
|
2022-08-15 01:38:08 +08:00 |
|
|
dce28be9c7
|
fix(logging): 修复日志滚动文件路径错误.
由于在滚动格式中没有使用 DATA_LOGS 占位符, 导致在日志滚动时会把日志归档文件保存在运行目录下, 而不是指定的数据目录,
该改动已修复该问题.
|
2022-08-13 13:19:09 +08:00 |
|
|
673c6d8392
|
build: 为项目支持可重现构建.
为确保项目的使用者(无论是开发者, 还是最终用户)可以完全重现构建, 确保安全, 故调整相关配置, 以实现"可重现构建".
有关可重现构建, 可以看这个: https://reproducible-builds.org/
|
2022-08-06 03:23:35 +08:00 |
|
|
d586ca378e
|
fix(launch): 修复缺省的 Maven 中央库不遵循代理规则的问题.
这个属于漏网之鱼, 已修复.
|
2022-08-05 00:23:13 +08:00 |
|
|
b6013e2fbe
|
refactor(extension): 将构件下载请求跟构件解析请求对齐.
防止在构件处理过程中因仓库原因出现问题, 因此统一两个请求所使用的仓库列表.
|
2022-07-16 20:55:24 +08:00 |
|
|
f79a4e4ff3
|
refactor(extension): 在 MavenRepositoryExtensionFinder 增加一个扩展包信息日志.
当初写的时候没留意这个问题, 结果最近给坑了, 所以补个日志, 打印出 Maven 搜索器所解析出来的构件信息.
|
2022-07-16 20:51:06 +08:00 |
|
|
93b9c6b727
|
refactor(launch): 统一代理的使用.
之前的版本中, 如果未指定 Maven 仓库的独立代理配置, 同时 Bot 拥有独立代理配置的情况下, Aether 将不会使用 Bot
的独立代理配置, 这样弄比较乱, 因此统一代理配置的使用顺序:
- 如果配置中包括了代理配置, 则优先使用独立代理配置;
- 如果不包括独立代理配置, 则使用关联 Bot 的独立代理配置;
- 如果关联 Bot 没有独立代理配置, 则使用 AppConfig 中的全局配置(如无配置则直连访问).
|
2022-07-16 20:46:15 +08:00 |
|
|
a8a0a9576f
|
build(dependencies): 更新 TelegramBots 依赖项的版本 (6.0.1 -> 6.1.0)
更新版本将有利于开发者和用户使用新的功能.
|
2022-07-16 20:30:22 +08:00 |
|
|
93685e9440
|
test(config): 优化单元测试.
将 AppPaths 的单元测试也覆盖了, 直接方便了.
|
2022-07-12 01:29:19 +08:00 |
|
|
92b7e84b3a
|
test(config): 补充相关的单元测试.
经检查, 已确定完全覆盖代码, 为完成单元测试的编写, 稍微改了一下 AppPaths 的代码, 不会有影响的 :P
|
2022-07-12 01:20:53 +08:00 |
|
|
8c4e48e3eb
|
refactor(launch): 更改初始化配置中, 退出进程的时机.
为了能在单元测试中检查 initialFiles 是否正常, 故将 exitProcess 移到 main 方法中, 方便进行测试.
|
2022-07-12 00:27:18 +08:00 |
|
|
441991b705
|
docs(extension): 补充部分扩展组件的 KDoc.
补充部分方法的文档, 不过文档内容嘛...有待加强.
|
2022-07-09 01:20:57 +08:00 |
|
|
51d036c4c6
|
feat(launch): 延后 BotConfig 的反序列化时机.
通过将 BotConfig 的反序列化时机延后到启动机器人的时候, 可以避免因某个机器人配置错误导致所有机器人都无法启动的问题.
注意, 语法错误还是会在启动时报错, 只是说部分序列化器会检查字段值是否有误, 通过延后反序列化来防止全反序列化的时候一个配置炸了影响全部而已.
|
2022-07-04 16:40:17 +08:00 |
|
|
c144755913
|
feat(config): 增加 BotAccountSerializer, 主要用于检查字段值.
增加 BotAccount 的序列化器, 便于检查有关字段的值是否有效.
|
2022-07-03 02:32:37 +08:00 |
|
|
9b7fc30512
|
fix(config): 修复因使用了错误的 Gson 对象而导致的配置初始化警告.
导致的原因是在初始化 app.json 时错误的使用了 botConfigGson, 而 botConfigGson 未配置用于 MetricsServer 的 UsernameAuthenticator 序列化器, 导致在初始化配置文件中序列化 AppConfig 时, Gson 会反射调用 BasicAuthenticator, 导致被 Java 模块系统拦截并报错, 现已修复该问题.
|
2022-07-02 22:01:05 +08:00 |
|
|
27dc26160d
|
refactor(config): 对配置文件的 AppPath 对象更名.
先前为确保后续可以增加指定配置文件路径的功能, 在命名上标记的 DEFAULT 在现在已经不符合实际意义了, 故将 DEFAULT 前缀移除.
|
2022-06-30 00:15:07 +08:00 |
|
|
ae411ce829
|
refactor(metrics): 调整 MetricsHttpServer 注册关闭钩子的时机.
将关闭钩子的时机调整到 main 方法中, 可以减少多余的钩子注册(比如测试时无需注册钩子, 却还是注册了).
|
2022-06-29 03:06:15 +08:00 |
|
|
1afe0f07a8
|
perf(extension): 优化 printExtensionFileConflictError 日志输出.
Kotlin-logging 在日志输出方法中做了检查, 如果级别未开启则不会调用方法获取日志内容,
故将内容构造部分移入 error 代码块以避免无意义的生成日志内容.
|
2022-06-29 03:03:16 +08:00 |
|
|
099c452fe7
|
feat(meta): 新增 meta 模块.
将与配置相关的内容迁移到 scalabot-meta 模块.
其他项目可以使用 meta 模块来生成 ScalaBot 的配置文件, 通过配置文件管理 ScalaBot 的运行.
BREAKING CHANGE: 与配置有关的类迁移到了 scalabot-meta 模块.
目前仅所有配置类 (以 `Config` 结尾的 Class) 和相应的序列化类 (以 `Serializer` 结尾的) 都迁移到了 meta 模块, 但其工具方法则作为扩展函数保留在 app 模块中.
这么做的好处是为了方便其他应用 (例如 ScalaBot 外部管理程序) 根据需要生成配置文件.
scalabot-meta 将会作为依赖项发布, 可根据需要获取 ScalaBot-meta 生成 ScalaBot 的配置.
+ 此次改动普通用户无需迁移。
|
2022-06-27 19:24:52 +08:00 |
|
|
581eeba20b
|
feat(config): 新增 HTTPS 代理类型, 增加 Maven 对 HTTPS 代理的支持.
为 ProxyType 增加 HTTPS 类型, 同时为 Aether 增加 Https 代理支持, 方便用户使用现有的公开代理下载依赖包.
|
2022-06-25 23:00:51 +08:00 |
|
|
896305f4a3
|
style: 改一下代码格式.
把“宝塔”改掉, 看起来太难受了.
|
2022-06-25 21:17:27 +08:00 |
|
|
4a160ad42b
|
refactor(config): 更改 BotConfig.enabled 的默认值为 false.
更改 enabled 的默认值, 以防止意外启动 Bot.
同时让 bot.json 在初始化时设为 true, 方便用户改完就能启动.
|
2022-06-24 19:10:39 +08:00 |
|
|
a1790a0716
|
perf(config): 优化配置使用过程中的判断.
通过调整部分属性的 null-safety 特性, 移除了部分 non-null 判断, 略微(真的很略微)提高了性能(虽然仅限于启动).
|
2022-06-24 19:08:41 +08:00 |
|