While i am upgrading the project Gradle from 7.4.2 to 7.51, i get the following exception :Caused by: groovy.lang.MissingPropertyException: Could not get unknown property ‘main’ for SourceSet container of type org.gradle.api.internal.tasks.DefaultSourceSetContainer.
at org.gradle.internal.metaobject.AbstractDynamicObject.getMissingProperty(AbstractDynamicObject.java:85)
at org.gradle.internal.metaobject.AbstractDynamicObject.getProperty(AbstractDynamicObject.java:62)
at org.gradle.api.internal.tasks.DefaultSourceSetContainer_Decorated.getProperty(Unknown Source)
Code inside the project : List sourceSets = composeClasspath ?
project.configurations.compileClasspath.allDependencies
.withType(ProjectDependency).dependencyProject.sourceSets.main :
[project.sourceSets.main]