From 11ba7c88ac16a55ac58705d632741717ee194649 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 09:21:39 +0100 Subject: [PATCH 01/13] chore: update changelog --- CHANGELOG.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6841bb01..5549c031 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,8 @@ #### v0.3.0 -- fixed inconsistency of `entity_type` as required argument ([#188](https://github.com/RWTH-EBC/FiLiP/issues/188)) -- BREAKING CHANGE: Migration of pydantic v1 to v2 ([#199](https://github.com/RWTH-EBC/FiLiP/issues/199)) +- fix: bug in typePattern validation @richardmarston ([#180](https://github.com/RWTH-EBC/FiLiP/pull/180)) +- add: add messages to all KeyErrors @FWuellhorst ([#192](https://github.com/RWTH-EBC/FiLiP/pull/192)) +- fix: get() method of Units dose not work properly by @djs0109 ([#193](https://github.com/RWTH-EBC/FiLiP/pull/193)) +- BREAKING CHANGE: Migration of pydantic v1 to v2 @djs0109 ([#199](https://github.com/RWTH-EBC/FiLiP/issues/199)) #### v0.2.5 - fixed service group edition not working ([#170](https://github.com/RWTH-EBC/FiLiP/issues/170)) From 57ecec421a1cb32e4995417b8d3fd3b885e620d6 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 09:41:23 +0100 Subject: [PATCH 02/13] chore: update packages version --- requirements.txt | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/requirements.txt b/requirements.txt index c57cd87d..4cd5a206 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,23 +1,23 @@ -requests>=2.23.0 -python-dotenv>=0.19.1 -pydantic>=2.0.2 -pydantic-settings>=2.0.1 -aenum>=3.0.0 -pathlib>=1.0.1 -regex>=2021.3.17 -pytz>=2019.1 -rapidfuzz>=1.7.1 -pandas>=1.2.0 +requests~=2.31.0 +python-dotenv~=1.0.0 +pydantic~=2.5.2 +pydantic-settings~=2.1.0 +aenum~=3.1.15 +pathlib~=1.0.1 +regex~=2023.10.3 +pytz~=2023.3.post1 +rapidfuzz~=3.5.2 +pandas~=2.1.3 setuptools>=40.6.0 -pandas_datapackage_reader>=0.18.0 -python-Levenshtein>=0.12.2 -numpy>=1.21 -rdflib~=6.0.0 -python-dateutil>=2.8.2 -wget >=3.2 -stringcase>=1.2.0 -igraph==0.9.8 -paho-mqtt>=1.6.1 -datamodel_code_generator[http]>=0.21.3 +pandas_datapackage_reader~=0.18.0 +python-Levenshtein~=0.23.0 +numpy~=1.26.2 +rdflib~=6.0.2 +igraph~=0.9.8 +python-dateutil~=2.8.2 +wget~=3.2 +stringcase~=1.2.0 +paho-mqtt~=1.6.1 +datamodel_code_generator[http]~=0.25.0 # tutorials -matplotlib>=3.5.1 \ No newline at end of file +matplotlib>=3.8.2 \ No newline at end of file From f500ce49a60e950483a06f3bec05d559842c2791 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 09:42:47 +0100 Subject: [PATCH 03/13] chore: temporarily remove dependency of semantics module --- requirements.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/requirements.txt b/requirements.txt index 4cd5a206..1a7615d3 100644 --- a/requirements.txt +++ b/requirements.txt @@ -12,12 +12,13 @@ setuptools>=40.6.0 pandas_datapackage_reader~=0.18.0 python-Levenshtein~=0.23.0 numpy~=1.26.2 -rdflib~=6.0.2 -igraph~=0.9.8 python-dateutil~=2.8.2 wget~=3.2 stringcase~=1.2.0 paho-mqtt~=1.6.1 datamodel_code_generator[http]~=0.25.0 # tutorials -matplotlib>=3.8.2 \ No newline at end of file +matplotlib>=3.8.2 +# semantics +# rdflib~=6.0.2 +# igraph~=0.9.8 \ No newline at end of file From 08aeb92cfa74565ce8668faad91fed8cfe2a3150 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 09:46:16 +0100 Subject: [PATCH 04/13] chore: update setuptools version --- requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements.txt b/requirements.txt index 1a7615d3..3b8a247c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -8,7 +8,7 @@ regex~=2023.10.3 pytz~=2023.3.post1 rapidfuzz~=3.5.2 pandas~=2.1.3 -setuptools>=40.6.0 +setuptools~=68.0.0 pandas_datapackage_reader~=0.18.0 python-Levenshtein~=0.23.0 numpy~=1.26.2 From 3f2abd6d09f1139f8d9a890b2aaade9a30568da4 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 10:02:53 +0100 Subject: [PATCH 05/13] chore: update setup.py --- setup.py | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/setup.py b/setup.py index 06783acb..e442d7e2 100644 --- a/setup.py +++ b/setup.py @@ -7,25 +7,25 @@ readme_path = Path(__file__).parent.joinpath("README.md") LONG_DESCRIPTION = readme_path.read_text() -INSTALL_REQUIRES = ['aenum', - 'datamodel_code_generator[http]>=0.11.16', - 'paho-mqtt>=1.6.1', - 'pandas>=1.2', - 'pandas-datapackage-reader>=0.18.0', - 'pydantic>=2.0.2', - 'pydantic-settings>=2.0.1', - 'PyYAML', +INSTALL_REQUIRES = ['aenum~=3.1.15', + 'datamodel_code_generator[http]~=0.25.0', + 'paho-mqtt~=1.6.1', + 'pandas~=2.1.3', + 'pandas_datapackage_reader~=0.18.0', + 'pydantic~=2.5.2', + 'pydantic-settings~=2.1.0', 'stringcase>=1.2.0', - 'igraph==0.9.8', - 'rdflib~=6.0.0', - 'regex', - 'requests', - 'rapidfuzz', - 'wget'] + # semantics module + # 'igraph==0.9.8', + # 'rdflib~=6.0.0', + 'regex~=2023.10.3', + 'requests~=2.31.0', + 'rapidfuzz~=3.5.2', + 'wget~=3.2'] SETUP_REQUIRES = INSTALL_REQUIRES.copy() -VERSION = '0.2.5' +VERSION = '0.3.0' setuptools.setup( name='filip', From 07d5e68681a82b51861a0349e10f592813b4c8c6 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 11:19:09 +0100 Subject: [PATCH 06/13] chore: update autor information --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index d3cd5ab6..1b89c524 100644 --- a/README.md +++ b/README.md @@ -213,6 +213,7 @@ how you can contribute to this project. ## Authors * [Thomas Storek](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Team2/~lhda/Thomas-Storek/?lidx=1) (corresponding) +* [Junsong Du](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Digitale-Energie-Quartiere/~trcib/Du-Junsong/lidx/1/) * [Saira Bano](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Systemadministration/~ohhca/Bano-Saira/) * [Daniel Nikolay](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Systemadministration/~qcqxq/Nikolay-Daniel/) From 7495f81ab25e3ffe153ea04511b561b72d6c7fac Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 11:19:45 +0100 Subject: [PATCH 07/13] chore: update autor information --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 1b89c524..f4c1e048 100644 --- a/README.md +++ b/README.md @@ -215,12 +215,12 @@ how you can contribute to this project. * [Thomas Storek](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Team2/~lhda/Thomas-Storek/?lidx=1) (corresponding) * [Junsong Du](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Digitale-Energie-Quartiere/~trcib/Du-Junsong/lidx/1/) * [Saira Bano](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Systemadministration/~ohhca/Bano-Saira/) -* [Daniel Nikolay](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Systemadministration/~qcqxq/Nikolay-Daniel/) ## Alumni * Jeff Reding * Felix Rehmann +* Daniel Nikolay ## References From 110bfb690cf17e0383aec4ca2b4aa6261fc9985a Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Mon, 4 Dec 2023 18:23:44 +0100 Subject: [PATCH 08/13] chore: update version for the compatibility with py37 --- requirements.txt | 14 +++++++------- setup.py | 8 ++++---- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/requirements.txt b/requirements.txt index 3b8a247c..47f6c04e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,24 +1,24 @@ requests~=2.31.0 -python-dotenv~=1.0.0 +python-dotenv>=0.21.0 pydantic~=2.5.2 -pydantic-settings~=2.1.0 +pydantic-settings~=2.0.0 aenum~=3.1.15 pathlib~=1.0.1 regex~=2023.10.3 pytz~=2023.3.post1 -rapidfuzz~=3.5.2 -pandas~=2.1.3 +rapidfuzz~=3.4.0 +pandas~=1.3.5 setuptools~=68.0.0 pandas_datapackage_reader~=0.18.0 python-Levenshtein~=0.23.0 -numpy~=1.26.2 +numpy~=1.20.0 python-dateutil~=2.8.2 wget~=3.2 stringcase~=1.2.0 paho-mqtt~=1.6.1 datamodel_code_generator[http]~=0.25.0 # tutorials -matplotlib>=3.8.2 +matplotlib~=3.5.3 # semantics -# rdflib~=6.0.2 +rdflib~=6.0.0 # igraph~=0.9.8 \ No newline at end of file diff --git a/setup.py b/setup.py index e442d7e2..eebf4947 100644 --- a/setup.py +++ b/setup.py @@ -10,17 +10,17 @@ INSTALL_REQUIRES = ['aenum~=3.1.15', 'datamodel_code_generator[http]~=0.25.0', 'paho-mqtt~=1.6.1', - 'pandas~=2.1.3', + 'pandas~=1.3.5', 'pandas_datapackage_reader~=0.18.0', 'pydantic~=2.5.2', - 'pydantic-settings~=2.1.0', + 'pydantic-settings~=2.0.0', 'stringcase>=1.2.0', # semantics module # 'igraph==0.9.8', - # 'rdflib~=6.0.0', + 'rdflib~=6.0.0', 'regex~=2023.10.3', 'requests~=2.31.0', - 'rapidfuzz~=3.5.2', + 'rapidfuzz~=3.4.0', 'wget~=3.2'] SETUP_REQUIRES = INSTALL_REQUIRES.copy() From c9cf27e453cf7a00d71aadf011a3166ce397d0f7 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Tue, 5 Dec 2023 08:31:59 +0100 Subject: [PATCH 09/13] chore: test with old requirements.txt --- requirements.txt | 70 ++++++++++++++++++++++++++++++++---------------- 1 file changed, 47 insertions(+), 23 deletions(-) diff --git a/requirements.txt b/requirements.txt index 47f6c04e..9e5495fc 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,24 +1,48 @@ -requests~=2.31.0 -python-dotenv>=0.21.0 -pydantic~=2.5.2 -pydantic-settings~=2.0.0 -aenum~=3.1.15 -pathlib~=1.0.1 -regex~=2023.10.3 -pytz~=2023.3.post1 -rapidfuzz~=3.4.0 -pandas~=1.3.5 -setuptools~=68.0.0 -pandas_datapackage_reader~=0.18.0 -python-Levenshtein~=0.23.0 -numpy~=1.20.0 -python-dateutil~=2.8.2 -wget~=3.2 -stringcase~=1.2.0 -paho-mqtt~=1.6.1 -datamodel_code_generator[http]~=0.25.0 -# tutorials -matplotlib~=3.5.3 -# semantics +# requests~=2.31.0 +# python-dotenv>=0.21.0 +# pydantic~=2.5.2 +# pydantic-settings~=2.0.0 +# aenum~=3.1.15 +# pathlib~=1.0.1 +# regex~=2023.10.3 +# pytz~=2023.3.post1 +# rapidfuzz~=3.4.0 +# pandas~=1.3.5 +# setuptools~=68.0.0 +# pandas_datapackage_reader~=0.18.0 +# python-Levenshtein~=0.23.0 +# numpy~=1.20.0 +# python-dateutil~=2.8.2 +# wget~=3.2 +# stringcase~=1.2.0 +# paho-mqtt~=1.6.1 +# datamodel_code_generator[http]~=0.25.0 +# # tutorials +# matplotlib~=3.5.3 +# # semantics +# rdflib~=6.0.0 +# # igraph~=0.9.8 + +requests>=2.23.0 +python-dotenv>=0.19.1 +pydantic>=2.0.2 +pydantic-settings>=2.0.1 +aenum>=3.0.0 +pathlib>=1.0.1 +regex>=2021.3.17 +pytz>=2019.1 +rapidfuzz>=1.7.1 +pandas>=1.2.0 +setuptools>=40.6.0 +pandas_datapackage_reader>=0.18.0 +python-Levenshtein>=0.12.2 +numpy>=1.21 rdflib~=6.0.0 -# igraph~=0.9.8 \ No newline at end of file +python-dateutil>=2.8.2 +wget >=3.2 +stringcase>=1.2.0 +# igraph==0.9.8 +paho-mqtt>=1.6.1 +datamodel_code_generator[http]>=0.21.3 +# tutorials +matplotlib>=3.5.1 \ No newline at end of file From 0295e6e754ceff5522a7d3291a30811e5b3ffb00 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Tue, 5 Dec 2023 09:07:17 +0100 Subject: [PATCH 10/13] chore: change back to updated requirements --- requirements.txt | 70 ++++++++++++++++-------------------------------- 1 file changed, 23 insertions(+), 47 deletions(-) diff --git a/requirements.txt b/requirements.txt index 9e5495fc..47f6c04e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,48 +1,24 @@ -# requests~=2.31.0 -# python-dotenv>=0.21.0 -# pydantic~=2.5.2 -# pydantic-settings~=2.0.0 -# aenum~=3.1.15 -# pathlib~=1.0.1 -# regex~=2023.10.3 -# pytz~=2023.3.post1 -# rapidfuzz~=3.4.0 -# pandas~=1.3.5 -# setuptools~=68.0.0 -# pandas_datapackage_reader~=0.18.0 -# python-Levenshtein~=0.23.0 -# numpy~=1.20.0 -# python-dateutil~=2.8.2 -# wget~=3.2 -# stringcase~=1.2.0 -# paho-mqtt~=1.6.1 -# datamodel_code_generator[http]~=0.25.0 -# # tutorials -# matplotlib~=3.5.3 -# # semantics -# rdflib~=6.0.0 -# # igraph~=0.9.8 - -requests>=2.23.0 -python-dotenv>=0.19.1 -pydantic>=2.0.2 -pydantic-settings>=2.0.1 -aenum>=3.0.0 -pathlib>=1.0.1 -regex>=2021.3.17 -pytz>=2019.1 -rapidfuzz>=1.7.1 -pandas>=1.2.0 -setuptools>=40.6.0 -pandas_datapackage_reader>=0.18.0 -python-Levenshtein>=0.12.2 -numpy>=1.21 -rdflib~=6.0.0 -python-dateutil>=2.8.2 -wget >=3.2 -stringcase>=1.2.0 -# igraph==0.9.8 -paho-mqtt>=1.6.1 -datamodel_code_generator[http]>=0.21.3 +requests~=2.31.0 +python-dotenv>=0.21.0 +pydantic~=2.5.2 +pydantic-settings~=2.0.0 +aenum~=3.1.15 +pathlib~=1.0.1 +regex~=2023.10.3 +pytz~=2023.3.post1 +rapidfuzz~=3.4.0 +pandas~=1.3.5 +setuptools~=68.0.0 +pandas_datapackage_reader~=0.18.0 +python-Levenshtein~=0.23.0 +numpy~=1.20.0 +python-dateutil~=2.8.2 +wget~=3.2 +stringcase~=1.2.0 +paho-mqtt~=1.6.1 +datamodel_code_generator[http]~=0.25.0 # tutorials -matplotlib>=3.5.1 \ No newline at end of file +matplotlib~=3.5.3 +# semantics +rdflib~=6.0.0 +# igraph~=0.9.8 \ No newline at end of file From f70fa131e90f3b5fc9d6dfb6680578f25e953d7d Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Tue, 5 Dec 2023 12:07:28 +0100 Subject: [PATCH 11/13] chore: remove numpy in dependency --- requirements.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/requirements.txt b/requirements.txt index 47f6c04e..5c058bbc 100644 --- a/requirements.txt +++ b/requirements.txt @@ -11,7 +11,6 @@ pandas~=1.3.5 setuptools~=68.0.0 pandas_datapackage_reader~=0.18.0 python-Levenshtein~=0.23.0 -numpy~=1.20.0 python-dateutil~=2.8.2 wget~=3.2 stringcase~=1.2.0 From 81a3618c3ae8b5b3c732e5dc4f5f142251604324 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Fri, 8 Dec 2023 16:23:35 +0100 Subject: [PATCH 12/13] chore: add optional module "semantics" --- README.md | 4 ++-- filip/__init__.py | 2 +- setup.py | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index f4c1e048..dc7b6bca 100644 --- a/README.md +++ b/README.md @@ -212,8 +212,8 @@ how you can contribute to this project. ## Authors -* [Thomas Storek](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Team2/~lhda/Thomas-Storek/?lidx=1) (corresponding) -* [Junsong Du](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Digitale-Energie-Quartiere/~trcib/Du-Junsong/lidx/1/) +* [Thomas Storek](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Team2/~lhda/Thomas-Storek/?lidx=1) +* [Junsong Du](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Digitale-Energie-Quartiere/~trcib/Du-Junsong/lidx/1/) (corresponding) * [Saira Bano](https://www.ebc.eonerc.rwth-aachen.de/cms/E-ON-ERC-EBC/Das-Institut/Mitarbeiter/Systemadministration/~ohhca/Bano-Saira/) ## Alumni diff --git a/filip/__init__.py b/filip/__init__.py index 1ec7ef77..803e7ed2 100644 --- a/filip/__init__.py +++ b/filip/__init__.py @@ -4,4 +4,4 @@ from filip.config import settings from filip.clients.ngsi_v2 import HttpClient -__version__ = '0.2.4' +__version__ = '0.3.0' diff --git a/setup.py b/setup.py index eebf4947..b56d4c2e 100644 --- a/setup.py +++ b/setup.py @@ -15,8 +15,6 @@ 'pydantic~=2.5.2', 'pydantic-settings~=2.0.0', 'stringcase>=1.2.0', - # semantics module - # 'igraph==0.9.8', 'rdflib~=6.0.0', 'regex~=2023.10.3', 'requests~=2.31.0', @@ -62,6 +60,10 @@ 'tutorials']), package_data={'filip': ['data/unece-units/*.csv']}, setup_requires=SETUP_REQUIRES, + # optional modules + extras_require={ + "semantics": ["igraph~=0.9.8"] + }, install_requires=INSTALL_REQUIRES, python_requires=">=3.7", From d4f096aee54e058e1707619c01abf105ede2f0a6 Mon Sep 17 00:00:00 2001 From: JunsongDu Date: Tue, 26 Dec 2023 14:21:38 +0100 Subject: [PATCH 13/13] chore: add docs for semantics installation --- CHANGELOG.md | 1 + README.md | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5549c031..f2026bf5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ #### v0.3.0 - fix: bug in typePattern validation @richardmarston ([#180](https://github.com/RWTH-EBC/FiLiP/pull/180)) - add: add messages to all KeyErrors @FWuellhorst ([#192](https://github.com/RWTH-EBC/FiLiP/pull/192)) +- add: optional module `semantics` in setup tool @djs0109 - fix: get() method of Units dose not work properly by @djs0109 ([#193](https://github.com/RWTH-EBC/FiLiP/pull/193)) - BREAKING CHANGE: Migration of pydantic v1 to v2 @djs0109 ([#199](https://github.com/RWTH-EBC/FiLiP/issues/199)) diff --git a/README.md b/README.md index dc7b6bca..f1010a63 100644 --- a/README.md +++ b/README.md @@ -83,6 +83,13 @@ If you want to benefit from the latest changes, use the following command pip install -U git+git://github.com/RWTH-EBC/filip ``` +#### Install semantics module (optional) + +If you want to use the optional [semantics module](filip/semantics), use the following command (This will install the libraries that only required for the semantics module): +```` +pip install -U filip[semantics] +```` + ### Introduction to FIWARE The following section introduces FIWARE. If you are already familiar with