Compare commits

..

3 Commits

Author SHA1 Message Date
Syer10
fbfa80f196 Import fix 2026-05-09 14:47:25 -04:00
Syer10
9d5d88e56c Update Javalin usage to v7 and Jackson 3 2026-05-09 14:40:09 -04:00
renovate[bot]
d57623fe2e Update javalin to v7 2026-05-09 17:01:05 +00:00
5 changed files with 6 additions and 18 deletions

View File

@@ -14,7 +14,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
### Fixed ### Fixed
- (WebUI) Handle serving non-default webui with "bundled" - (WebUI) Handle serving non-default webui with "bundled"
- (WebUI) Wait until WebUI is ready to open in browser
## [v2.2.2100] + [WebUI: v20260508.01] - 2026-05-08 ## [v2.2.2100] + [WebUI: v20260508.01] - 2026-05-08

View File

@@ -6,7 +6,7 @@ jvmTarget = "21"
okhttp = "5.3.2" # Major version is locked by Tachiyomi extensions okhttp = "5.3.2" # Major version is locked by Tachiyomi extensions
javalin = "7.2.0" javalin = "7.2.0"
jte = "3.2.4" jte = "3.2.4"
jackson = "3.1.3" # jackson version locked by javalin, ref: `io.javalin.core.util.OptionalDependency` jackson = "3.1.2" # jackson version locked by javalin, ref: `io.javalin.core.util.OptionalDependency`
exposed = "0.61.0" exposed = "0.61.0"
dex2jar = "2.4.36" dex2jar = "2.4.36"
polyglot = "25.0.3" polyglot = "25.0.3"
@@ -54,7 +54,7 @@ javalin-openapi = { module = "io.javalin:javalin-openapi", version.ref = "javali
javalin-rendering = { module = "io.javalin:javalin-rendering-jte", version.ref = "javalin" } javalin-rendering = { module = "io.javalin:javalin-rendering-jte", version.ref = "javalin" }
jackson-databind = { module = "tools.jackson.core:jackson-databind", version.ref = "jackson" } jackson-databind = { module = "tools.jackson.core:jackson-databind", version.ref = "jackson" }
jackson-kotlin = { module = "tools.jackson.module:jackson-module-kotlin", version.ref = "jackson" } jackson-kotlin = { module = "tools.jackson.module:jackson-module-kotlin", version.ref = "jackson" }
jackson-annotations = "com.fasterxml.jackson.core:jackson-annotations:2.21" jackson-annotations = "com.fasterxml.jackson.core:jackson-annotations:2.20"
jte = { module = "gg.jte:jte", version.ref = "jte" } jte = { module = "gg.jte:jte", version.ref = "jte" }
kte = { module = "gg.jte:jte-kotlin", version.ref = "jte" } kte = { module = "gg.jte:jte-kotlin", version.ref = "jte" }

View File

@@ -171,7 +171,6 @@ tasks {
"Implementation-Vendor" to "The Suwayomi Project", "Implementation-Vendor" to "The Suwayomi Project",
"Specification-Version" to getTachideskVersion(), "Specification-Version" to getTachideskVersion(),
"Implementation-Version" to getTachideskRevision(), "Implementation-Version" to getTachideskRevision(),
"Multi-Release" to true, // needed for polyglot
) )
} }
archiveBaseName.set(rootProject.name) archiveBaseName.set(rootProject.name)

View File

@@ -27,10 +27,7 @@ import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.SupervisorJob import kotlinx.coroutines.SupervisorJob
import kotlinx.coroutines.flow.combine import kotlinx.coroutines.flow.combine
import kotlinx.coroutines.flow.first
import kotlinx.coroutines.future.future import kotlinx.coroutines.future.future
import kotlinx.coroutines.launch
import kotlinx.coroutines.withTimeoutOrNull
import org.eclipse.jetty.server.ServerConnector import org.eclipse.jetty.server.ServerConnector
import suwayomi.tachidesk.global.GlobalAPI import suwayomi.tachidesk.global.GlobalAPI
import suwayomi.tachidesk.graphql.GraphQL import suwayomi.tachidesk.graphql.GraphQL
@@ -54,7 +51,6 @@ import java.util.concurrent.CompletableFuture
import kotlin.concurrent.thread import kotlin.concurrent.thread
import kotlin.text.get import kotlin.text.get
import kotlin.time.Duration.Companion.days import kotlin.time.Duration.Companion.days
import kotlin.time.Duration.Companion.seconds
object JavalinSetup { object JavalinSetup {
private val logger = KotlinLogging.logger {} private val logger = KotlinLogging.logger {}
@@ -136,12 +132,7 @@ object JavalinSetup {
config.events.serverStarted { config.events.serverStarted {
if (serverConfig.initialOpenInBrowserEnabled.value) { if (serverConfig.initialOpenInBrowserEnabled.value) {
scope.launch { Browser.openInBrowser()
withTimeoutOrNull(10.seconds) {
WebInterfaceManager.isSetupComplete.first { it }
}
Browser.openInBrowser()
}
} }
} }
} }

View File

@@ -27,7 +27,6 @@ import kotlinx.coroutines.GlobalScope
import kotlinx.coroutines.SupervisorJob import kotlinx.coroutines.SupervisorJob
import kotlinx.coroutines.delay import kotlinx.coroutines.delay
import kotlinx.coroutines.flow.MutableSharedFlow import kotlinx.coroutines.flow.MutableSharedFlow
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.SharingStarted import kotlinx.coroutines.flow.SharingStarted
import kotlinx.coroutines.flow.combine import kotlinx.coroutines.flow.combine
import kotlinx.coroutines.flow.sample import kotlinx.coroutines.flow.sample
@@ -91,7 +90,7 @@ object WebInterfaceManager {
private val preferences = Injekt.get<Application>().getSharedPreferences("server_util", Context.MODE_PRIVATE) private val preferences = Injekt.get<Application>().getSharedPreferences("server_util", Context.MODE_PRIVATE)
private var currentUpdateTaskId: String = "" private var currentUpdateTaskId: String = ""
val isSetupComplete = MutableStateFlow(false) private var isSetupComplete = false
private val json: Json by injectLazy() private val json: Json by injectLazy()
private val network: NetworkHelper by injectLazy() private val network: NetworkHelper by injectLazy()
@@ -197,7 +196,7 @@ object WebInterfaceManager {
@OptIn(DelicateCoroutinesApi::class) @OptIn(DelicateCoroutinesApi::class)
GlobalScope.launchIO { GlobalScope.launchIO {
setupWebUI() setupWebUI()
isSetupComplete.value = true isSetupComplete = true
} }
} }
@@ -261,7 +260,7 @@ object WebInterfaceManager {
val lastAutomatedUpdate = preferences.getLong(LAST_WEBUI_UPDATE_CHECK_KEY, System.currentTimeMillis()) val lastAutomatedUpdate = preferences.getLong(LAST_WEBUI_UPDATE_CHECK_KEY, System.currentTimeMillis())
val task = { val task = {
if (isSetupComplete.value) { if (isSetupComplete) {
val log = val log =
KotlinLogging.logger( KotlinLogging.logger(
"${logger.name}::scheduleWebUIUpdateCheck(" + "${logger.name}::scheduleWebUIUpdateCheck(" +