Conversation
Co-authored-by: iscai-msft <43154838+iscai-msft@users.noreply.github.com>
Co-authored-by: iscai-msft <43154838+iscai-msft@users.noreply.github.com>
commit: |
|
@copilot do the following
|
Co-authored-by: iscai-msft <43154838+iscai-msft@users.noreply.github.com>
Done!
The test cases cover:
|
tadelesh
left a comment
There was a problem hiding this comment.
For ARM cases, there always has a root client with no op and sub-clients from operation groups. Then this lint will always report for ARM case, which I don't think is a good lint.
| ); | ||
| // Check if the client is empty (has no methods and no children with operations) | ||
| // Only emit diagnostic if client.type is defined (client has a source TypeSpec type to attach the diagnostic to) | ||
| if (sdkClientType.methods.length === 0 && !sdkClientType.children?.length && client.type) { |
There was a problem hiding this comment.
| if (sdkClientType.methods.length === 0 && !sdkClientType.children?.length && client.type) { | |
| if (sdkClientType.methods.length === 0 && client.type) { |
There was a problem hiding this comment.
If no sub clients, this client will not exist.
There was a problem hiding this comment.
we should keep the diagnostic in this case though, we should have a diagnostic for an explicitly defined client with no methods and no sub-clients. That seems like unintentional behavior for users. This also won't trigger for ARM
There was a problem hiding this comment.
I mean you did not need the condition since it is filtered in caching process.
|
All changed packages have been documented.
Show changes
|
|
You can try these changes here
|
Implementation Plan for Empty Client Linter Warning
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.