aiidalab / aiidalab-widgets-base

Reusable widgets for AiiDAlab applications
MIT License
7 stars 17 forks source link

Add info box widgets with CSS stylesheets #623

Closed edan-bainglass closed 3 months ago

edan-bainglass commented 4 months ago

Based on #624

This PR adds info box widgets to provide in-app information to users

codecov[bot] commented 4 months ago

Codecov Report

Attention: Patch coverage is 79.01235% with 17 lines in your changes missing coverage. Please review.

Project coverage is 83.64%. Comparing base (de5f0cc) to head (93d2986). Report is 10 commits behind head on master.

Files with missing lines Patch % Lines
aiidalab_widgets_base/__init__.py 14.28% 12 Missing :warning:
aiidalab_widgets_base/utils/loaders.py 73.33% 4 Missing :warning:
aiidalab_widgets_base/infobox.py 98.07% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #623 +/- ## ========================================== + Coverage 83.61% 83.64% +0.02% ========================================== Files 16 18 +2 Lines 3522 3595 +73 ========================================== + Hits 2945 3007 +62 - Misses 577 588 +11 ``` | [Flag](https://app.codecov.io/gh/aiidalab/aiidalab-widgets-base/pull/623/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=aiidalab) | Coverage Δ | | |---|---|---| | [python-3.11](https://app.codecov.io/gh/aiidalab/aiidalab-widgets-base/pull/623/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=aiidalab) | `83.64% <79.01%> (+0.02%)` | :arrow_up: | | [python-3.9](https://app.codecov.io/gh/aiidalab/aiidalab-widgets-base/pull/623/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=aiidalab) | `83.68% <79.01%> (+0.02%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=aiidalab#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

edan-bainglass commented 4 months ago

@superstar54 @unkcpz can you guys have a look at the failed tests? I don't see how my changes could suddenly trigger the following error, which is failing several structure-related tests!

DeprecationWarning: dict interface (SpglibDataset['international']) is deprecated.Use attribute interface ({self.__class__.__name__}.{key}) instead
superstar54 commented 4 months ago

Hi @edan-bainglass , spglib released a new version yesterday. Apparently, it drops support for some old API.

superstar54 commented 4 months ago

I just created an issue on this: https://github.com/aiidalab/aiidalab-widgets-base/issues/625

edan-bainglass commented 4 months ago

@superstar54 I see. So we need to update on our end? I take it this is unrelated to my PR. I would rebase on top of an update PR once that's in?

Regarding an spglib update PR, do we need it? Can we instead pin to <2.5.0?

superstar54 commented 4 months ago

Regarding an spglib update PR, do we need it? Can we instead pin to <2.5.0?

No idea yet.

danielhollas commented 4 months ago

You can just add the DeprecationWarning to the list of ignored warnings in pyproject.toml

(We have configured pytest so that it turns any warnings into errors, maybe we should change it)

edan-bainglass commented 3 months ago

Moving this PR to the QE App for local testing. If all is good and approved for general use, InfoBox classes will move back to the widgets base.