mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 12:58:16 -07:00
dev-python/jupyter-events: Remove old
Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
@@ -1,2 +1 @@
|
||||
DIST jupyter_events-0.10.0.tar.gz 61516 BLAKE2B 12cf323f65cd52a6c0aa29e7b75e7899ec245752a7c4e17d32650ae3e9b27f47a7e593b491747667dfc58bde5e0745077c72317dbfa6db1f266d7ada14bc8f6a SHA512 6e56b48a238353fbd5e6a1a8cb3fcc5a506063aa555c96172ec2e03a14fb527b39d03a9897de49353927e8993a770d028d6d0d2c9a92785c4b727e3da66676df
|
||||
DIST jupyter_events-0.11.0.tar.gz 62039 BLAKE2B 0a6d4598c763c59595d66e8ea30c0c056e48600a024e138258a6d0b306a002b10bf2eabaad78bb7ca1280b214660cd682737518c503437ba4921451473cb0d92 SHA512 a19458ca9e2b9c44af1a7b4b80259aa4f67b318a5bf6ca7a9b4e24c6e6923b64947b6de8f9476e354b090542bfd9af5b7db2479df0e08ff3617d7c0f32cc267e
|
||||
|
||||
@@ -1,93 +0,0 @@
|
||||
From 6c6219710e08784b3b8beed25d17240ea7f9ef93 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
|
||||
Date: Fri, 12 Jul 2024 11:05:40 +0200
|
||||
Subject: [PATCH 1/2] Improve compatibility with patched python-json-logger on
|
||||
py3.12+
|
||||
|
||||
Discard the `taskName` field from event capsule, to preserve
|
||||
compatibility both with current python-json-logger versions, and with
|
||||
versions containing the Python 3.12 fix
|
||||
from madzak/python-json-logger#188 that removes the reserved `taskName`
|
||||
field.
|
||||
---
|
||||
tests/test_logger.py | 15 +++++----------
|
||||
1 file changed, 5 insertions(+), 10 deletions(-)
|
||||
|
||||
diff --git a/tests/test_logger.py b/tests/test_logger.py
|
||||
index 8a0a499..986aade 100644
|
||||
--- a/tests/test_logger.py
|
||||
+++ b/tests/test_logger.py
|
||||
@@ -166,8 +166,7 @@ def test_emit():
|
||||
"__metadata_version__": 1,
|
||||
"something": "blah",
|
||||
}
|
||||
- if sys.version_info >= (3, 12):
|
||||
- expected["taskName"] = None
|
||||
+ event_capsule.pop("taskName", None)
|
||||
assert event_capsule == expected
|
||||
|
||||
|
||||
@@ -214,8 +213,7 @@ def test_message_field():
|
||||
"something": "blah",
|
||||
"message": "a message was seen",
|
||||
}
|
||||
- if sys.version_info >= (3, 12):
|
||||
- expected["taskName"] = None
|
||||
+ event_capsule.pop("taskName", None)
|
||||
assert event_capsule == expected
|
||||
|
||||
|
||||
@@ -263,8 +261,7 @@ def test_nested_message_field():
|
||||
"__metadata_version__": 1,
|
||||
"thing": {"message": "a nested message was seen"},
|
||||
}
|
||||
- if sys.version_info >= (3, 12):
|
||||
- expected["taskName"] = None
|
||||
+ event_capsule.pop("taskName", None)
|
||||
assert event_capsule == expected
|
||||
|
||||
|
||||
@@ -428,8 +425,7 @@ def test_unique_logger_instances():
|
||||
"__metadata_version__": 1,
|
||||
"something": "blah",
|
||||
}
|
||||
- if sys.version_info >= (3, 12):
|
||||
- expected["taskName"] = None
|
||||
+ event_capsule0.pop("taskName", None)
|
||||
assert event_capsule0 == expected
|
||||
|
||||
event_capsule1 = json.loads(output1.getvalue())
|
||||
@@ -443,8 +439,7 @@ def test_unique_logger_instances():
|
||||
"__metadata_version__": 1,
|
||||
"something": "blah",
|
||||
}
|
||||
- if sys.version_info >= (3, 12):
|
||||
- expected["taskName"] = None
|
||||
+ event_capsule1.pop("taskName", None)
|
||||
assert event_capsule1 == expected
|
||||
|
||||
|
||||
|
||||
From 5ad1b27eb8424f1c33067eb68859f9ed0d7ede74 Mon Sep 17 00:00:00 2001
|
||||
From: "pre-commit-ci[bot]"
|
||||
<66853113+pre-commit-ci[bot]@users.noreply.github.com>
|
||||
Date: Fri, 12 Jul 2024 09:08:44 +0000
|
||||
Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks
|
||||
|
||||
for more information, see https://pre-commit.ci
|
||||
---
|
||||
tests/test_logger.py | 1 -
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
diff --git a/tests/test_logger.py b/tests/test_logger.py
|
||||
index 986aade..ecd56ab 100644
|
||||
--- a/tests/test_logger.py
|
||||
+++ b/tests/test_logger.py
|
||||
@@ -3,7 +3,6 @@
|
||||
import io
|
||||
import json
|
||||
import logging
|
||||
-import sys
|
||||
from datetime import datetime, timedelta, timezone
|
||||
from unittest.mock import MagicMock
|
||||
|
||||
@@ -1,47 +0,0 @@
|
||||
# Copyright 1999-2024 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
DISTUTILS_USE_PEP517=hatchling
|
||||
PYTHON_COMPAT=( pypy3 python3_{10..13} )
|
||||
|
||||
inherit distutils-r1 pypi
|
||||
|
||||
DESCRIPTION="Jupyter Event System library"
|
||||
HOMEPAGE="
|
||||
https://jupyter.org/
|
||||
https://github.com/jupyter/jupyter_events/
|
||||
https://pypi.org/project/jupyter-events/
|
||||
"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 arm arm64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86"
|
||||
|
||||
# jsonschema[format-nongpl] deps are always on in our ebuild
|
||||
RDEPEND="
|
||||
>=dev-python/jsonschema-4.18.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-json-logger-2.0.4[${PYTHON_USEDEP}]
|
||||
>=dev-python/pyyaml-5.3[${PYTHON_USEDEP}]
|
||||
dev-python/referencing[${PYTHON_USEDEP}]
|
||||
>=dev-python/traitlets-5.3[${PYTHON_USEDEP}]
|
||||
"
|
||||
BDEPEND="
|
||||
test? (
|
||||
dev-python/click[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-asyncio[${PYTHON_USEDEP}]
|
||||
dev-python/pytest-console-scripts[${PYTHON_USEDEP}]
|
||||
dev-python/rich[${PYTHON_USEDEP}]
|
||||
)
|
||||
"
|
||||
|
||||
# TODO: package jupyterlite-sphinx
|
||||
# distutils_enable_sphinx docs
|
||||
distutils_enable_tests pytest
|
||||
|
||||
PATCHES=(
|
||||
# fix compatibility with patched python-json-logger
|
||||
# https://github.com/jupyter/jupyter_events/pull/100
|
||||
"${FILESDIR}/${P}-test.patch"
|
||||
)
|
||||
Reference in New Issue
Block a user