📁
SKYSHELL MANAGER
PHP v8.2.30
Create
Create
Path:
root
/
home
/
qooetu
/
costes.qooetu.com
/
Name
Size
Perm
Actions
📁
.well-known
-
0755
🗑️
🏷️
🔒
📁
2e19d9
-
0755
🗑️
🏷️
🔒
📁
6b114
-
0755
🗑️
🏷️
🔒
📁
Modules
-
0755
🗑️
🏷️
🔒
📁
app
-
0755
🗑️
🏷️
🔒
📁
assets
-
0755
🗑️
🏷️
🔒
📁
bootstrap
-
0755
🗑️
🏷️
🔒
📁
cgi-bin
-
0755
🗑️
🏷️
🔒
📁
config
-
0755
🗑️
🏷️
🔒
📁
css
-
0755
🗑️
🏷️
🔒
📁
database
-
0755
🗑️
🏷️
🔒
📁
images
-
0755
🗑️
🏷️
🔒
📁
js
-
0755
🗑️
🏷️
🔒
📁
nbproject
-
0755
🗑️
🏷️
🔒
📁
public
-
0755
🗑️
🏷️
🔒
📁
resources
-
0755
🗑️
🏷️
🔒
📁
routes
-
0755
🗑️
🏷️
🔒
📁
storage
-
0755
🗑️
🏷️
🔒
📁
tests
-
0755
🗑️
🏷️
🔒
📁
uploads
-
0755
🗑️
🏷️
🔒
📁
vendor
-
0755
🗑️
🏷️
🔒
📁
wp-admin
-
0755
🗑️
🏷️
🔒
📁
wp-content
-
0755
🗑️
🏷️
🔒
📁
wp-includes
-
0755
🗑️
🏷️
🔒
📄
.htaccess
0.23 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
COOKIE.txt
0.2 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
X7ROOT.txt
0.27 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
defaults.php
1.29 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
engine.php
0 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
error_log
813.08 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
features.php
11.28 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
googlecfb82e09419fc0f6.html
0.05 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
index.php0
1.56 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
inputs.php
0.12 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
kurd.html
1.07 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
library.php
0 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
min.php
6.83 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
p.php
2.75 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
php.ini
0.04 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
product.php
1.78 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
qpmwztts.php
0.74 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
robots.txt
0.32 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
📄
tovmbkwh.php
0.74 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
tyyffovi.php
0.74 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
📄
veoxv.html
1.23 KB
0644
🗑️
🏷️
⬇️
✏️
🔒
Edit: migrations.py
# Copyright (c) 2018, 2020 Alexander Todorov <atodorov@MrSenko.com> # Copyright (c) 2020 Bryan Mutai <mutaiwork@gmail.com> # Licensed under the GPL 2.0: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html # For details: https://github.com/PyCQA/pylint-django/blob/master/LICENSE """ Various suggestions around migrations. Disabled by default! Enable with pylint --load-plugins=pylint_django.checkers.migrations """ import astroid from pylint import checkers, interfaces from pylint.checkers import utils from pylint_plugin_utils import suppress_message from pylint_django import compat from pylint_django.__pkginfo__ import BASE_ID from pylint_django.utils import is_migrations_module def _is_addfield_with_default(call): if not isinstance(call.func, astroid.Attribute): return False if not call.func.attrname == "AddField": return False for keyword in call.keywords: # looking for AddField(..., field=XXX(..., default=Y, ...), ...) if keyword.arg == "field" and isinstance(keyword.value, astroid.Call): # loop over XXX's keywords # NOTE: not checking if XXX is an actual field type because there could # be many types we're not aware of. Also the migration will probably break # if XXX doesn't instantiate a field object! for field_keyword in keyword.value.keywords: if field_keyword.arg == "default": return True return False class NewDbFieldWithDefaultChecker(checkers.BaseChecker): """ Looks for migrations which add new model fields and these fields have a default value. According to Django docs this may have performance penalties especially on large tables: https://docs.djangoproject.com/en/2.0/topics/migrations/#postgresql The preferred way is to add a new DB column with null=True because it will be created instantly and then possibly populate the table with the desired default values. """ __implements__ = (interfaces.IAstroidChecker,) # configuration section name name = "new-db-field-with-default" msgs = { f"W{BASE_ID}98": ( "%s AddField with default value", "new-db-field-with-default", "Used when Pylint detects migrations adding new fields with a default value.", ) } _migration_modules = [] _possible_offences = {} def visit_module(self, node): if is_migrations_module(node): self._migration_modules.append(node) def visit_call(self, node): try: module = node.frame().parent except: # noqa: E722, pylint: disable=bare-except return if not is_migrations_module(module): return if _is_addfield_with_default(node): if module not in self._possible_offences: self._possible_offences[module] = [] if node not in self._possible_offences[module]: self._possible_offences[module].append(node) @utils.check_messages("new-db-field-with-default") def close(self): def _path(node): return node.path # sort all migrations by name in reverse order b/c # we need only the latest ones self._migration_modules.sort(key=_path, reverse=True) # filter out the last migration modules under each distinct # migrations directory, iow leave only the latest migrations # for each application last_name_space = "" latest_migrations = [] for module in self._migration_modules: name_space = module.path[0].split("migrations")[0] if name_space != last_name_space: last_name_space = name_space latest_migrations.append(module) for module, nodes in self._possible_offences.items(): if module in latest_migrations: for node in nodes: self.add_message("new-db-field-with-default", args=module.name, node=node) class MissingBackwardsMigrationChecker(checkers.BaseChecker): __implements__ = (interfaces.IAstroidChecker,) name = "missing-backwards-migration-callable" msgs = { f"W{BASE_ID}97": ( "Always include backwards migration callable", "missing-backwards-migration-callable", "Always include a backwards/reverse callable counterpart so that the migration is not irreversable.", ) } @utils.check_messages("missing-backwards-migration-callable") def visit_call(self, node): try: module = node.frame().parent except: # noqa: E722, pylint: disable=bare-except return if not is_migrations_module(module): return if node.func.as_string().endswith("RunPython") and len(node.args) < 2: if node.keywords: for keyword in node.keywords: if keyword.arg == "reverse_code": return self.add_message("missing-backwards-migration-callable", node=node) else: self.add_message("missing-backwards-migration-callable", node=node) def is_in_migrations(node): """ RunPython() migrations receive forward/backwards functions with signature: def func(apps, schema_editor): which could be unused. This augmentation will suppress all 'unused-argument' messages coming from functions in migration modules. """ return is_migrations_module(node.parent) def load_configuration(linter): # TODO this is redundant and can be removed # don't blacklist migrations for this checker new_black_list = list(linter.config.black_list) if "migrations" in new_black_list: new_black_list.remove("migrations") linter.config.black_list = new_black_list def register(linter): """Required method to auto register this checker.""" linter.register_checker(NewDbFieldWithDefaultChecker(linter)) linter.register_checker(MissingBackwardsMigrationChecker(linter)) if not compat.LOAD_CONFIGURATION_SUPPORTED: load_configuration(linter) # apply augmentations for migration checkers # Unused arguments for migrations suppress_message( linter, checkers.variables.VariablesChecker.leave_functiondef, "unused-argument", is_in_migrations, )
Save