diff --git a/.cookiecutter.json b/.cookiecutter.json index d2c8398..65ffe18 100644 --- a/.cookiecutter.json +++ b/.cookiecutter.json @@ -1,6 +1,6 @@ { "cookiecutter": { - "codeowner_github_usernames": "@cmsirbu @snaselj @whitej6", + "codeowner_github_usernames": "@nautobot/maintain-nautobot-apps", "full_name": "Network to Code, LLC", "email": "opensource@networktocode.com", "github_org": "nautobot", diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f533e1d..83ecf91 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -175,7 +175,6 @@ jobs: if: "matrix.db-backend == 'mysql'" - name: "Run Tests" run: "poetry run invoke unittest" - changelog: if: > contains(fromJson('["develop","ltm-1.6"]'), github.base_ref) && diff --git a/development/nautobot_config.py b/development/nautobot_config.py index f7786ce..0b80cd5 100644 --- a/development/nautobot_config.py +++ b/development/nautobot_config.py @@ -48,8 +48,7 @@ "PASSWORD": os.getenv("NAUTOBOT_DB_PASSWORD", ""), # Database password "HOST": os.getenv("NAUTOBOT_DB_HOST", "localhost"), # Database server "PORT": os.getenv( - "NAUTOBOT_DB_PORT", - default_db_settings[nautobot_db_engine]["NAUTOBOT_DB_PORT"], + "NAUTOBOT_DB_PORT", default_db_settings[nautobot_db_engine]["NAUTOBOT_DB_PORT"] ), # Database port, default to postgres "CONN_MAX_AGE": int(os.getenv("NAUTOBOT_DB_TIMEOUT", "300")), # Database timeout "ENGINE": nautobot_db_engine, diff --git a/nautobot_dev_example/forms.py b/nautobot_dev_example/forms.py index b497b80..753ed72 100644 --- a/nautobot_dev_example/forms.py +++ b/nautobot_dev_example/forms.py @@ -1,12 +1,7 @@ """Forms for nautobot_dev_example.""" from django import forms -from nautobot.apps.forms import ( - NautobotBulkEditForm, - NautobotFilterForm, - NautobotModelForm, - TagsBulkEditFormMixin, -) +from nautobot.apps.forms import NautobotBulkEditForm, NautobotFilterForm, NautobotModelForm, TagsBulkEditFormMixin from nautobot_dev_example import models diff --git a/nautobot_dev_example/models.py b/nautobot_dev_example/models.py index 7cdaad8..8e0610b 100644 --- a/nautobot_dev_example/models.py +++ b/nautobot_dev_example/models.py @@ -6,7 +6,7 @@ # Nautobot imports from nautobot.apps.models import PrimaryModel -# from nautobot.extras.utils import extras_features +# from nautobot.apps.models import extras_features # If you want to use the extras_features decorator please reference the following documentation # https://docs.nautobot.com/projects/core/en/latest/plugins/development/#using-the-extras_features-decorator-for-graphql # Then based on your reading you may decide to put the following decorator before the declaration of your class diff --git a/pyproject.toml b/pyproject.toml index 7a5f7b7..75e5547 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,12 +64,12 @@ all = [ [tool.pylint.master] # Include the pylint_django plugin to avoid spurious warnings about Django patterns -load-plugins="pylint_django, pylint_nautobot" -ignore=".venv" +load-plugins = "pylint_django, pylint_nautobot" +ignore = ".venv" [tool.pylint.basic] # No docstrings required for private methods (Pylint default), or for test_ functions, or for inner Meta classes. -no-docstring-rgx="^(_|test_|Meta$)" +no-docstring-rgx = "^(_|test_|Meta$)" [tool.pylint.messages_control] disable = """, @@ -101,21 +101,21 @@ select = [ ] ignore = [ # warning: `one-blank-line-before-class` (D203) and `no-blank-line-before-class` (D211) are incompatible. - "D203", # 1 blank line required before class docstring + "D203", # 1 blank line required before class docstring # D212 is enabled by default in google convention, and complains if we have a docstring like: # """ # My docstring is on the line after the opening quotes instead of on the same line as them. # """ # We've discussed and concluded that we consider this to be a valid style choice. - "D212", # Multi-line docstring summary should start at the first line - "D213", # Multi-line docstring summary should start at the second line + "D212", # Multi-line docstring summary should start at the first line + "D213", # Multi-line docstring summary should start at the second line # Produces a lot of issues in the current codebase. - "D401", # First line of docstring should be in imperative mood - "D407", # Missing dashed underline after section - "D416", # Section name ends in colon - "E501", # Line too long + "D401", # First line of docstring should be in imperative mood + "D407", # Missing dashed underline after section + "D416", # Section name ends in colon + "E501", # Line too long ] [tool.ruff.lint.pydocstyle] diff --git a/tasks.py b/tasks.py index 9dcf61a..a772942 100644 --- a/tasks.py +++ b/tasks.py @@ -530,12 +530,7 @@ def dbshell(context, db_name="", input_file="", output_file="", query=""): f"> '{output_file}'" if output_file else "", ] - docker_compose( - context, - " ".join(command), - env=env, - pty=not (input_file or output_file or query), - ) + docker_compose(context, " ".join(command), env=env, pty=not (input_file or output_file or query)) @task( @@ -856,20 +851,11 @@ def generate_app_config_schema(context): - `NautobotAppConfig.required_settings` """ start(context, service="nautobot") - nbshell( - context, - file="development/app_config_schema.py", - env={"APP_CONFIG_SCHEMA_COMMAND": "generate"}, - ) + nbshell(context, file="development/app_config_schema.py", env={"APP_CONFIG_SCHEMA_COMMAND": "generate"}) @task def validate_app_config(context): """Validate the app config based on the app config schema.""" start(context, service="nautobot") - nbshell( - context, - plain=True, - file="development/app_config_schema.py", - env={"APP_CONFIG_SCHEMA_COMMAND": "validate"}, - ) + nbshell(context, plain=True, file="development/app_config_schema.py", env={"APP_CONFIG_SCHEMA_COMMAND": "validate"})