Error while trying to create a new dart file.

Answered

since the last update of intellij ultimate to 2022.1, I can't create dart files anymore.

whenever, I try to create a new dart file, I get this:

0
6 comments

1 - Create a mvn project and create a new (normal) file with extension .dart
2 - Then install plugins will appear
3 - Automatically you will get "dart" and install it.

or also

1 - Go to plugins and search for "dart"

0

but i already have the dart plugin installed... and I also tried uninstalling it, reinstalling, restarting IDE... ect.

Actually, right now as a workaround, i'm using the create File option and i type "filename.dart"...

0

I'll make you a quick and basic tutorial. Try to follow the steps.

1 - Install the plugin

2 - Download the Dart SDK at https://dart.dev/get-dart/archive
3 - Create a dart project

4 - See if the option to create a .dart appears.
Remember to create them inside the bin folder or if you want to have a custom path then wherever you want.

 

If it doesn't work for you I recommend that you remove the temps from jetbrains/Intellij

C:\Users\<YourUser>\AppData\Roaming\JetBrains

And try again.

0

Thank you for your effort kind sir, I did exactly as you mentionned, started a dart project, and whenever i try to create a dart file, I still got the same error.

I tried clearing all the temp from Intellij folder, and repeated the above steps, still the same error.

0

Then I recommend that you upload the project to
https://youtrack.jetbrains.com/newIssue?project=IDEA
and the "logs" of the possible error and wait for a response from the Intellij developers.

 

In old version of Intellij it works. 2021.3.3

If you dare you can take the previous version.
https://www.jetbrains.com/es-es/idea/download/other.html

 

Possible references:
https://github.com/flutter/flutter-intellij/issues/6111

 

You can always create it by hand. new file filename.dart.
It's a bit annoying... but if you can't find a solution, it's an alternative for now.

0

Looks like it is a known problem https://youtrack.jetbrains.com/issue/WEB-55484 . Please follow YouTrack for updates.

Sorry for the inconvenience.

0

Please sign in to leave a comment.