Commit Graph

14197 Commits

Author SHA1 Message Date
Ilya Goncharov 8dbeb721a2 [JS] Use only rollup action, copy and delete through Gradle task 2023-12-05 18:00:27 +00:00
Alexander.Likhachev d8c416f818 [Gradle] Replace the deprecated K/JS plugin in ExecutionStrategyIT.kt 2023-12-05 13:51:14 +00:00
Alexander.Likhachev b000b66ef7 [Daemon] Improve some daemon log messages
A few messages were improved:
  * If the daemon process died at the startup, add its last 10 lines of the output to the log and report to the EXCEPTION (ERROR in the case of Gradle) level
  * If some exception occurs during connection attempt, add its stacktrace and report to the EXCEPTION (ERROR in the case of Gradle) level
  * Added more DEBUG level messages
  * Some important messages are moved to the INFO level
  * Added a suggestion to report issue to kotl.in/issue
^KT-55322 Fixed
2023-12-05 13:51:14 +00:00
Alexander.Likhachev 3ccca58bb0 [Gradle] Release daemon compile session at a compilation task's finish
Before this change, some long-running tasks like `run` might cause the Kotlin daemon to go into the LastSession state and stay in that state until the long-running tasks and therefore the Gradle build are finished.
The reason for that behaviour is that if we don't release sessions explicitly, the created "session is alive" marker files are cleaned up by `KotlinGradleFinishBuildHandler.buildFinished` at the end of the build.
^KT-55322 In Progress
2023-12-05 13:51:14 +00:00
Yahor Berdnikau b7d6cdb6eb [Gradle] Fix warning in GradleCompilationResults
^KT-56904 In Progress
2023-12-05 09:26:45 +00:00
Nataliya.Valtman 4294c7bab7 Add limitation for changed files list for JPS build report
#KT-63549
2023-12-04 18:19:15 +00:00
Anton Lakotka 6eeb459076 [Gradle] Add defaultDestinationDir to FatFrameworkTask
To prevent cycle when updating destinationDirProperty
2023-12-04 18:08:09 +00:00
Anton Lakotka 8b335ea051 [Gradle] Add destinationDirProperty to FatFrameworkTask
And use gradle's projectLayout.buildDirectory instead deprecated
project.buildDir.

^KT-56904
2023-12-04 18:08:09 +00:00
Evgenii Mazhukin 834602b737 [Tests] Add javadoc for @TestMetadata
Merge-request: KT-MR-13338
Merged-by: Evgenii Mazhukin <evgenii.mazhukin@jetbrains.com>
2023-12-04 17:29:42 +00:00
Leonid Startsev a035533316 Rename JvmMetadataVersion.CURRENT to JvmMetadataVersion.LATEST_STABLE_SUPPORTED. 2023-12-01 17:43:12 +00:00
Leonid Startsev 048802e143 Rework KotlinModuleMetadata to align it with KotlinClassMetadata:
- Public constructor with KmModule and JvmMetadataVersion
- make write() member function
2023-12-01 17:43:12 +00:00
Leonid Startsev 6e9a62c317 Update ReadMe.md in kotlinx-metadata with instructions for new
functions:

How to use readStrict(), transform(), write() and
JvmMetadataVersion.CURRENT
2023-12-01 17:43:12 +00:00
Leonid Startsev 721af75f40 Provide a separate class for representing metadata version in kotlinx-metadata
Separate class allows encapsulating comparison, equality, and structure of version parts.
It also makes more sense from API standpoint than plain `IntArray`.
2023-12-01 17:43:11 +00:00
Leonid Startsev f101e5a336 Unify write() method and make it a member of KotlinClassMetadata
To make sure that the correct version and flags are preserved during metadata transformation,
they are now stored inside KotlinClassMetadata.
Such change also makes it possible to make write() a member function of KotlinClassMetadata, further simplifying API.
Also, it allows tracking whether readStrict or readLenient was used to read metadata and prohibit writing accordingly.

Also provide transform() method as a shortcut for readStrict+write.

