Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jazzy errors are not being detected in CI #5690

Open
2 tasks done
mildm8nnered opened this issue Jul 22, 2024 · 4 comments
Open
2 tasks done

Jazzy errors are not being detected in CI #5690

mildm8nnered opened this issue Jul 22, 2024 · 4 comments
Labels
discussion Topics that cannot be categorized as bugs or enhancements yet. They require further discussions. documentation Issues related to documentation, either from the tooling side or content-wise.

Comments

@mildm8nnered
Copy link
Collaborator

New Issue Checklist

Describe the bug

A clear and concise description of what the bug is.

It looks like Jazzy warnings and errors are not being detected in CI. For example, https://dev.azure.com/jpsim/SwiftLint/_build/results?buildId=8942&view=logs&j=ca898bab-e9ac-5909-e869-07ade246060d&t=bdc59b0b-f79d-5892-08f4-c67ba9c29a9a

Examples which are in a sense separate issues, but I'm just recording it all here for right now.

The first issue I noticed (because I was wondering where the reporters documentation was) is:

WARNING: No documented top-level declarations match name "CSVReporter" specified in categories file
WARNING: No documented top-level declarations match name "CheckstyleReporter" specified in categories file
WARNING: No documented top-level declarations match name "CodeClimateReporter" specified in categories file
WARNING: No documented top-level declarations match name "EmojiReporter" specified in categories file
WARNING: No documented top-level declarations match name "GitHubActionsLoggingReporter" specified in categories file
WARNING: No documented top-level declarations match name "HTMLReporter" specified in categories file
WARNING: No documented top-level declarations match name "JSONReporter" specified in categories file
WARNING: No documented top-level declarations match name "JUnitReporter" specified in categories file
WARNING: No documented top-level declarations match name "MarkdownReporter" specified in categories file

I think the problem here is that the reporters are not public anymore since 5544ce1

Other warnings, which are not so obviously warnings:

Parsing ViolationsSyntaxVisitor.swift (108/108)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method init(fromAny:context:), instance method init(fromAny:context:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method asOption(), instance method asOption()
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method asDescription(with:), instance method asDescription(with:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method apply(_:ruleID:), instance method apply(_:ruleID:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method kind(from:), instance method kind(from:), instance method kind(from:), instance method kind(from:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method collectInfo(for:), instance method collectInfo(for:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method validate(file:collectedInfo:), instance method validate(file:collectedInfo:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method validate(file:), instance method validate(file:)
Found conflicting type declarations with the same name, which may indicate a build issue or a bug in Jazzy: instance method makeViolation(file:violation:), instance method makeViolation(file:violation:)

and

Parsing Glob.swift (39/108)
/Users/runner/work/1/s/Source/SwiftLintCore/Helpers/Glob.swift:8:8: error: no such module 'Glibc'
import Glibc
       ^
@SimplyDanny SimplyDanny added discussion Topics that cannot be categorized as bugs or enhancements yet. They require further discussions. documentation Issues related to documentation, either from the tooling side or content-wise. labels Jul 22, 2024
@SimplyDanny
Copy link
Collaborator

SimplyDanny commented Jul 24, 2024

Parsing Glob.swift (39/108)
/Users/runner/work/1/s/Source/SwiftLintCore/Helpers/Glob.swift:8:8: error: no such module 'Glibc'
import Glibc
       ^

This one seems to be a bug in Jazzy or SourceKit(ten). They don't seem to evaluate compiler directives correctly. But this doesn't have an influence on the result in our case.

Not yet sure what causes the "Found conflicting type declarations ..." warnings. Do you have an idea?

@mildm8nnered
Copy link
Collaborator Author

Parsing Glob.swift (39/108)
/Users/runner/work/1/s/Source/SwiftLintCore/Helpers/Glob.swift:8:8: error: no such module 'Glibc'
import Glibc
       ^

This one is a bug in Jazzy or SourceKit(ten). They don't seem to evaluate compiler directives correctly. But this doesn't have an influence on the result in our case.

Not yet sure what causes the "Found conflicting type declarations ..." warnings. Do you have an idea?

So I would have thought it means that Jazzy found public func asOption() -> OptionType and then public func asOption() -> SomeOtherType, but I can't see any actual examples like that in the code, so maybe it is a bug in Jazzy.

@SimplyDanny
Copy link
Collaborator

So I would have thought it means that Jazzy found public func asOption() -> OptionType and then public func asOption() -> SomeOtherType, but I can't see any actual examples like that in the code, so maybe it is a bug in Jazzy.

I've reported this in realm/jazzy#1396. There are similar issues, but none that addresses the warning specifically. Let's see ...

@SimplyDanny
Copy link
Collaborator

For understanding, I've also just reported the Glibc one in realm/jazzy#1397.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion Topics that cannot be categorized as bugs or enhancements yet. They require further discussions. documentation Issues related to documentation, either from the tooling side or content-wise.
Projects
None yet
Development

No branches or pull requests

2 participants