Ensure Dart version is at least as high as dependencies
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
Research direction
Start by locating the validator's existing SDK and dependency checks, then inspect .dart_tool/package_config.json to understand the available languageVersion data. Implement validation that compares the project's environment.sdk with the highest required Dart version, including transitive packages, and verify that incompatible constraints are reported.
Written by the indexing model from the issue text.
Description
Say I have the following project:
environment:
sdk: ^3.0.0
dependencies:
pubspec_parse: ^1.5.0
This compiles, Pub doesn't complain, and this tool validates it with no issues. However, pubspec_parse version 1.5 requires Dart 3.6! Everything works because, coincidentally, I happen to have Dart 3.6 on my PC. But someone else might not, especially a CI workflow (this just happened in #138 but it happens to me all the time). I have a use case where I need to be entirely offline, so I'd like to know if I need to upgrade my Dart SDK as far in advance as possible.
To handle this, the tool should notice that pubspec_parse requires Dart 3.6 and flag that my environment.sdk is less than that. To handle the transitive case as well, the tool can look through .dart_tool/package_config.json and use the highest languageVersion it finds.
I filed https://github.com/dart-lang/pub/issues/4488 to see if the Dart team wants to integrate this into Pub directly as well
- Dominant language
- Dart
- Stars
- 66
- Forks
- 26
- Avg merge
- 5d 7h
- Merged PRs (30d)
- 7
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Workiva/dependency_validator
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
Workiva/dependency_validator#176 · 2 reactions ·
-
Difficulty 5/5 Over a week Newbie friendliness 30/100
Workiva/dependency_validator#167 · 2 comments ·
-
Support Doc Imports Open
Difficulty 3/5 1-2 days Newbie friendliness 45/100
Workiva/dependency_validator#153 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 48/100
Workiva/dependency_validator#140 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
Workiva/dependency_validator#134 · 1 comment ·
All issues in Workiva/dependency_validator
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
code quality good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Suwayomi/Suwayomi-Tsumiru#479 ·
-
Build Failure: agora_rtc_engine compiled against android-31 while dependencies require android-34+ Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 92/100
conceptadev/noir#95 ·