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

Silence noisy warnings for pyicu #2990

Closed
pombredanne opened this issue Jun 10, 2022 · 4 comments · Fixed by #3280
Closed

Silence noisy warnings for pyicu #2990

pombredanne opened this issue Jun 10, 2022 · 4 comments · Fixed by #3280

Comments

@pombredanne
Copy link
Member

See this when running SCTK latest develop:
scancode-toolkit-master/venv/lib/python3.6/site-packages/fingerprints/cleanup.py:54: ICUWarning: Install 'pyicu' for better text transliteration. text = ascii_text(text)

@pombredanne pombredanne added this to the v31.0 milestone Jun 10, 2022
@pombredanne pombredanne modified the milestones: v31.0, v32.0 Aug 11, 2022
@pombredanne
Copy link
Member Author

Not seen anymore as reported by @AyanSinhaMahapatra ... moving to later and lower priority

@AyanSinhaMahapatra AyanSinhaMahapatra changed the title Silense noisy warnings for pyicu Silence noisy warnings for pyicu Jan 4, 2023
@AyanSinhaMahapatra
Copy link
Member

This is fixed and not seen anymore, closing.

@AyanSinhaMahapatra
Copy link
Member

AyanSinhaMahapatra commented Jan 19, 2023

I saw this again, this is happening when we use the --summary option due to the use of fingerprints.generate in the src/summarycode/summarizer.py.

See #3016 (comment)

@rritik772
Copy link
Contributor

hey, I am new to contributing. So, I need a little bit of help.

I have done some research and came to conclusion that the warning is generated by library Normality which is used in Fingerprints and it is here.

Also I have different solution based on it.

  1. Using warnings.simplefilter("ignore") it will filter and ignore all the warnings
  2. Using with warnings.catch_warnings(): warnings.filterwarnings("ignore", category=ICUWarning) this will ignore all the ICUwarning
  3. Using warnings.simplefilter("ignore", ICUWarning) in global scope of summary

What should I do.

Also can you please assign this issue to me.

AyanSinhaMahapatra added a commit that referenced this issue Feb 28, 2023
Signed-off-by: Ayan Sinha Mahapatra <[email protected]>
AyanSinhaMahapatra added a commit that referenced this issue Mar 9, 2023
Signed-off-by: Ayan Sinha Mahapatra <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants