Skip to content

Commit b9c49a9

Browse files
Vampirekrzema12
andauthored
docs: add some more IDE quirks to the FAQ (#1640)
Co-authored-by: Piotr Krzemiński <[email protected]>
1 parent 1290877 commit b9c49a9

File tree

1 file changed

+22
-2
lines changed

1 file changed

+22
-2
lines changed

docs/faq.md

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,31 @@ scripting. It's lagging behind the support provided by Kotlin itself.
6363

6464
Here's a list of tickets on the JetBrains side, along with proposed workarounds:
6565

66-
* [\[KTIJ-14580\] Imported script are not supported for scripts outside of a source root](https://youtrack.jetbrains.com/issue/KTIJ-14580)
66+
* **[\[KTIJ-14580\] Imported script are not supported for scripts outside of a source root](https://youtrack.jetbrains.com/issue/KTIJ-14580)**
6767
It's possible to partially mitigate it by adding dependencies from the imported files directly in the top-level
6868
script.
6969

70-
* [\[KTIJ-16532\] Scripting: dependencies do not open source files](https://youtrack.jetbrains.com/issue/KTIJ-16532)
70+
* **[\[KTIJ-16532\] Scripting: dependencies do not open source files](https://youtrack.jetbrains.com/issue/KTIJ-16532)**
7171
There are several workarounds: browse the code in GitHub, add a dependency on the library in your main project which
7272
will let you browse the source code in the IDE, or maybe it's enough to use
7373
[the rendered API docs](https://typesafegithub.github.io/github-workflows-kt/api-docs/).
74+
75+
* **[\[KTIJ-31203\] main.kts script handler uses stale `@Repository` value to resolve dependencies](https://youtrack.jetbrains.com/issue/KTIJ-31203)**
76+
When changing `@Repository` values, close the IntelliJ project and re-open it.
77+
If IntelliJ already resolved the dependency from the old repository, you might need to delete it from the Maven Local
78+
cache repository and after that restart the whole IDE as IntelliJ might not see the recreated file even after
79+
executing the workflow script and the file was recreated in the Maven Local cache repository. (also see next points)
80+
81+
* **A new release of an action added some input, but I don't see it in the IDE**
82+
If you depend on a major version of an action like `v1` and the action adds backwards compatible changes in a new
83+
release that adds inputs, the generated `v1` bindings are already present in your Maven Local cache repository and
84+
you do not get a new binding generated that includes the new inputs. To work-around this, delete the cache binding
85+
from your Maven Local cache repository, which typically is located at `~/.m2/respository/`. After that, executing or
86+
syncing the workflow script will re-request a fresh binding from the binding server that will include the up-to-date
87+
state of the action.
88+
89+
* **[\[KTIJ-31214\] Deleting a dependency jar from Maven Local and recreating it leaves `*.main.kts` script with unresolved symbols until IDE is restarted](https://youtrack.jetbrains.com/issue/KTIJ-31214)**
90+
After following the previous step and deleting a dependency from the Maven Local cache repository to get it updated,
91+
IntelliJ will not re-resolve the dependency and even doing so in another way like actually executing the workflow
92+
script, IntelliJ still treats the classes as unresolved symbols. To get to a usable state again, you need to restart
93+
the whole IDE, just closing and re-opening the project is not sufficient.

0 commit comments

Comments
 (0)