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

[APIview] [Python] custom linter reporting duplicate errors #3712

Closed
kristapratico opened this issue Jul 20, 2022 · 13 comments · Fixed by #3908
Closed

[APIview] [Python] custom linter reporting duplicate errors #3712

kristapratico opened this issue Jul 20, 2022 · 13 comments · Fixed by #3908
Assignees

Comments

@kristapratico
Copy link
Member

https://apiview.dev/Assemblies/Review/453e3478565f4bdfb4df7e8ca9b53ba9#azure.ai.textanalytics.AnalyzeHealthcareEntitiesAction

Specific example is the __eq__ method on AnalyzeHealthcareEntitiesAction:

image

@l0lawrence
Copy link
Member

Removing for now - will need to add in case/test

@tjprescott
Copy link
Member

@kristapratico are the warnings accurate? If so, can they be fixed? @johanste and @annatisch would like to move to the point where any warnings on APIViews are blocking anyhow.

@kristapratico
Copy link
Member Author

Fair point. Going to leave this open, though, so the duplicate errors can be fixed - it makes my browser want to explode.

@praveenkuttappan
Copy link
Member

@LibbaLawrence This issue is fixed in latest pylint-checker-guidelines. right?

@l0lawrence
Copy link
Member

Yes, it is still open so that it can be fixed if we want to enable this checker again.

@tjprescott
Copy link
Member

@l0lawrence is this an issue with APIView or the custom linter rule itself??

@l0lawrence
Copy link
Member

@l0lawrence is this an issue with APIView or the custom linter rule itself??

I ran this locally and I only got the 3 warnings once, so I believe this is an APIView issue.

@tjprescott
Copy link
Member

If the warning is legitimate, I would argue we should definitely not disable this checker. These warnings should be fixed. Disabling them from APIView circumvents that. I can look at the duplication next week, but fixing the issue in the code would resolve the warnings, and that is the course that should be taken.

@l0lawrence
Copy link
Member

If the warning is legitimate, I would argue we should definitely not disable this checker. These warnings should be fixed. Disabling them from APIView circumvents that. I can look at the duplication next week, but fixing the issue in the code would resolve the warnings, and that is the course that should be taken.

Let me double check with Krista that they are valid, and we can reinstate Docstring in version .7 with @Stevenjin8 's aiohttp/requests checker as well

@kristapratico
Copy link
Member Author

The linter warnings are valid and have since been fixed. The issue with the duplication is that it basically crashes the page making it hard to review the warnings present.

@tjprescott
Copy link
Member

image

So the issue is that a generated diagnostics is being repeatedly rendered on these methods, which points to an issue with the target ID not being specific enough.

@l0lawrence
Copy link
Member

image

So the issue is that a generated diagnostics is being repeatedly rendered on these methods, which points to an issue with the target ID not being specific enough.

By target ID do you mean the pylint node that the message is correlated with, or do you mean an ApiView target ID?

@tjprescott
Copy link
Member

tjprescott commented Aug 9, 2022

The same logical issue (in this case AZ_PY_3) is being repeatedly associated with APIView target IDs. Hence, if this method appears 10 times in the APIView, each one will appear to have 10 copies of the same diagnostic.

tjprescott added a commit that referenced this issue Aug 10, 2022
Repository owner moved this from 🆕 New to ✅ Done in ApiView Aug 10, 2022
Baas-hub pushed a commit to Baas-hub/azure-sdk-tools that referenced this issue Aug 11, 2022
* Troubleshoot issue

* Bump pylint-guidelines-checker version.

* Fixes Azure#3712.
chidozieononiwu pushed a commit to Baas-hub/azure-sdk-tools that referenced this issue Sep 23, 2022
author Baas-hub <benjbaas@gmail.com> 1659925517 +1200
committer Chidozie Ononiwu <chononiw@microsoft.com> 1663964726 -0700

parent 2d7456e
author Baas-hub <benjbaas@gmail.com> 1659925517 +1200
committer Chidozie Ononiwu <chononiw@microsoft.com> 1663964615 -0700

Adding Usage Sample page and Models for Azure#285

Continued advancements on adding usage samples.

Milestone step for Azure#285: Capability to upload via file or text input, and remove samples.

Minor refactor and tidy of backend code.

Adding Markdown to HTML parsing for display

Comments in bugged state. Going to experiment with new method of construction that may make them easier to manage.

Inline comments semi-working

Updated CONTRIBUTING.md and altered styling minimally.

Syntax highlighting added for Azure#285

Added editable samples

Added revisions to samples

Minor finalizing changes

Remvoing suggested inputs from revision labels

