Skip to content

Conversation

@ForliyScarlet
Copy link
Member

close #1071

@ForliyScarlet ForliyScarlet added the 特性 一个新特性,或者一个新的功能/能力 label Jun 22, 2025
@ForteScarlet ForteScarlet enabled auto-merge June 22, 2025 14:07
@ForteScarlet ForteScarlet linked an issue Jun 22, 2025 that may be closed by this pull request
@ForteScarlet ForteScarlet requested a review from Copilot June 22, 2025 14:17
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces two new bot interfaces—ConfigurableBot and InitializableBot—to support delayed initialization and configurable bot state prior to full startup. Key changes include:

  • Addition of the ConfigurableBot interface with a configuration property for bot configuration.
  • Addition of the InitializableBot interface extending ConfigurableBot with an asynchronous initialization function and status properties.
  • Updates to the Bot interface documentation and API metadata to reference these new bot types.

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
simbot-api/src/commonMain/kotlin/love/forte/simbot/bot/InitializableBot.kt Adds a new interface for delayed bot initialization with status properties.
simbot-api/src/commonMain/kotlin/love/forte/simbot/bot/ConfigurableBot.kt Introduces an interface for bots that hold modifiable configuration.
simbot-api/src/commonMain/kotlin/love/forte/simbot/bot/Bot.kt Updates documentation to include the new bot types in the extended types section.
simbot-api/api/simbot-api.api Updates API metadata to include the new ConfigurableBot and InitializableBot interfaces.
Comments suppressed due to low confidence (1)

simbot-api/src/commonMain/kotlin/love/forte/simbot/bot/InitializableBot.kt:69

  • The comment for 'isInitializing' appears to be inconsistent with the expected behavior. It should indicate that 'isInitializing' returns true while the bot is in the process of initialization.
     * [isInitializing] 得到 `false`。

@ForliyScarlet
Copy link
Member Author

Qodana Community for JVM

It seems all right 👌

No new problems were found according to the checks applied

💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report

Contact Qodana team

Contact us at [email protected]

@ForteScarlet ForteScarlet merged commit 3679233 into v4-dev Jun 22, 2025
6 checks passed
@ForteScarlet ForteScarlet deleted the init-bot-api branch June 22, 2025 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

特性 一个新特性,或者一个新的功能/能力

Projects

None yet

Development

Successfully merging this pull request may close these issues.

为 Bot 添加新的 fun init()val isInitialized: Boolean

3 participants