Related to: #KT-59441
2023-12-01 17:43:11 +00:00
Leonid Startsev 36703ff9ae Implement strict and lenient modes for Kotlin metadata reading
In strict mode, an exception will be thrown when inconsistent metadata is encountered. In lenient mode, the reader will attempt to handle the inconsistent metadata by ignoring certain inconsistencies. This is a solution to a problem of reading metadata 'from the future' that is not allowed by default, but desired in certain cases. See updated ReadMe for details.

Also fix problem with Strict Semantics flag.

#KT-57922 Fixed
#KT-59441 Fixed
2023-12-01 17:43:11 +00:00
Yahor Berdnikau 57bc120daf [Gradle] Add AGP 8.3 into test versions
^KT-58064 Verification Pending
2023-12-01 17:19:20 +00:00
Yahor Berdnikau fc6ef76afe [Gradle] Bump max Gradle version in tests to 8.2.1
^KT-58064 In Progress
2023-12-01 17:19:20 +00:00
Yahor Berdnikau b666e66e19 [Gradle] Fix 3-rd party lombok plugin is non-compatible with Gradle 8.2
^KT-58064 In Progress
2023-12-01 17:19:20 +00:00
Yahor Berdnikau cb64234192 [Gradle] Fix test data using deprecated conventions
^KT-63369 Fixed
2023-12-01 17:19:20 +00:00
Yahor Berdnikau c847d427d8 [Gradle] Fix test data not including test framework dependency
^KT-63368 Fixed
2023-12-01 17:19:20 +00:00
Evgenii Mazhukin befa921fd9 [IC] Multi-module incremental compilation smoke tests for KMP
Part 2. Main multi-module KMP smoke tests for incremental compilation

^KT-56963 Fixed
^KT-63876 Fixed

Merge-request: KT-MR-13193
Merged-by: Evgenii Mazhukin <evgenii.mazhukin@jetbrains.com>
2023-12-01 15:46:51 +00:00
Evgenii Mazhukin 3f8505a090 [IC] Smoke tests for KMP IC, part 1.5
Refactorings: rework testData to better reflect usages of declarations,
clean up internal test methods.

Merge-request: KT-MR-13232
Merged-by: Evgenii Mazhukin <evgenii.mazhukin@jetbrains.com>
2023-11-29 13:28:26 +00:00
Ilya Goncharov 08e3cb300a [JS] Migrate tests onto IR compiler with outputDir API instead of outputFile
^KT-61117 fixed
2023-11-29 11:21:56 +00:00
Yahor Berdnikau e50f6e6bca [Gradle] Add '@JvmStatic' annotation to companion methods in Kotlin types
This should improve usability in groovy scripts.

^KT-63601 Fixed
2023-11-29 10:24:23 +00:00
Alexander.Likhachev b0254add6d [Gradle] Add a check for the SNAPSHOT_SIZE metric 2023-11-28 15:22:43 +00:00
Alexander.Likhachev a7e3f7b3a6 [Gradle] Apply IDEA suggestions to BuildReportsIT.kt 2023-11-28 15:22:43 +00:00
Alexander.Likhachev 71320d2439 [IC] Add a check for the CACHE_DIRECTORY_SIZE metric
^KT-63010 Fixed
2023-11-28 15:22:43 +00:00
Alexander.Likhachev 9f89e7f94f [Gradle] Flip the IC backup optimizations flags in the tests
^KT-62758 Fixed
2023-11-28 15:22:43 +00:00
Alexander.Likhachev 0f245ef3c6 [Gradle] Enable the IC backup optimizations by default
^KT-62758 In Progress
2023-11-28 15:22:43 +00:00
Alexander.Likhachev f0c643a887 [Gradle] Remove warning about experimental IC backup optimizations
This commit is part of the optimizations stabilization
^KT-62758 In Progress
2023-11-28 15:22:43 +00:00
Evgenii Mazhukin 563c878f20 [KGP] Fix sharing build cache between Windows and Linux
On Windows, path() uses backslash as a file separator, and Mac/Linux
are using forward slashes. If friendPathsSet differs, remote build outputs
from other platforms can't be reused.

