Skip to content

Improve central logging management and enrich docs#29

Open
Bilpapster wants to merge 2 commits into
mainfrom
logging
Open

Improve central logging management and enrich docs#29
Bilpapster wants to merge 2 commits into
mainfrom
logging

Conversation

@Bilpapster

Copy link
Copy Markdown
Owner

Description

Created a centralized logging management mechanism with configurable levels (e.g., INFO, DEBUG, ERROR). Also renamed assess parameter to must_be in the check() function of StreamDaQ which slipped through the previous PR for consistency. The check() function of Task already uses the must_be parameter. Also updated the docs/concepts/ and examples/ directories.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

Testing

  • I have tested this change locally
  • I have added tests that prove my fix is effective or that my feature works
  • All new and existing tests pass

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation

Issues

Fixes #27 and is mainly based on the implementation provided in #28

@Gatmatz Gatmatz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Very clean and nice work, Vassilis! When you have a moment, please take a look at my comments.

Comment thread streamdaq/StreamDaQ.py
self,
measure: pw.ColumnExpression | ReducerExpression,
assess: str | Callable[[Any], bool] | None = None,
must_be: str | Callable[[Any], bool] | None = None,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This may break compatibility with the pre-task version of StreamDaQ. Specifically, it introduces a breaking API change for users who call StreamDaQ.check(assess=...), as this would now raise a TypeError.

To maintain backward compatibility, consider accepting both keywords (assess and must_be) during a transition period.

@Bilpapster Bilpapster Oct 20, 2025

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

I did not clarify it enough, sorry. This check() function was added in the same PR that introduced the Task API. Note that the add() function still has the assess parameter, like it used to be.

In other words, this change tries to align the check() function of Task (which correctly uses must_be), with the check() function of StreamDaQ (which is relatively new, not advertised and is not expected to affect users).

Does this make sense or am I missing something here?

@Bilpapster Bilpapster force-pushed the main branch 2 times, most recently from 65f98bd to 0b8b9e9 Compare April 12, 2026 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Better logging

2 participants