the import packages are shown in the Uncovered Lines on New Code.
How can I exclude those imports from to exclude those lines as part of the coverage
SonarCloud computes coverage and uncovered lines based on the coverage report you imported.
Could you please share how did you configure coverage?
Could you please check if your coverage report contains information about those import lines?