This patch uses invariant paths to address the issue.

^KT-63460 Fixed


Merge-request: KT-MR-13261
Merged-by: Evgenii Mazhukin <evgenii.mazhukin@jetbrains.com>
2023-11-28 12:09:39 +00:00
Ilya Goncharov 8c95665e27 [Gradle, JS] Deprecate specific Node.js properties
^KT-62780 fixed
2023-11-28 10:36:36 +00:00
Ilya Gorbunov 28c1049518 [stdlib] KT-55619 provide samples and extend documentation for String.format 2023-11-27 15:04:51 +00:00
Anton Lakotka bb5e219c1d [Gradle] Explain reason for (isCanBeResolved && isCanBeConsumed) check 2023-11-26 18:47:29 +01:00
Anton Lakotka 7673434ccd [Gradle] Keep "-publishable" configurations as dependencyScope
As they would clash with the ones that is intended to be consumed as
project dependencies. It will not be compatible with future Gradle
versions. This should be fixed with KT-49919

^KT-60879
2023-11-26 18:47:29 +01:00
Anton Lakotka e73441843b [Gradle] Don't make native compilation api configuration resolvable
Instead, create a resolvableDetached configuration for that purpose.
Changing configuration roles is deprecated since Gradle 8.2

^KT-60879
2023-11-26 18:47:29 +01:00
Anton Lakotka 5d46e45da7 [Gradle] Fix tests for Gradle 8.2 compatibility
* Dependency scope configurations can't have attributes
* ConfigurationInternal.path is removed

^KT-60879
2023-11-26 18:47:29 +01:00
Anton Lakotka 2ab30d8880 [Gradle] Add role-based configuration method factories
Starting from Gradle 8.2 there is deprecation diagnostic that
disallows changing configuration roles after creation.

With Gradle 8.4 there is an Incubating API that introduces
role factories for Configuration. For consistency reasons names that
introduced in this commit match the names that Gradle introduces in 8.4
version.

^KT-60879
2023-11-26 18:47:29 +01:00
Abduqodiri Qurbonzoda e94b247835 Introduce Common StringBuilder.append/insert(Byte/Short) extensions #KT-63341 2023-11-26 02:48:19 +02:00
Abduqodiri Qurbonzoda db6a662631 Remove Common StringBuilder.append/insert(Byte/Short) members #KT-63341 2023-11-26 02:48:18 +02:00
Alexander Udalov b63a780e15 Build: update kotlinx-metadata-jvm to 0.7.0 2023-11-24 14:03:21 +00:00
Ilya Goncharov f9ffe67430 [Gradle, JS] Add comment why we use project.provider and not use single 2023-11-24 11:17:49 +00:00
Philip Wedemann 1dbb227de2 KT-63544: Fix Gradle CC problem in KotlinJsIrLink 2023-11-24 11:17:49 +00:00
Ilya Gorbunov 88bbe8d92d [stdlib] Enable explicit API mode 2023-11-24 01:45:45 +00:00
Ilya Goncharov 957d3c5610 [Gradle, JS] Use binaries for wasi with KotlinJsIrCompilation 2023-11-23 18:36:39 +00:00
Yahor Berdnikau b000b3a90b [Gradle] Drop usage of non-LTS JDK versions in integration tests 2023-11-23 18:28:10 +00:00
Ilya Gorbunov d8ee74222f [builtins-gen] Explicit visibility for companion objects and secondary constructors 2023-11-22 18:04:34 +00:00
Ilya Gorbunov ab7c2f2196 [stdlib] Explicit visibility and return types: builtins 2023-11-22 18:04:34 +00:00
Ilya Gorbunov df190b1265 [stdlib] Explicit visibility and return types: JVM internal 2023-11-22 18:04:34 +00:00
Ilya Gorbunov 2e030f213b [stdlib] Explicit visibility and return types: JVM 2023-11-22 18:04:34 +00:00