diff options
author | takeshi_hoshina <takeshi_hoshina@mail.toyota.co.jp> | 2020-11-02 11:07:33 +0900 |
---|---|---|
committer | takeshi_hoshina <takeshi_hoshina@mail.toyota.co.jp> | 2020-11-02 11:07:33 +0900 |
commit | 1c7d6584a7811b7785ae5c1e378f14b5ba0971cf (patch) | |
tree | cd70a267a5ef105ba32f200aa088e281fbd85747 /external/poky/bitbake/lib/toaster/toastergui | |
parent | 4204309872da5cb401cbb2729d9e2d4869a87f42 (diff) |
basesystem-jjsandbox/ToshikazuOhiwa/master-jj
recipes
Diffstat (limited to 'external/poky/bitbake/lib/toaster/toastergui')
13 files changed, 65 insertions, 168 deletions
diff --git a/external/poky/bitbake/lib/toaster/toastergui/api.py b/external/poky/bitbake/lib/toaster/toastergui/api.py index 564d595a..b4cdc335 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/api.py +++ b/external/poky/bitbake/lib/toaster/toastergui/api.py @@ -3,19 +3,8 @@ # # Copyright (C) 2016 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. +# SPDX-License-Identifier: GPL-2.0-only # -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - # Please run flake8 on this file before sending patches import os @@ -24,7 +13,6 @@ import logging import json import subprocess from collections import Counter -from shutil import copyfile from orm.models import Project, ProjectTarget, Build, Layer_Version from orm.models import LayerVersionDependency, LayerSource, ProjectLayer @@ -36,12 +24,10 @@ from bldcontrol import bbcontroller from django.http import HttpResponse, JsonResponse from django.views.generic import View -from django.core.urlresolvers import reverse +from django.urls import reverse from django.db.models import Q, F from django.db import Error from toastergui.templatetags.projecttags import filtered_filesizeformat -from django.utils import timezone -import pytz # development/debugging support verbose = 2 diff --git a/external/poky/bitbake/lib/toaster/toastergui/buildtables.py b/external/poky/bitbake/lib/toaster/toastergui/buildtables.py index 755a7c2e..327059d0 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/buildtables.py +++ b/external/poky/bitbake/lib/toaster/toastergui/buildtables.py @@ -1,23 +1,10 @@ # -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# # BitBake Toaster Implementation # # Copyright (C) 2016 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# SPDX-License-Identifier: GPL-2.0-only # -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. from orm.models import Build, Task, Target, Package from django.db.models import Q, Sum diff --git a/external/poky/bitbake/lib/toaster/toastergui/static/js/importlayer.js b/external/poky/bitbake/lib/toaster/toastergui/static/js/importlayer.js index 29648398..8e2032de 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/static/js/importlayer.js +++ b/external/poky/bitbake/lib/toaster/toastergui/static/js/importlayer.js @@ -17,11 +17,15 @@ function importLayerPageInit (ctx) { var currentLayerDepSelection; var validLayerName = /^(\w|-)+$/; + /* Catch 'disable' race condition between type-ahead started and "input change" */ + var typeAheadStarted = 0; + libtoaster.makeTypeahead(layerDepInput, libtoaster.ctx.layersTypeAheadUrl, { include_added: "true" }, function(item){ currentLayerDepSelection = item; layerDepBtn.removeAttr("disabled"); + typeAheadStarted = 1; }); layerDepInput.on("typeahead:select", function(event, data){ @@ -34,7 +38,10 @@ function importLayerPageInit (ctx) { // disable the "Add layer" button when the layer input typeahead is empty // or not in the typeahead choices layerDepInput.on("input change", function(){ - layerDepBtn.attr("disabled","disabled"); + if (0 == typeAheadStarted) { + layerDepBtn.attr("disabled","disabled"); + } + typeAheadStarted = 0; }); /* We automatically add "openembedded-core" layer for convenience as a @@ -50,6 +57,7 @@ function importLayerPageInit (ctx) { }); layerDepBtn.click(function(){ + typeAheadStarted = 0; if (currentLayerDepSelection == undefined) return; @@ -77,7 +85,7 @@ function importLayerPageInit (ctx) { $("#layer-deps-list").append(newLayerDep); - libtoaster.getLayerDepsForProject(currentLayerDepSelection.layerdetailurl, + libtoaster.getLayerDepsForProject(currentLayerDepSelection.xhrLayerUrl, function (data){ /* These are the dependencies of the layer added as a dependency */ if (data.list.length > 0) { diff --git a/external/poky/bitbake/lib/toaster/toastergui/tablefilter.py b/external/poky/bitbake/lib/toaster/toastergui/tablefilter.py index 65454e14..ffef7955 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/tablefilter.py +++ b/external/poky/bitbake/lib/toaster/toastergui/tablefilter.py @@ -1,23 +1,10 @@ # -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# # BitBake Toaster Implementation # # Copyright (C) 2015 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# SPDX-License-Identifier: GPL-2.0-only # -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. from django.db.models import Q, Max, Min from django.utils import dateparse, timezone diff --git a/external/poky/bitbake/lib/toaster/toastergui/tables.py b/external/poky/bitbake/lib/toaster/toastergui/tables.py index 9ff756bc..528dd32b 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/tables.py +++ b/external/poky/bitbake/lib/toaster/toastergui/tables.py @@ -1,34 +1,16 @@ # -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# # BitBake Toaster Implementation # # Copyright (C) 2015 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# SPDX-License-Identifier: GPL-2.0-only # -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. from toastergui.widgets import ToasterTable -from orm.models import Recipe, ProjectLayer, Layer_Version, Machine, Project +from orm.models import Recipe, ProjectLayer, Layer_Version, Project from orm.models import CustomImageRecipe, Package, Target, Build, LogMessage, Task from orm.models import CustomImagePackage, Package_DependencyManager -from orm.models import Distro -from django.db.models import Q, Max, Sum, Count, When, Case, Value, IntegerField -from django.conf.urls import url -from django.core.urlresolvers import reverse, resolve -from django.http import HttpResponse -from django.views.generic import TemplateView +from django.db.models import Q, Sum, Count, When, Case, Value, IntegerField from toastergui.tablefilter import TableFilter from toastergui.tablefilter import TableFilterActionToggle diff --git a/external/poky/bitbake/lib/toaster/toastergui/templatetags/field_values_filter.py b/external/poky/bitbake/lib/toaster/toastergui/templatetags/field_values_filter.py index 5a73af79..eb483396 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/templatetags/field_values_filter.py +++ b/external/poky/bitbake/lib/toaster/toastergui/templatetags/field_values_filter.py @@ -1,3 +1,7 @@ +# +# SPDX-License-Identifier: GPL-2.0-only +# + from django import template register = template.Library() diff --git a/external/poky/bitbake/lib/toaster/toastergui/templatetags/objects_to_dictionaries_filter.py b/external/poky/bitbake/lib/toaster/toastergui/templatetags/objects_to_dictionaries_filter.py index 0dcc7d27..e242234b 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/templatetags/objects_to_dictionaries_filter.py +++ b/external/poky/bitbake/lib/toaster/toastergui/templatetags/objects_to_dictionaries_filter.py @@ -1,5 +1,8 @@ +# +# SPDX-License-Identifier: GPL-2.0-only +# + from django import template -import json register = template.Library() diff --git a/external/poky/bitbake/lib/toaster/toastergui/templatetags/project_url_tag.py b/external/poky/bitbake/lib/toaster/toastergui/templatetags/project_url_tag.py index 04770ac6..7b6f15b2 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/templatetags/project_url_tag.py +++ b/external/poky/bitbake/lib/toaster/toastergui/templatetags/project_url_tag.py @@ -1,5 +1,9 @@ +# +# SPDX-License-Identifier: GPL-2.0-only +# + from django import template -from django.core.urlresolvers import reverse +from django.urls import reverse register = template.Library() diff --git a/external/poky/bitbake/lib/toaster/toastergui/templatetags/projecttags.py b/external/poky/bitbake/lib/toaster/toastergui/templatetags/projecttags.py index b170a161..c432f59a 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/templatetags/projecttags.py +++ b/external/poky/bitbake/lib/toaster/toastergui/templatetags/projecttags.py @@ -1,25 +1,12 @@ # -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# # BitBake Toaster Implementation # # Copyright (C) 2013 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# SPDX-License-Identifier: GPL-2.0-only # -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -from datetime import datetime, timedelta +from datetime import timedelta from os.path import relpath import re from django import template @@ -57,7 +44,7 @@ def json(value, default = None): # it manually here return mark_safe(JsonLib.dumps(value, indent=2, default = default, ensure_ascii=False).replace('</', '<\\/')) -@register.assignment_tag +@register.simple_tag def query(qs, **kwargs): """ template tag which allows queryset filtering. Usage: {% query books author=author as mybooks %} @@ -96,7 +83,7 @@ def divide(value, arg): def multiply(value, arg): return int(value) * int(arg) -@register.assignment_tag +@register.simple_tag def datecompute(delta, start = timezone.now()): return start + timedelta(delta) @@ -225,7 +212,7 @@ def filtered_installedsize(size, installed_size): """If package.installed_size not null and not empty return it, else return package.size """ - return size if (installed_size == 0) or (installed_size == "") or (installed_size == None) else installed_size + return size if (installed_size == 0) or (installed_size == "") or (installed_size is None) else installed_size @register.filter def filtered_packageversion(version, revision): @@ -241,7 +228,7 @@ def filter_sizeovertotal(package_object, total_size): formatted nicely. """ size = package_object.installed_size - if size == None or size == '': + if size is None or size == '': size = package_object.size return '{:.1%}'.format(float(size)/float(total_size)) diff --git a/external/poky/bitbake/lib/toaster/toastergui/typeaheads.py b/external/poky/bitbake/lib/toaster/toastergui/typeaheads.py index 5aa0f8d8..a1e6fe90 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/typeaheads.py +++ b/external/poky/bitbake/lib/toaster/toastergui/typeaheads.py @@ -3,24 +3,14 @@ # # Copyright (C) 2015 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. +# SPDX-License-Identifier: GPL-2.0-only # -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. import subprocess from toastergui.widgets import ToasterTypeAhead from orm.models import Project -from django.core.urlresolvers import reverse +from django.urls import reverse from django.core.cache import cache diff --git a/external/poky/bitbake/lib/toaster/toastergui/urls.py b/external/poky/bitbake/lib/toaster/toastergui/urls.py index dc03e303..d2df4e60 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/urls.py +++ b/external/poky/bitbake/lib/toaster/toastergui/urls.py @@ -3,23 +3,12 @@ # # Copyright (C) 2013-2017 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. +# SPDX-License-Identifier: GPL-2.0-only # -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -from django.conf.urls import include, url -from django.views.generic import RedirectView, TemplateView +from django.conf.urls import url +from django.views.generic import RedirectView -from django.http import HttpResponseBadRequest from toastergui import tables from toastergui import buildtables from toastergui import typeaheads diff --git a/external/poky/bitbake/lib/toaster/toastergui/views.py b/external/poky/bitbake/lib/toaster/toastergui/views.py index c712b06a..9a5e48e3 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/views.py +++ b/external/poky/bitbake/lib/toaster/toastergui/views.py @@ -1,24 +1,10 @@ # -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# # BitBake Toaster Implementation # # Copyright (C) 2013 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# SPDX-License-Identifier: GPL-2.0-only # -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - import re @@ -33,8 +19,8 @@ from orm.models import Target_Installed_Package, Target_File from orm.models import TargetKernelFile, TargetSDKFile, Target_Image_File from orm.models import BitbakeVersion, CustomImageRecipe -from django.core.urlresolvers import reverse, resolve -from django.core.exceptions import MultipleObjectsReturned, ObjectDoesNotExist +from django.urls import reverse, resolve +from django.core.exceptions import ObjectDoesNotExist from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger from django.http import HttpResponseNotFound, JsonResponse from django.utils import timezone @@ -65,7 +51,7 @@ class MimeTypeFinder(object): def get_mimetype(self, path): guess = mimetypes.guess_type(path, self._strict) guessed_type = guess[0] - if guessed_type == None: + if guessed_type is None: guessed_type = 'application/octet-stream' return guessed_type @@ -140,7 +126,7 @@ def _lv_to_dict(prj, x = None): return {"id": x.pk, "name": x.layer.name, "tooltip": "%s | %s" % (x.layer.vcs_url,x.get_vcs_reference()), - "detail": "(%s" % x.layer.vcs_url + (")" if x.release == None else " | "+x.get_vcs_reference()+")"), + "detail": "(%s" % x.layer.vcs_url + (")" if x.release is None else " | "+x.get_vcs_reference()+")"), "giturl": x.layer.vcs_url, "layerdetailurl" : reverse('layerdetails', args=(prj.id,x.pk)), "revision" : x.get_vcs_reference(), @@ -366,7 +352,7 @@ def _get_parameters_values(request, default_count, default_order): # set cookies for parameters. this is usefull in case parameters are set # manually from the GET values of the link def _set_parameters_values(pagesize, orderby, request): - from django.core.urlresolvers import resolve + from django.urls import resolve current_url = resolve(request.path_info).url_name request.session['%s_count' % current_url] = pagesize request.session['%s_orderby' % current_url] =orderby @@ -678,7 +664,6 @@ def recipe_packages(request, build_id, recipe_id): _set_parameters_values(pagesize, orderby, request) return response -from django.core.serializers.json import DjangoJSONEncoder from django.http import HttpResponse def xhr_dirinfo(request, build_id, target_id): top = request.GET.get('start', '/') @@ -733,7 +718,7 @@ def _get_dir_entries(build_id, target_id, start): resolved_id = o.sym_target_id resolved_path = o.path if target_packages.count(): - while resolved_id != "" and resolved_id != None: + while resolved_id != "" and resolved_id is not None: tf = Target_File.objects.get(pk=resolved_id) resolved_path = tf.path resolved_id = tf.sym_target_id @@ -745,10 +730,10 @@ def _get_dir_entries(build_id, target_id, start): entry['package_id'] = str(p.id) entry['package'] = p.name # don't use resolved path from above, show immediate link-to - if o.sym_target_id != "" and o.sym_target_id != None: + if o.sym_target_id != "" and o.sym_target_id is not None: entry['link_to'] = Target_File.objects.get(pk=o.sym_target_id).path entry['size'] = filtered_filesizeformat(o.size) - if entry['link_to'] != None: + if entry['link_to'] is not None: entry['permission'] = node_str[o.inodetype] + o.permission else: entry['permission'] = node_str[o.inodetype] + o.permission @@ -770,7 +755,7 @@ def dirinfo(request, build_id, target_id, file_path=None): objects = _get_dir_entries(build_id, target_id, '/') packages_sum = Package.objects.filter(id__in=Target_Installed_Package.objects.filter(target_id=target_id).values('package_id')).aggregate(Sum('installed_size')) dir_list = None - if file_path != None: + if file_path is not None: """ Link from the included package detail file list page and is requesting opening the dir info to a specific file path. @@ -1044,15 +1029,15 @@ def _get_package_dependency_count(package, target_id, is_installed): def _get_package_alias(package): alias = package.installed_name - if alias != None and alias != '' and alias != package.name: + if alias is not None and alias != '' and alias != package.name: return alias else: return '' def _get_fullpackagespec(package): r = package.name - version_good = package.version != None and package.version != '' - revision_good = package.revision != None and package.revision != '' + version_good = package.version is not None and package.version != '' + revision_good = package.revision is not None and package.revision != '' if version_good or revision_good: r += '_' if version_good: @@ -1206,7 +1191,7 @@ def package_included_reverse_dependencies(request, build_id, target_id, package_ return _redirect_parameters( 'package_included_reverse_dependencies', request.GET, mandatory_parameters, build_id = build_id, target_id = target_id, package_id = package_id) (filter_string, search_term, ordering_string) = _search_tuple(request, Package_File) - queryset = Package_Dependency.objects.select_related('depends_on__name', 'depends_on__size').filter(depends_on=package_id, target_id=target_id, dep_type=Package_Dependency.TYPE_TRDEPENDS) + queryset = Package_Dependency.objects.select_related('depends_on').filter(depends_on=package_id, target_id=target_id, dep_type=Package_Dependency.TYPE_TRDEPENDS) objects = _get_queryset(Package_Dependency, queryset, filter_string, search_term, ordering_string, 'package__name') package = Package.objects.get(pk=package_id) @@ -1354,7 +1339,7 @@ def json_build(request,build_id): import toastermain.settings -from orm.models import Project, ProjectLayer, ProjectTarget, ProjectVariable +from orm.models import Project, ProjectLayer, ProjectVariable from bldcontrol.models import BuildEnvironment # we have a set of functions if we're in managed mode, or @@ -1363,10 +1348,8 @@ from bldcontrol.models import BuildEnvironment if True: from django.contrib.auth.models import User from django.contrib.auth import authenticate, login - from django.contrib.auth.decorators import login_required - from orm.models import LayerSource, ToasterSetting, Release, Machine, LayerVersionDependency - from bldcontrol.models import BuildRequest + from orm.models import LayerSource, ToasterSetting, Release import traceback @@ -1381,8 +1364,8 @@ if True: template = "newproject.html" context = { - 'email': request.user.email if request.user.is_authenticated() else '', - 'username': request.user.username if request.user.is_authenticated() else '', + 'email': request.user.email if request.user.is_authenticated else '', + 'username': request.user.username if request.user.is_authenticated else '', 'releases': Release.objects.order_by("description"), } @@ -1408,7 +1391,7 @@ if True: # set alert for missing fields raise BadParameterException("Fields missing: %s" % ", ".join(missing)) - if not request.user.is_authenticated(): + if not request.user.is_authenticated: user = authenticate(username = request.POST.get('username', '_anonuser'), password = 'nopass') if user is None: user = User.objects.create_user(username = request.POST.get('username', '_anonuser'), email = request.POST.get('email', ''), password = "nopass") @@ -1455,8 +1438,8 @@ if True: project = Project.objects.get(pk=pid) template = "newproject_specific.html" context = { - 'email': request.user.email if request.user.is_authenticated() else '', - 'username': request.user.username if request.user.is_authenticated() else '', + 'email': request.user.email if request.user.is_authenticated else '', + 'username': request.user.username if request.user.is_authenticated else '', 'releases': Release.objects.order_by("description"), 'projectname': project.name, 'project_pk': project.pk, @@ -1486,7 +1469,7 @@ if True: # set alert for missing fields raise BadParameterException("Fields missing: %s" % ", ".join(missing)) - if not request.user.is_authenticated(): + if not request.user.is_authenticated: user = authenticate(username = request.POST.get('username', '_anonuser'), password = 'nopass') if user is None: user = User.objects.create_user(username = request.POST.get('username', '_anonuser'), email = request.POST.get('email', ''), password = "nopass") diff --git a/external/poky/bitbake/lib/toaster/toastergui/widgets.py b/external/poky/bitbake/lib/toaster/toastergui/widgets.py index db5c3aa0..ceff5294 100644 --- a/external/poky/bitbake/lib/toaster/toastergui/widgets.py +++ b/external/poky/bitbake/lib/toaster/toastergui/widgets.py @@ -1,23 +1,10 @@ # -# ex:ts=4:sw=4:sts=4:et -# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- -# # BitBake Toaster Implementation # # Copyright (C) 2015 Intel Corporation # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License version 2 as -# published by the Free Software Foundation. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# SPDX-License-Identifier: GPL-2.0-only # -# You should have received a copy of the GNU General Public License along -# with this program; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. from django.views.generic import View, TemplateView from django.views.decorators.cache import cache_control @@ -35,7 +22,7 @@ from django.utils import timezone from toastergui.templatetags.projecttags import sectohms, get_tasks from toastergui.templatetags.projecttags import json as template_json from django.http import JsonResponse -from django.core.urlresolvers import reverse +from django.urls import reverse import types import json |