Requested changes

Changing wording as suggested

Revert "Remvoing suggested inputs from revision labels"

This reverts commit 0b96946.

Undoing bad push

Sandboxing changes: create apireview gen pipeline (Azure#3347)

* APIView sandboxing pipeline yaml to generate api review file

Bump Azure.Storage.Blobs (Azure#3750)

Bumps [Azure.Storage.Blobs](https://github.com/Azure/azure-sdk-for-net) from 12.8.0 to 12.13.0.
- [Release notes](https://github.com/Azure/azure-sdk-for-net/releases)
- [Commits](Azure/azure-sdk-for-net@Azure.Storage.Blobs_12.8.0...Azure.Storage.Blobs_12.13.0)

---
updated-dependencies:
- dependency-name: Azure.Storage.Blobs
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Bump Azure.Storage.Blobs (Azure#3749)

Bumps [Azure.Storage.Blobs](https://github.com/Azure/azure-sdk-for-net) from 12.8.0 to 12.13.0.
- [Release notes](https://github.com/Azure/azure-sdk-for-net/releases)
- [Commits](Azure/azure-sdk-for-net@Azure.Storage.Blobs_12.8.0...Azure.Storage.Blobs_12.13.0)

---
updated-dependencies:
- dependency-name: Azure.Storage.Blobs
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Bump Azure.Storage.Blobs in /src/dotnet/APIView/APIViewTest (Azure#3732)

Bumps [Azure.Storage.Blobs](https://github.com/Azure/azure-sdk-for-net) from 12.0.0 to 12.13.0.

Bump MacOs version to macos-11 (Azure#3753)

Resolve Azure#3715

Tracking issue: actions/runner-images#5583

Introduced codeowner-extractor. (Azure#3719)

* Introduced codeowner-extractor.

* Refactor using implicit principal and vault based config (Azure#3751)

* Refactor using implicit principal and vault based config
* Cleanup logging and skipping logic in Processor. Use bulk github user mapping api.
* Avoid using arrays with IConfiguration
* Improve logging in GitHubToAADConverter and pipeline owner extractor

Co-authored-by: Nicholi Harris <t-nharris@microsoft.com>
Co-authored-by: Patrick Hallisey <pahallis@microsoft.com>

Set net core version for pipeline-owners-extractor (Azure#3771)

APIVIew - Make GitHub token optional (Azure#3757)

* Make github token optional when testing locally

Update sandboxing pipeline to send request to APIView (Azure#3775)

* Update sandboxing pipeline to send request to APIView

Revert Accidentally Broken Sample assets (Azure#3776)

* reverting assets.json to ensure tests continue succeeding

Update nuget dependencies for pipeline witness (Azure#3745)

Return 401 error code if org info is not available for PR owner (Azure#3778)

* Return 401 error code if org info is not available for PR owner

[Perf] Display results with 4 significant figures (Azure#3770)

- Fixes Azure#3554

Remove build log queue based fanout (Azure#3789)

Add pipeline-owners-extraction pipeline (Azure#3784)

* Add pipeline-owners-extraction pipeline

Fix misleading step name in az module install (Azure#3787)

The name of this step is misleading and needed renaming.

Server changes to create manual and upgrade required API reviews using pipeline(sandboxing) (Azure#3774)

* Generate reviews using sandboxing pipeline

docs: add disclaimer and specificity (Azure#3796)

Co-authored-by: Dohyun Kim <tnghwk0661@gmail.com>
Co-authored-by: Jeesang Kim <jeenowden@gmail.com>

Co-authored-by: Dohyun Kim <tnghwk0661@gmail.com>
Co-authored-by: Jeesang Kim <jeenowden@gmail.com>

Add code owner processing to PipelineWitness (Azure#3742)

Add kusto schema for tables and views (Azure#3425)

Add Option for Hiding Left Navigation (Azure#3686)

* Add option for hiding left navigation

* Improve reviews page command bar

* Persist page settings as user preferences

* Smart update cache

* Add auto mapper for mapping between models

Fix issue when uploading json file to APIView (Azure#3800)

Feature/3465 support for java variants (Azure#3797)

Added Variant field to reviews and codefiles for different language variants

Improving Java reference docs in apiview

Fix label case in review dropdown (Azure#3814)

Fix bad path to sample matrix json (Azure#3765)

[perf] Right-align numerical values in tables (Azure#3802)

- Change percentages from two to one decimal place, since our results are not stable enough to justify two decimals
- Update sample results to 4 significant figures
- Fixes Azure#3703

Fetch all reviews when running background tasks (Azure#3818)

Feature/import warnings (Azure#3648)

* update class names

* docs

* tests

* fixme

* change to convention

* only allow imports from transport

* spacing

* naming

* better naming

* typo in tests

* update linter names

* fix test (please)

* better class name

Create API review using modules in consistent order (Azure#3832)

* Create API review using modules in consistent order

Update Python parser version and Python version to match version used by CI (Azure#3833)

Add link checking for stress CI (Azure#3826)

* Add link checking for stress CI

* Remove region segment from stress testing links

Add `RegexEntrySanitizer` (Azure#3807)

* add RegexEntrySanitizer and accompanying tests

* Update tools/test-proxy/Azure.Sdk.Tools.TestProxy/Sanitizers/RegexEntrySanitizer.cs

Fix example group (Azure#3845)

* fix: reuse m4 operation group to group examples

* build: release @autorest/testmodeler_v2.3.1

[Pylint] adding in TypeError to exception for next() if type cant be inferred (Azure#3843)

* adding in TypeError to exception for next() if type cant be inferred

* update version

* fix paging test

* pass -> return so that on exceptions we dont throw a warning

* fixing merge conflict

* spacing:

* spacing

Bump Azure.Storage.Blobs (Azure#3729)

Bumps [Azure.Storage.Blobs](https://github.com/Azure/azure-sdk-for-net) from 12.6.0 to 12.13.0.
- [Release notes](https://github.com/Azure/azure-sdk-for-net/releases)
- [Commits](Azure/azure-sdk-for-net@Azure.Storage.Blobs_12.6.0...Azure.Storage.Blobs_12.13.0)

---
updated-dependencies:
- dependency-name: Azure.Storage.Blobs
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

Updating Proxy Dev Cert (Azure#3860)

support creating go apiview in pipeline (Azure#3878)

* support creating go apiview in pipeline

* format

Vendor CrossPlat PemReader from azure-core (Azure#3882)

* standardize line endings for RecordingHandler.cs. Update pem to an expired certificate that should be valid crossplat. remove trial RemoveOnLinuxFact
* use vendored internal-only azure-core classes for loading a X509Certificate2 from the TLS Certificate input string.

[check-enforcer] Remove unused dependency Azure.Storage.Blobs (Azure#3890)

[Python APIView] Add error diagnostic if pylint parsing fails rather than fail APIView (and thus CI) (Azure#3884)

* Make pylint parsing failure create an APIView error instead of failing the tool (and thus CI).

* Closes Azure#3842.

Update CODEOWNERS (Azure#3891)

- Remove previous owners
- Sort tools dirs alphabetically
- Add owners for perf-automation and CODEOWNERS

new pipeline for codegen (Azure#3375)

* new pipeline for codegen

* bugfix: taskresult is required, check exist before prepare sourcecode

* Simplify Judgment Conditions

* delete unnecessary variable

* separate artifacts from total one to three part

* move mkdir out of loop for it has the same path

* may not generate artifact so event task failed, the pipeline should continue next task

* use pr number to checkout swagger repo

* [bugfix] fix missed parameter

* delete test code

* pipeline support use swagger pr to checkout spec repo

* try upload logs file to artifact even sdk generation failed

* debug for pipeline

* build dpg

* codegen pipeline support java dpg

* add release pipeline name and build type in result

* use azure-sdk account for create sdk pr

* support add ex cmd for docker

* event generate and build stage failed, try to upload source code and artifact

* don't exit 1 event generate cmd return 1

* use one token for all git cmd

* set sdk url by variable

* use env variable to control whether to show debug info

* remove hard code branch

* roll back for debug

* test

* set basedir for git wapper

* lint fix

* update js ci test repo commitid

* lint fix

Update docs/trusting-cert-per-language for Mac troubleshooting (Azure#3739)

* update docs/trusting-cert-per-language for Mac troubleshooting

* fix images under the _images folder

Co-authored-by: ponopono0322 <ponopono0322@gmail.com>

[Test-Proxy] Add Optional Specificity to the TLSValidationCert (Azure#3894)

* add optional specificity to the hostname

[Python APIView] Fix issue with duplicated diagnostics (Azure#3908)

* Troubleshoot issue

* Bump pylint-guidelines-checker version.

* Fixes Azure#3712.

Update CHANGELOG.md (Azure#3921)

updated targeted proxy version to one that properly allows consumption of TLS certificates (Azure#3945)

docker manifest deployment honors stabletags option (Azure#3913)

Remove duplicate PR API review revisions (Azure#3949)

* Remove duplicate pull request API review revisions

Improvements around aliased types (Azure#3940)

* Improvements around aliased types

Issue a diagnostic error if an exported, aliased type contains nested
types that aren't exported from the same package.
Include methods for aliased types in the source package.
Removed references to ioutil as it's been deprecated.

* skip unexported fields

* handle arrays

* fix happy line

* little more refinement

* refine per feedback

* array with pointer-to-type

* add tests

Sync azure-dev (Azure#3931)

[Perf] Update storage GA package versions (Azure#3959)

Feature/3810 replace language image references with css (Azure#3876)

Replace language icon conditionals with CSS classes with background-image

fix bug: miss autorest command in _meta (Azure#3966)

Co-authored-by: Wei Dong <weidong@microsoft.com>

upgrade version (Azure#3967)

Co-authored-by: Wei Dong <weidong@microsoft.com>

Explicit Error Message for Mismatch BEGIN and END Aliases (Azure#3889)

Explicit Error Message for Mismatch BEGIN and END Aliases

Fix issue with read-only properties. (Azure#3961)

Add dark theme for APIView (Azure#3747)

* Add dark theme for APIView

* Add button for switching themes

* persist Dark Theme

* Allow Updates to UserPreference on all Pages

* Handle cases where preference model is null

* Fix colors for popover

codesnippet-maven-plugin Performance Improvements (Azure#3970)

Pipeline to covert manual JS reviews to code file (Azure#3897)

add admin label to scheduler project (Azure#3974)

eng-common sync is running on hosted pools (Azure#3863)

Fix codesnippet-maven-plugin Bug with Full Class Codesnippets (Azure#3979)

js apiview parser build pipeline (Azure#3847)

* Pipeline yaml to build and publish JS APIView parser

Block non-abstract transport imports (Azure#3930)

* block transport imports

* use separate rule

* register linter

* styling

* fix comments

* readme

* typos

Removes excess newlines

Updating page to work with other changes (Azure Azure#285)

Adding comment note for suppression reasoning. Suppressing warnings for dependencies in Azure#285

Changing "sample" to "revision" to account for new revision system

add option --explicit-types to allow customize tagged types in exported code model. (Azure#3976)

* explicti-types

* changelog

* lint

* fix-swaggerpath

* fix

* use operation response schema

* changelog

* publish

Only skip /internal sub-directories (Azure#3993)

Allows support for the poorly named "internal" module.

[Perf] Update EventHubs package versions (Azure#3995)

clone sdk repo in grow up scenario (Azure#3667)

* save

* clone sdk repo in grow up scenario

* lint fix

* doc fix

* clone spec repo in grow up

* add skip-generation param in rerunning task

* update doc

* mute output

* add new param --is-public-repo

* lint

* result change

* fix test

Co-authored-by: Wei Dong <weidong@microsoft.com>

Remove Duplicate Event Listener Code (Azure#3987)

* Remove duplicate event listener code

* Ensure that js files are not cached

Initial integration tests (Azure#3932)

* Initial integration test

* Add Restore Tests

* Update TODO in GitProcessHandler

Update stress readme to remove misleading sections (Azure#4003)

[Perf] Add pipeline to validate changes to perf-automation (Azure#3874)

- Fixes Azure#3559

stress status dashboard update (Azure#3998)

* stress status dashboard update

* Adding back log analytics in stress dashboard

* delete comment

Add integration reset tests (Azure#4013)

* Add integration reset tests

* Updates based upon feedback

Hiding warning for ColorCode inclusion

Removing unused variable causing build failure

Reduce throttling by adding distributed locks (Azure#3973)

* Add async locks

* Add cosmos initialization and secrets resolution

* Increate queue worker count in prod to 10 per instance

Support language-specific CSS files Azure#3464 (Azure#3978)

Support language-specific CSS files
Co-authored-by: Jonathan Giles <jonathan.giles@microsoft.com>

Adding Solarized Dark theme (Azure#4005)

* Tweaking error/warning banner colors
* Minor adjustments to style based on fast pass feedback

Adding missed comma

Feature/2389 show reference docs for specific method class (Azure#3941)

Reference doc code folding feature - fully implemented

Adding Java-Specific typekinds Azure#3463 (Azure#3988)

Adding accomodation for new features

Adding authorization, Modifying to soft deletes, Tidying unused code, and refactoring backend systems for revisions

Remove a few extra properties

Bugfixing deleting last revision not properly deleting, updating styles

Cleaner error handling for blob/container misconfiguration

Adding usage samples comments to conversation page

Adding icons to usage sample buttons

Updating for feedback. (Remove excess check and fix indentation)

Removing old code and implementing feedback
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ✅ Done
Development

Successfully merging a pull request may close this issue.

4 participants