More idiomatic python3 + fix some tests

From: Cyril Jouve <jv(dot)cyril(at)gmail(dot)com>
To: pgadmin-hackers(at)postgresql(dot)org
Subject: More idiomatic python3 + fix some tests
Date: 2020-08-28 20:57:40
Message-ID: CANhjAHykjZOPe0=MLkTvqjvmUfK1F=HX+dE4ORrVdEPf+wwAfg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hello,

patch 1 to 6 generated mostly using 2to3:
0001: https://docs.python.org/3.8/library/2to3.html#2to3fixer-asserts
0002: https://docs.python.org/3.8/library/2to3.html#2to3fixer-filter
0003: https://docs.python.org/3.8/library/2to3.html#2to3fixer-idioms
0004: https://docs.python.org/3.8/library/2to3.html#2to3fixer-metaclass
0005: https://docs.python.org/3.8/library/2to3.html#2to3fixer-xrange
0006: https://docs.python.org/3.8/library/2to3.html#2to3fixer-unicode

patch 7 fixes change_password tests:
Less that min length : min is 8 instead of 6
Valid password : use an user different than admin user / mock mail module

patch 8 fixes ConstraintDeleteMultipleTestCase on py3.10 (using simplejson
like in all other modules).

Regards,
Cyril

Attachment Content-Type Size
0001-Replaces-deprecated-unittest-method-names-with-the-c.patch application/octet-stream 301.7 KB
0002-Wraps-filter-usage-in-a-list-call.patch application/octet-stream 6.8 KB
0003-several-transformations-that-make-Python-code-more-i.patch application/octet-stream 32.1 KB
0004-Converts-the-old-metaclass-syntax-to-the-new.patch application/octet-stream 822 bytes
0005-Renames-xrange-to-range.patch application/octet-stream 1.2 KB
0006-Renames-unicode-to-str.patch application/octet-stream 106.3 KB
0007-fix-change_password-tests.patch application/octet-stream 3.8 KB
0008-use-simplejson-instead-of-plain-json-compat-py3.10.patch application/octet-stream 979 bytes

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Rahul Shirsat 2020-08-31 09:39:05 [pgAdmin][Patch] #5746 setup.py --load-server does not allow loading connections that use pg_services
Previous Message Akshay Joshi 2020-08-28 12:54:14 Re: [pgAdmin][Patch] #4059 Query Tool button in Query Tool to open a new Query Window