Skip to content

Instantly share code, notes, and snippets.

@alikins
alikins / 3.11_to_3.12.out
Created July 6, 2021 17:58
pyff api semantic diff of pulpcore 3.11 to 3.12, 3.13, 3.14
Removed packages 'pulpcore/tests/upgrade/pre', 'pulpcore/tests/upgrade'
Package 'pulpcore/tests/unit/models' changed:
Module 'test_content.py' changed:
New imported 'Remote', 'RemoteArtifact' from 'pulpcore.plugin.models'
New class 'RemoteArtifactAlgorithmTestCase' with 6 public methods
Package 'pulpcore/plugin' changed:
Module 'actions.py' changed:
Removed import of 'enqueue_with_reservation' from 'pulpcore.tasking.tasks'
New imported 'dispatch' from 'pulpcore.tasking.tasks'
Class 'ModifyRepositoryActionMixin' changed:
@alikins
alikins / Dockerfile
Last active May 11, 2021 16:16
in galaxy_ng/dev/alikins
FROM localhost/galaxy_ng/galaxy_ng:base
COPY requirements/requirements.standalone.txt /tmp/requirements.standalone.txt
COPY requirements/requirements.alikins.txt /tmp/requirements.alikins.txt
RUN set -ex; \
pip install --no-cache-dir --requirement /tmp/requirements.standalone.txt; \
pip install --no-cache-dir --requirement /tmp/requirements.alikins.txt
@alikins
alikins / .compose.dev
Created February 5, 2021 16:17
dev/alikins/docker-compose.yml
COMPOSE_PROFILE=alikins
DEV_SOURCE_PATH='galaxy_ng'
docker run --network="host" -v "$PWD/galaxy_ng_schemaspy2:/output" -v "/home/adrian/src/galaxy_ng/schemaspy.properties:/schemaspy.properties" schemaspy/schemaspy:latest -hq -imageformat=svg
@alikins
alikins / logging.yaml
Created September 15, 2020 15:35
kind of excessive logging config
---
version: 1
disable_existing_loggers: false
# disable_existing_loggers: true
dynaconf_merge: true
filters:
require_debug_true:
(): django.utils.log.RequireDebugTrue
sql_excludes:
(): alogging.filters.django_sql_excludes.DjangoDbSqlExcludeFilter
@alikins
alikins / gist:e23349e8bbd4b347918614527f7aa692
Created August 24, 2020 14:47
galaxy_ng './compose up' dep traceback
api_1 | [2020-08-24 14:44:33 +0000] [113] [ERROR] Exception in worker process
api_1 | Traceback (most recent call last):
api_1 | File "/venv/lib64/python3.6/site-packages/gunicorn/arbiter.py", line 583, in spawn_worker
api_1 | worker.init_process()
api_1 | File "/venv/lib64/python3.6/site-packages/gunicorn/workers/base.py", line 119, in init_process
api_1 | self.load_wsgi()
api_1 | File "/venv/lib64/python3.6/site-packages/gunicorn/workers/base.py", line 144, in load_wsgi
api_1 | self.wsgi = self.app.wsgi()
api_1 | File "/venv/lib64/python3.6/site-packages/gunicorn/app/base.py", line 67, in wsgi
api_1 | self.callable = self.load()
worker_1 | SELECT T7."pulp_id",
worker_1 | T7."pulp_created",
worker_1 | T7."pulp_last_updated",
worker_1 | T7."pulp_type",
worker_1 | T7."upstream_id",
worker_1 | "ansible_collectionversion"."content_ptr_id",
worker_1 | "ansible_collectionversion"."authors",
worker_1 | "ansible_collectionversion"."contents",
worker_1 | "ansible_collectionversion"."dependencies",
worker_1 | "ansible_collectionversion"."description",
@alikins
alikins / gist:c124542112e64294768f6e942e9dbbde
Created August 12, 2020 21:29
guardian/rbac error when queueing a task
api_1 | Traceback (most recent call last):
api_1 | File "/venv/lib64/python3.6/site-packages/django/core/handlers/exception.py", line 34, in inner
api_1 | response = get_response(request)
api_1 | File "/venv/lib64/python3.6/site-packages/django/core/handlers/base.py", line 115, in _get_response
api_1 | response = self.process_exception_by_middleware(e, request)
api_1 | File "/venv/lib64/python3.6/site-packages/django/core/handlers/base.py", line 113, in _get_response
api_1 | response = wrapped_callback(request, *callback_args, **callback_kwargs)
api_1 | File "/venv/lib64/python3.6/site-packages/django/views/decorators/csrf.py", line 54, in wrapped_view
api_1 | return view_func(*args, **kwargs)
api_1 | File "/venv/lib64/python3.6/site-packages/rest_framework/viewsets.py", line 114, in view
@alikins
alikins / gist:3e100b85acc397ecedbc1b82e36d8b25
Created August 12, 2020 15:33
galaxy_ng rbac migrate after import apply_perms
Operations to perform:
Apply all migrations: admin, ansible, auth, authtoken, container, contenttypes, core, galaxy, guardian, sessions
Running migrations:
Applying galaxy.0004_rbac...Traceback (most recent call last):
File "/venv/bin/django-admin", line 8, in <module>
sys.exit(execute_from_command_line())
File "/venv/lib64/python3.6/site-packages/django/core/management/__init__.py", line 381, in execute_from_command_line
utility.execute()
File "/venv/lib64/python3.6/site-packages/django/core/management/__init__.py", line 375, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
Package galaxy_ng/app/migrations changed:
New module 0004_rbac.py
Package galaxy_ng/app/api/ui/serializers changed:
Removed module namespace.py
Module __init__.py changed:
Removed import of NamespaceSerializer, NamespaceSummarySerializer, NamespaceUpdateSerializer from removed namespace
Module synclist.py changed:
Removed import of auth_models from removed galaxy_ng.app.models
New imported GroupPermissionField from new galaxy_ng.app.access_control.fields
Class SyncListSerializer changed: