aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2022-04-26layerindex/utils.py: ignore 'core' in BBFILES_COLLECTIONStimo/fixes2Tim Orling
Many layers append BBFILE_COLLECTIONS and therefore have 'core <layer>' During update.py, this means we are likely not handling the collection we expect: WARNING: /opt/workdir/git___git_openembedded_org_meta-openembedded/meta-oe: multiple collections found, handling first one (core) only BBFILE_COLLECTIONS = "core" Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-04-26recipe{desc,parse}.py: BB_ENV_PASSTHROUGH_ADDITIONSTim Orling
ERROR: Variable BB_ENV_EXTRAWHITE has been renamed to BB_ENV_PASSTHROUGH_ADDITIONS ERROR: Variable BB_ENV_EXTRAWHITE from the shell environment has been renamed to BB_ENV_PASSTHROUGH_ADDITIONS ERROR: Exiting to allow enviroment variables to be corrected Replace BB_ENV_EXTRAWHITE with new variable BB_ENV_PASSTHROUGH_ADDITIONS In order to be backward compatible with older branches, we must first check for the presence of the bitbake commit which implemented the variable name change, using layerindex.utils.is_commit_ancestor(). Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-04-26layerindex/utils.py: add is_commit_ancestor checkTim Orling
Add a helper function to check if a given SHA1 hash is an ancestor in the currently checked out branch, using: git merge-branch --is-ancestor <commit> HEAD NOTE: This will not match commits which have been cherry-picked. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-04-18layerindex/models.py: add Inactive-UpstreamTim Orling
Add the newish Inactive-Upstream upstream status. Add 0046_alter_patch_status.py migration. Signed-off-by: Tim Orling <tim.orling@konsulko.com> layerindex/migrations: update patch status Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-04-18layerindex/urls.py: fix about url patternTim Orling
The url pattern was not including the trailing / [YOCTO #14445] Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13templates/*: staticfiles -> statictimo/django-3.2.11Tim Orling
In Django 3.0 the staticfiles tag was changed to static Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13requirements.txt: bump all to latestTim Orling
Run pip-upgrade and update all to latest Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13Dockerfile: add back python2 dependenciesTim Orling
We have some layers and especially older releases that still support python2. Add python2 dependencies back to the container so that the older releases still function. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13rrs: add 0030_alter_recipeupgrade_maintainer.py miagrationTim Orling
Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13Dockerfile: fix warningsTim Orling
* Define LANGUAGE to quiet perl warnings * Set DEBIAN_FRONTEND=noninteractive before apt call to quiet TERM/Dialog warnings Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13rrs/admin.py: drop curry importTim Orling
Dropped in Django 3.0 [1] Suggested replacements are functools.partial() or functools.partialmethod() [2] [1] https://docs.djangoproject.com/en/4.0/releases/3.0/ [2] https://github.com/django/django/commit/5b1c389603a353625ae1603ba345147356336afb Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13README.devel: update versionsTim Orling
This updated code-base should be compatible with Django 3.1 and obviously 3.2 (but not 3.0 or earlier). Django 3.2 requires Python 3.6+. With the upgrade to Celery 5, it is safer to recommend RabbitMQ 3.8.x, since that is what we are using. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13docker-compose: fix celeryTim Orling
In celery 5, the --workdir argument must come before the 'worker' subcommand. Without this, celery cannot load the layerindex module and this causes the celery container to continually restart. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13settings: set DEFAULT_AUTO_FIELDTim Orling
New in Django 3.2 To quiet warnings, set DEFAULT_AUTO_FIELD to the default value 'django.db.models.AutoField' NOTE: The default value for newly created Django 3.2 projects is django.db.models.BigAutoField, but this causes the need for a migration in 'captcha'. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13requirements.txt: bump to Django 3.2 LTSTim Orling
Upgrade to the latest Django 3.2.x LTS for extended support up until April 2024. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13requirements.txt: update all to latestTim Orling
Since we are on a "modern" version of Python in Debian buster container (3.7) and a modern version of Django (3.1.x) we should be able to run with the latest of all dependencies. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13docker-compose: bump mariadb to 10.3Tim Orling
10.2 was based on Ubuntu bionic 18.04, bumping to 10.3 as it is the first release on Ubuntu focal 20.04 Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13requirements.txt: bump to Django 3.1Tim Orling
Another incremental upgrade towards 3.2 LTS Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13Updates for Django 3.0Tim Orling
* Update requirements.txt versions - Mostly update to latest pre-Django 3.1 versions * Fix deprecated axes.backends.AxesModelBackend - settings.py - docker/settings.py * Fix template syntax 'staticfiles' -> 'static' - base.html * Add migrations for layerbranch classicrecipe Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13requirements.txt: bump to Django 3.0Tim Orling
Incremental upgrade towards 3.2 LTS version. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13layerindex/*: make all shebangs python3Tim Orling
Several scripts still had /usr/bin/env python Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13dockersetup.py: letsencrypt 2048 bit rsaTim Orling
The minimum length for an RSA pem is 2048 for the dummy cert. Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13Dockerfile: cleanup, install python3-wheelTim Orling
Remove duplicate python3-pip, etc. lines Need python3-wheel for bdist_wheel command Signed-off-by: Tim Orling <tim.orling@konsulko.com>
2022-01-13dockersetup.py: fix EMAIL_USE_SSL/TLSTim Orling
Need to concatenate str(boolean), not bool Signed-off-by: Tim Orling <timothy.t.orling@intel.com>
2021-10-20Report charset for text & CSV viewspaule/newfixes1Paul Eggleton
I noticed in the branch comparison plain text view ("Plain text" button in the Tools -> Branch Comparison page) that in current versions of Firefox the ellipses were coming through corrupted, though they looked fine in the HTML version, and it turns out this is because I wasn't specifying a character set encoding. It should be UTF-8, so add a charset to the content type stating as such for this and other similar views. Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-10-20about: add Amber & Tim to contributors listPaul Eggleton
Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-10-20rrs: make changes to support Django 2.2Paul Eggleton
Removed obsolete references to django.core.urlresolvers. Added the newly required on_delete parameters to foreign key relationships in models.py and in all migrations. (Amber Elliot's 2d526f9b0d363f3e442abc97ef9bd9fab37ee5e4 served as a reference for these changes). Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-10-20utils: ensure we show error messages on server startupPaul Eggleton
If a BBHandledException occurs that means some error was logged, so we need to handle any pending events so that we can actually have the error logged. Tinfoil should really be doing this for us but at this stage in the release we can't really fix this there, so do it here for now. Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-10-20update: fix setup of BBLAYERSPaul Eggleton
So with honister / current master we can no longer get away with bypassing BBLAYERS - it now needs to point to the core layer at minimum. This is fine, we just need to skip parsing layer.conf if we're parsing the core layer or we get some extra warnings we don't need. Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-10-20README.devel: update versionsPaul Eggleton
Update version requirements in line with recent changes. Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-10-20requirements.txt: set proper version restriction for DjangoPaul Eggleton
Without a comma, pip3 will currently install Django 4.0 which does not work. Signed-off-by: Paul Eggleton <paul.eggleton@linux.microsoft.com>
2021-04-21Add SPDX license headers to layerindex-web source filesMeh Mbeh Ida Delphine
Added SPDX identifiers to all .py files except those in migrations directory. Fixes: [YOCTO #13527] Signed-off-by: Meh Mbeh Ida Delphine <idadelm@gmail.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30docker/settings.py: MIDDLEWARETim Orling
The docker/settings.py file also needs the change from "Changing MIDDLEWARE_CLASSES to MIDDLEWARE." Signed-off-by: Tim Orling <ticotimo@gmail.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30Dockerfile: debian 10 "buster" and drop python2Tim Orling
Debian 10 "buster" actually has Django 2.2 available python2 is now EOL, so drop all usage Signed-off-by: Tim Orling <ticotimo@gmail.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30requirements.txt: Updating Django requirement to the 2.2 LTS release.Amber Elliot
Signed-off-by: Amber Elliot <amber.n.elliot@intel.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30Replacing is_authenticated() with is_authenticated for Django upgrade.Amber Elliot
Signed-off-by: Amber Elliot <amber.n.elliot@intel.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30settings.py: Replacing MIDDLEWARE_CLASSES with MIDDLEWARE for Django 2.2 ↵Amber Elliot
upgrade. Signed-off-by: Amber Elliot <amber.n.elliot@intel.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30Updating models and imports for Django 2.2 upgrade.Amber Elliot
Removed all obsolete references to django.core.urlresolvers. Added the newly required on_delete fields to foreign key relationships in models.py and in all migrations. Signed-off-by: Amber Elliot <amber.n.elliot@intel.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-06-30README: Correcting mailing list.Amber Elliot
Signed-off-by: Amber Elliot <amber.n.elliot@intel.com> Signed-off-by: Paul Eggleton <bluelightning@bluelightning.org>
2020-02-05Fix backup instructions when large logs are recordedPaul Eggleton
If the database contains task logs that are over the default max packet size for MariaDB, then attempting to dump the database will fail, but it won't be immediately obvious that that has happened - the gzipped sql file will simply be truncated and have an error in it. To fix the underlying issue, add an option to the example command for database backup to increase the max packet size to 512MB. (Restoring the database doesn't seem to suffer the same issue). In future we should probably look at writing a script to do this and in it properly check the return of mysqldump so that any problems get noticed immediately. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2020-01-06Fix parsing after AVAILABLE_LICENSES changePaul Eggleton
In OE-Core commit 8c9ef587fe499c612a878a1ab42092eb79b334ef an AVAILABLE_LICENSES variable was added in license.bbclass where its value is assigned with immediate expansion ( := ) with the result that it looks in LICENSE_PATH for licenses; in turn LICENSE_PATH refers to COREBASE. You might assume that COREBASE is always set, and normally it is (since it's set OE-Core's layer.conf) - but in the layer index context we do not parse layer.conf until a bit later, so it immediately fails. The quick way to fix this is just to set our own (correct) value for COREBASE and then AVAILABLE_LICENSES can be expanded successfully. You might ask why we don't instead just set BBLAYERS such that we *do* parse OE-Core's layer.conf - the answer is that that can have other effects such as BBFILE_COLLECTIONS being set, and at least at the moment the rest of the code isn't expecting that. Fixes [YOCTO #13723]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-12-20requirements.txt: bump Django version to fix CVE-2019-19844Paul Eggleton
Fixes a vulnerability in the password reset process due to insufficiently stringent validation of unicode email addresses. https://www.djangoproject.com/weblog/2019/dec/18/security-releases/ https://nvd.nist.gov/vuln/detail/CVE-2019-19844 (The existing version specification would have selected the fixed version of Django already for new installs, but bumping the minimum ensures that it will be installed for upgrades with ./dockersetup.py -u as well.) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-12-09tasks: squash out CRs in task logs to avoid huge transferspaule/fixes15Paul Eggleton
Reloading an existing update task page was taking an extremely long time to fetch down the task log and then pegging the client CPU such that the browser gave a warning. Digging into it, logs from a Clear Linux update task can be of the order of 500MB in size (with all of the line refreshing using CRs that happens during downloads), causing (a) the transfer to take a long time and (b) the JS code that updates the log text box to be extremely busy. If we're loading the entire log from scratch (as we are when we refresh the page) rather than just getting an update since the last poll, we don't need any of those line refreshes - so squash them out before returning the data. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-12-09update: ensure removed recipe dependencies are removed from dbPaul Eggleton
If a recipe dependency (either static or dynamic) is removed from the recipe when it is parsed, then we should ensure it gets removed from the database as well. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-12-09Upgrade Chart.js to 2.9.3Paul Eggleton
Quite a few bugs fixed, as far as I know none that we observed, but good to have. Details can be found here: https://github.com/chartjs/Chart.js/releases Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-12-09Upgrade jquery to 3.4.1Paul Eggleton
Minor bugfix releases, but we should have them anyway: https://blog.jquery.com/2019/04/10/jquery-3-4-0-released/ https://blog.jquery.com/2019/05/01/jquery-3-4-1-triggering-focus-events-in-ie-and-finding-root-elements-in-ios-10/ Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-12-09Upgrade Bootstrap to 3.4.1Paul Eggleton
https://blog.getbootstrap.com/2019/02/13/bootstrap-4-3-1-and-3-4-1/ https://blog.getbootstrap.com/2018/12/13/bootstrap-3-4-0/ These include a couple of CVE fixes, but this application already sanitises data when rendering so it is unlikely to have been vulnerable. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-11-26README.devel: mention python SMTP serverPaul Eggleton
For debugging email functionality, python's SMTP test server is useful, so add brief instructions on how to use it for convenience. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-11-21recipes: add help button to explain search termspaule/fixes14Paul Eggleton
There's a bit of advanced functionality by now in recipe searching, so add a link that shows a popup with information on how it works. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2019-11-21recipes: allow searching for layer:oe-corePaul Eggleton
When using the layer: advanced query term, if you want to match on OE-Core, its actual layer name is "openembedded-core", but people will naturally assume that "oe-core" should work, so make it so (case insensitive). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>