[GH-ISSUE #1729] qcleanup error TypeError: '<' not supported between instances of 'memoryview' and 'memoryview' #1363

Closed
opened 2026-02-27 11:16:44 +03:00 by kerem · 1 comment
Owner

Originally created by @proto on GitHub (May 2, 2019).
Original GitHub issue: https://github.com/modoboa/modoboa/issues/1729

Impacted versions

  • Modoboa: 1.13.1
  • installer used: No
  • Webserver: Nginx
  • DB: postgresql 10.7

NOTEs: FreeBSD install

Steps to reproduce

CRONTAB: qcleanup
MANUAL: VENV_PATH/python INSTANCE/manage.py qcleanup --debug --verbose

Current behavior

Deleting marked messages...
Deleting messages older than 30 days...
Traceback (most recent call last):
  File "/mailstore/app/instance/manage.py", line 22, in <module>
    execute_from_command_line(sys.argv)
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/__init__.py", line 364, in execute_from_command_line
    utility.execute()
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/__init__.py", line 356, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/base.py", line 283, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/base.py", line 330, in execute
    output = self.handle(*args, **options)
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/modoboa_amavis/management/commands/qcleanup.py", line 59, in handle
    Msgs.objects.filter(time_num__lt=limit).delete()
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/db/models/query.py", line 620, in delete
    deleted, _rows_count = collector.delete()
  File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/db/models/deletion.py", line 265, in delete
    self.data[model] = sorted(instances, key=attrgetter("pk"))
TypeError: '<' not supported between instances of 'memoryview' and 'memoryview'

Manual clean via Web interface is working.

Expected behavior

Should clean.

Originally created by @proto on GitHub (May 2, 2019). Original GitHub issue: https://github.com/modoboa/modoboa/issues/1729 # Impacted versions * Modoboa: 1.13.1 * installer used: No * Webserver: Nginx * DB: postgresql 10.7 NOTEs: FreeBSD install # Steps to reproduce CRONTAB: qcleanup MANUAL: VENV_PATH/python INSTANCE/manage.py qcleanup --debug --verbose # Current behavior ``` Deleting marked messages... Deleting messages older than 30 days... ``` ``` Traceback (most recent call last): File "/mailstore/app/instance/manage.py", line 22, in <module> execute_from_command_line(sys.argv) File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/__init__.py", line 364, in execute_from_command_line utility.execute() File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/__init__.py", line 356, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/base.py", line 283, in run_from_argv self.execute(*args, **cmd_options) File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/core/management/base.py", line 330, in execute output = self.handle(*args, **options) File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/modoboa_amavis/management/commands/qcleanup.py", line 59, in handle Msgs.objects.filter(time_num__lt=limit).delete() File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/db/models/query.py", line 620, in delete deleted, _rows_count = collector.delete() File "/mailstore/app/.local/share/virtualenvs/app-nTDplZi9/lib/python3.6/site-packages/django/db/models/deletion.py", line 265, in delete self.data[model] = sorted(instances, key=attrgetter("pk")) TypeError: '<' not supported between instances of 'memoryview' and 'memoryview' ``` Manual clean via Web interface is working. # Expected behavior Should clean.
kerem closed this issue 2026-02-27 11:16:44 +03:00
Author
Owner

@tonioo commented on GitHub (May 6, 2019):

Duplicates https://github.com/modoboa/modoboa-amavis/issues/115

<!-- gh-comment-id:489567080 --> @tonioo commented on GitHub (May 6, 2019): Duplicates https://github.com/modoboa/modoboa-amavis/issues/115
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/modoboa-modoboa#1363
No description provided.