diff --git a/.github/workflows/pylint.yml b/.github/workflows/pylint.yml index d6ee66c..0835745 100644 --- a/.github/workflows/pylint.yml +++ b/.github/workflows/pylint.yml @@ -18,7 +18,8 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install -r requirements-tests.txt + pip install -r requirements.txt + pip install pylint - name: Check with Pylint run: | pylint --fail-under=9.5 loglan_core \ No newline at end of file diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 5647998..c10cb24 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -22,7 +22,6 @@ jobs: run: | python -m pip install --upgrade pip pip install -r requirements-tests.txt - pip install coverage - name: Test with pytest run: | pytest --cov loglan_core diff --git a/README.md b/README.md index ca83f8e..239b893 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ ![Code Climate maintainability](https://img.shields.io/codeclimate/maintainability-percentage/torrua/loglan_core?logo=Code%20Climate) [![Pylint](https://github.com/torrua/loglan_core/actions/workflows/pylint.yml/badge.svg)](https://github.com/torrua/loglan_core/actions/workflows/pylint.yml) [![Pytest](https://github.com/torrua/loglan_core/actions/workflows/pytest.yml/badge.svg)](https://github.com/torrua/loglan_core/actions/workflows/pytest.yml) -![pylint](https://img.shields.io/badge/pylint-9.94-yellow?logo=python&logoColor=white) +![pylint](https://img.shields.io/badge/pylint-9.96-yellow?logo=python&logoColor=white) ![PyPI - Downloads](https://img.shields.io/pypi/dm/loglan_core?color=yellow) ![PyPI - Version](https://img.shields.io/pypi/v/loglan-core?logo=PyPi&logoColor=%23FFFFFF) ![GitHub License](https://img.shields.io/github/license/torrua/loglan_core) diff --git a/docs/event.html b/docs/event.html index 5f42611..d2d7896 100644 --- a/docs/event.html +++ b/docs/event.html @@ -35,7 +35,7 @@

Classes

class BaseEvent -(date, name, definition, annotation, suffix) +(name, date, definition, annotation, suffix)

Base Event's DB Model

diff --git a/loglan_core/__init__.py b/loglan_core/__init__.py index 309d34b..12b5be1 100644 --- a/loglan_core/__init__.py +++ b/loglan_core/__init__.py @@ -3,7 +3,7 @@ """ __author__ = "torrua" -__copyright__ = "Copyright 2023, loglan_core project" +__copyright__ = "Copyright 2024, loglan_core project" __email__ = "torrua@gmail.com" from loglan_core.author import BaseAuthor as Author @@ -21,3 +21,5 @@ from loglan_core.word import BaseWord as Word from loglan_core.word_source import BaseWordSource as WordSource from loglan_core.word_spell import BaseWordSpell as WordSpell +from loglan_core.base import BaseModel as Base +from loglan_core.addons.word_selector import WordSelector diff --git a/loglan_core/addons/__init__.py b/loglan_core/addons/__init__.py index 9373ea4..d94f733 100644 --- a/loglan_core/addons/__init__.py +++ b/loglan_core/addons/__init__.py @@ -1,3 +1,3 @@ """ This module contains an addons for BaseModels -""" \ No newline at end of file +""" diff --git a/loglan_core/event.py b/loglan_core/event.py index 2ce6d28..e1cdb83 100644 --- a/loglan_core/event.py +++ b/loglan_core/event.py @@ -42,15 +42,15 @@ class BaseEvent(BaseModel): def __init__( self, - date: Mapped[datetime.date], name: Mapped[str_064], + date: Mapped[datetime.date], definition: Mapped[str], annotation: Mapped[str_016], suffix: Mapped[str_016], ): super().__init__() - self.date = date self.name = name + self.date = date self.definition = definition self.annotation = annotation self.suffix = suffix @@ -62,12 +62,12 @@ def __str__(self): f"{self.name} ({self.date})>" ) - date: Mapped[datetime.date] = mapped_column(nullable=False) - """*Event's starting day* - **dateime.date** : nullable=False, unique=False""" name: Mapped[str_064] = mapped_column(nullable=False) """*Event's short name* **str** : max_length=64, nullable=False, unique=False""" + date: Mapped[datetime.date] = mapped_column(nullable=False) + """*Event's starting day* + **dateime.date** : nullable=False, unique=False""" definition: Mapped[str] = mapped_column(Text, nullable=False) """*Event's definition* **str** : nullable=False, unique=False""" diff --git a/requirements-dev.txt b/requirements-dev.txt index 44bb8f6..eded03f 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -4,4 +4,5 @@ black~=23.12.1 mypy~=1.8.0 radon~=6.0.1 setuptools~=69.0.3 -wheel~=0.42.0 \ No newline at end of file +wheel~=0.42.0 +pylint~=3.0 \ No newline at end of file diff --git a/requirements-tests.txt b/requirements-tests.txt index 07e9cf2..a6ac234 100644 --- a/requirements-tests.txt +++ b/requirements-tests.txt @@ -1,7 +1,6 @@ -r requirements.txt -coverage~=7.3 -pylint~=3.0 +coverage~=7.4 pytest-cov~=4.1 pytest~=7.4 scrutinizer-ocular~=1.0