Skip to content

Commit e1f62ea

Browse files
committed
reflect PR feedback
1 parent c414c62 commit e1f62ea

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

.github/workflows/test-publish.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,3 +61,4 @@ jobs:
6161
uses: pypa/gh-action-pypi-publish@release/v1
6262
with:
6363
repository-url: https://test.pypi.org/legacy/
64+
skip-existing: true

src/designer_plugin/d3sdk/function.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -256,11 +256,11 @@ def __init__(self, module_name: str, func: Callable[P, T]):
256256

257257
super().__init__(func)
258258

259-
# Update the function in case the function was updated in same session.
259+
# Update the function in case the function was updated in the same session.
260260
# For example, jupyter notebook server can be running, but function signature can
261261
# change constantly.
262262
if self in D3Function._available_d3functions[module_name]:
263-
logger.warning(
263+
logger.debug(
264264
"Function '%s' in module '%s' is being replaced.",
265265
self.name,
266266
module_name,

tests/test_core.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -352,16 +352,16 @@ def my_func(a: int, b: int) -> int: # noqa: F811
352352
assert len(matching) == 1
353353
assert matching[0].function_info.args == ["a", "b"]
354354

355-
def test_reregister_logs_warning(self, caplog):
356-
"""Re-registering should log a warning."""
355+
def test_reregister_logs_debug(self, caplog):
356+
"""Re-registering should log a debug message."""
357357
module = "test_replace_warn_module"
358358
D3Function._available_d3functions[module].clear()
359359

360360
@d3function(module)
361361
def warn_func() -> None:
362362
pass
363363

364-
with caplog.at_level(logging.WARNING, logger="designer_plugin.d3sdk.function"):
364+
with caplog.at_level(logging.DEBUG, logger="designer_plugin.d3sdk.function"):
365365
@d3function(module)
366366
def warn_func() -> int: # noqa: F811
367367
return 1

0 commit comments

Comments
 (0)