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

Remove unnecessary utf-8 header in license_headers.py (follow-up to #615) #617

Conversation

jayaddison
Copy link
Contributor

Description

This is a small followup to @samuelorji's cleanup in #615. It applies the same cleanup (removal of a redundant/default coding declaration of utf-8 in source files) to the license_headers.py check script itself.

This pull request also removes that line from the list of LINES_TO_KEEP - lines of source code that aren't checked by the license check script - since it shouldn't appear anymore.

Issues Resolved

#613

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

…y check/fix script; since #615 it is no longer used in the library's codebase

UTF-8 is the default encoding used to read source code files for Python3 - see https://docs.python.org/3/howto/unicode.html#unicode-literals-in-python-source-code

Signed-off-by: James Addison <james@reciperadar.com>
…script itself

Signed-off-by: James Addison <james@reciperadar.com>
Copy link

codecov bot commented Nov 28, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (6f26eb3) 71.98% compared to head (6b876d3) 71.98%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #617   +/-   ##
=======================================
  Coverage   71.98%   71.98%           
=======================================
  Files          89       89           
  Lines        7935     7935           
=======================================
  Hits         5712     5712           
  Misses       2223     2223           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@saimedhi saimedhi added the skip-changelog Skips changelog verifier label Nov 28, 2023
Signed-off-by: James Addison <james@reciperadar.com>
Copy link
Member

@dblock dblock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch, thank you.

@saimedhi
Copy link
Collaborator

@jayaddison, I think changelog entry is not needed.

@dblock dblock merged commit 0837c5b into opensearch-project:main Nov 28, 2023
55 of 56 checks passed
@dblock
Copy link
Member

dblock commented Nov 28, 2023

I opened two more issues related to API generator, #619 and #618, if you have any interest @jayaddison :)

@jayaddison
Copy link
Contributor Author

Thanks @saimedhi - I had pushed a commit with a changelog entry a few moments before seeing that you added a label to skip it. It was merged - I hope that's OK?

@dblock those issues do look interesting, thanks; I cannot offer any sense of when I might work on them yet, though.

Something that I notice about the utils/generate_api.py script is that it could be difficult to easily confirm what version (git commit ID) of the OpenSearch.openapi.json spec file was used to produce the output. Has including a version/commit identifier, or referencing the spec file using a git submodule been considered?

@dblock
Copy link
Member

dblock commented Nov 28, 2023

I would largely prefer a submodule for the exact reason you describe. Feel free to open a feature request or just do it (TM).

roma2023 pushed a commit to roma2023/opensearch-py that referenced this pull request Dec 28, 2023
…pensearch-project#615) (opensearch-project#617)

* License tools: remove utf-8 coding declaration from license_headers.py check/fix script; since opensearch-project#615 it is no longer used in the library's codebase

UTF-8 is the default encoding used to read source code files for Python3 - see https://docs.python.org/3/howto/unicode.html#unicode-literals-in-python-source-code

Signed-off-by: James Addison <james@reciperadar.com>

* Cleanup: remove utf-8 coding declaration from the license_headers.py script itself

Signed-off-by: James Addison <james@reciperadar.com>

* Update CHANGELOG.md

Signed-off-by: James Addison <james@reciperadar.com>

---------

Signed-off-by: James Addison <james@reciperadar.com>
Signed-off-by: roma2023 <romasaparhan19@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip-changelog Skips changelog verifier
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants