Skip to content

Fix lint issues in ecs_logging/_stdlib.py - #172

Merged
dliappis merged 1 commit into
elastic:mainfrom
dliappis:fix-mypy
Jun 25, 2025
Merged

Fix lint issues in ecs_logging/_stdlib.py#172
dliappis merged 1 commit into
elastic:mainfrom
dliappis:fix-mypy

Conversation

@dliappis

Copy link
Copy Markdown
Contributor

This commit addresses linting issues reported by mypy e.g. in https://github.com/elastic/ecs-logging-python/actions/runs/15781106393/job/44486719657?pr=171

@dliappis
dliappis merged commit 5482679 into elastic:main Jun 25, 2025
13 checks passed
@v1v
v1v requested a review from a team June 25, 2025 13:02
Comment thread ecs_logging/_stdlib.py
} | _LOGRECORD_DIR
converter = time.gmtime

convert = _converter

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@dliappis haven't you changed the name of this attribute?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@xrmx good catch. Fixed in 588cc41
I wonder why it didn't fail tests tbh.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Ugh turns out automerge kicked in. Will raise another PR.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@xrmx PR #173 is up with a fix to the above typo.

dliappis added a commit to dliappis/ecs-logging-python that referenced this pull request Jun 25, 2025
This commit fixes a typo observed in
elastic#172 (comment)
dliappis added a commit to dliappis/ecs-logging-python that referenced this pull request Jun 25, 2025
This commit fixes a mistake observed in
elastic#172 (comment)

With that identified, the code is now hopefully simpler.
dliappis added a commit to dliappis/ecs-logging-python that referenced this pull request Jun 25, 2025
This commit fixes a mistake observed in
elastic#172 (comment)
dliappis added a commit to dliappis/ecs-logging-python that referenced this pull request Jun 25, 2025
This commit fixes a mistake observed in
elastic#172 (comment)

and allows to simply the code further (no need for a helper function)
xrmx added a commit that referenced this pull request Jun 26, 2025
* Fix typo identified in #172

This commit fixes a mistake observed in
#172 (comment)

and allows to simply the code further (no need for a helper function)

* Add 3.8/3.9 compatibility for mypy

* Fix lint

* Also fix precommit and old mypy

* Update ecs_logging/_stdlib.py

* Update ecs_logging/_stdlib.py

---------

Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants