projectDependencyIssues method
Validates the pubspec.yaml dependencies of a customer project in order to be deployed to Serverpod Cloud.
The Dart SDK version the project is built with is chosen by DartSdkSelector, which validates the declared bound against the version policy. This method only checks that the bound is declared.
If the dependencies are not valid, the returned list will contain the error messages. If the dependencies are valid, the list will be empty.
Implementation
List<String> projectDependencyIssues({bool requireServerpod = true}) {
final supportedServerpod = VersionConstraint.parse(
VersionConstants.supportedServerpodConstraint,
);
final sdkError = _validateEnvironmentConstraints();
final serverpodError = _validateHostedDependencyConstraint(
packageName: 'serverpod',
supported: supportedServerpod,
requireDependency: requireServerpod,
);
return [?sdkError, ?serverpodError];
}