File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
src/main/kotlin/org/jetbrains/kotlinx/dataframe/io Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ repositories {
20
20
dependencies {
21
21
api(project(" :core" ))
22
22
23
+ implementation(libs.kotlinLogging)
23
24
implementation(libs.kotlin.reflect)
24
25
implementation(libs.kotlinpoet)
25
26
api(libs.swagger) {
Original file line number Diff line number Diff line change 1
1
package org.jetbrains.kotlinx.dataframe.io
2
2
3
+ import io.github.oshai.kotlinlogging.KotlinLogging
3
4
import io.swagger.parser.OpenAPIParser
4
5
import java.io.File
5
6
import java.net.URL
6
7
8
+ private val logger = KotlinLogging .logger {}
9
+
7
10
/* * Needs to have any type schemas to convert. */
8
11
public fun isOpenApiStr (text : String ): Boolean = try {
9
12
val parsed = OpenAPIParser ().readContents(text, null , null )
10
13
parsed.openAPI?.components?.schemas != null
11
- } catch (_: Throwable ) {
14
+ } catch (e: Throwable ) {
15
+ logger.debug(e) { " Attempt to read input as YAML/JSON OpenAPI specification failed." }
12
16
false
13
17
}
14
18
You can’t perform that action at this time.
0 commit comments