Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traits not correctly highlighted #8

Closed
DiegoMC9 opened this issue May 12, 2023 · 4 comments
Closed

Traits not correctly highlighted #8

DiegoMC9 opened this issue May 12, 2023 · 4 comments
Labels
question Further information is requested

Comments

@DiegoMC9
Copy link

DiegoMC9 commented May 12, 2023

  • Intellij-Version: IntelliJ IDEA 2023.1.1 (Ultimate Edition)
  • Using New UI
  • Smithy Plugin Version: 2.0.8

Observed behaviour:

  • Traits get identified as shapes, reporting "Unresolved shape "
  • Similar behaviour happens with use statements, reporting "Unresolved shape " error on the use statement and its usage

Screenshot 2023-05-12 at 5 03 09 PM

@iancaffey
Copy link
Owner

iancaffey commented May 12, 2023

What are you using to build your smithy models? The CLI or the Gradle plugin?

Traits get identified as shapes, reporting "Unresolved shape "

Traits are shapes, the plugin just can't find smithy.api#title.

What you're observing there is from dependencies not being configured properly in IntelliJ.

If you're using the CLI, dependency jars (and the CLI itself or the smithy-model package for prelude shapes) which contain smithy shapes that you depend on have to be manually added as dependencies to your IntelliJ project for the time being until the build system integration is added.

If you're using Gradle, there's nothing special required. The built-in Gradle support in IntelliJ handles smithy dependencies out of the box.

@iancaffey
Copy link
Owner

iancaffey commented May 12, 2023

Smithy CLI support is being tracked #9.

Initial goal is to unblock dependency resolution for the time being, since you can always manually run the CLI from a Terminal tool window within IntelliJ. And follow-up tasks would add integrated support for build actions (very similar to the UX you get with Gradle in IntelliJ today).

The workaround for the time being would be to keep using the Smithy Gradle plugin, since you get the best IDE experience. And it's not much to haul around for the time being, can just delete the build.gradle(.kts) once CLI support is added.

@iancaffey
Copy link
Owner

Hey Diego, let me know if there's anything else I can help with.

Going to resolve the issue for now.

@DiegoMC9
Copy link
Author

Thank you, i'll double check the build system!

@iancaffey iancaffey added the question Further information is requested label Jun 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants