New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests fail with python3.6 #385

Closed
antlarr-suse opened this Issue Sep 24, 2018 · 1 comment

Comments

Projects
None yet
2 participants
@antlarr-suse
Copy link

antlarr-suse commented Sep 24, 2018

Running on openSUSE Tumbleweed, with python2.7 and python3.6 .

The tests run fine under python2, but if I try to run them with python3 (with a clean system, just after extracting the 0.7.6 package), python3 setup.py build runs fine but then I get (I enabled debug output):

> python3 setup.py test
click to open the rest of the test output
running test
running egg_info
writing pony.egg-info/PKG-INFO
writing dependency_links to pony.egg-info/dependency_links.txt
writing top-level names to pony.egg-info/top_level.txt
reading manifest file 'pony.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'pony/flask/example/templates'
warning: no files found matching '*.html'
writing manifest file 'pony.egg-info/SOURCES.txt'
running build_ext
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Customer" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "email" TEXT UNIQUE NOT NULL
)

CREATE TABLE "Order" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "total_price" DECIMAL(12, 2) NOT NULL,
  "customer" INTEGER NOT NULL REFERENCES "Customer" ("id")
)

CREATE INDEX "idx_order__customer" ON "Order" ("customer")

CREATE TABLE "Product" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "price" DECIMAL(12, 2) NOT NULL
)

CREATE TABLE "OrderItem" (
  "quantity" INTEGER NOT NULL,
  "order" INTEGER NOT NULL REFERENCES "Order" ("id"),
  "product" INTEGER NOT NULL REFERENCES "Product" ("id"),
  PRIMARY KEY ("order", "product")
)

CREATE INDEX "idx_orderitem__product" ON "OrderItem" ("product")

SELECT "Customer"."id", "Customer"."name", "Customer"."email"
FROM "Customer" "Customer"
WHERE 0 = 1

SELECT "Order"."id", "Order"."total_price", "Order"."customer"
FROM "Order" "Order"
WHERE 0 = 1

SELECT "OrderItem"."quantity", "OrderItem"."order", "OrderItem"."product"
FROM "OrderItem" "OrderItem"
WHERE 0 = 1

SELECT "Product"."id", "Product"."name", "Product"."price"
FROM "Product" "Product"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Category" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT UNIQUE NOT NULL
)

CREATE TABLE "Customer" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "email" TEXT UNIQUE NOT NULL,
  "password" TEXT NOT NULL,
  "name" TEXT NOT NULL,
  "country" TEXT NOT NULL,
  "address" TEXT NOT NULL
)

CREATE TABLE "Order" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "state" TEXT NOT NULL,
  "date_created" DATETIME NOT NULL,
  "date_shipped" DATETIME,
  "date_delivered" DATETIME,
  "total_price" DECIMAL(12, 2) NOT NULL,
  "customer" INTEGER NOT NULL REFERENCES "Customer" ("id")
)

CREATE INDEX "idx_order__customer" ON "Order" ("customer")

CREATE TABLE "Product" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "description" TEXT NOT NULL,
  "picture" BLOB,
  "price" DECIMAL(12, 2) NOT NULL,
  "quantity" INTEGER NOT NULL
)

CREATE TABLE "CartItem" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "quantity" INTEGER NOT NULL,
  "customer" INTEGER NOT NULL REFERENCES "Customer" ("id"),
  "product" INTEGER NOT NULL REFERENCES "Product" ("id")
)

CREATE INDEX "idx_cartitem__customer" ON "CartItem" ("customer")

CREATE INDEX "idx_cartitem__product" ON "CartItem" ("product")

CREATE TABLE "Category_Product" (
  "category" INTEGER NOT NULL REFERENCES "Category" ("id"),
  "product" INTEGER NOT NULL REFERENCES "Product" ("id"),
  PRIMARY KEY ("category", "product")
)

CREATE INDEX "idx_category_product" ON "Category_Product" ("product")

CREATE TABLE "OrderItem" (
  "quantity" INTEGER NOT NULL,
  "price" DECIMAL(12, 2) NOT NULL,
  "order" INTEGER NOT NULL REFERENCES "Order" ("id"),
  "product" INTEGER NOT NULL REFERENCES "Product" ("id"),
  PRIMARY KEY ("order", "product")
)

CREATE INDEX "idx_orderitem__product" ON "OrderItem" ("product")

SELECT "CartItem"."id", "CartItem"."quantity", "CartItem"."customer", "CartItem"."product"
FROM "CartItem" "CartItem"
WHERE 0 = 1

SELECT "Category"."id", "Category"."name"
FROM "Category" "Category"
WHERE 0 = 1

SELECT "Category_Product"."category", "Category_Product"."product"
FROM "Category_Product" "Category_Product"
WHERE 0 = 1

SELECT "Customer"."id", "Customer"."email", "Customer"."password", "Customer"."name", "Customer"."country", "Customer"."address"
FROM "Customer" "Customer"
WHERE 0 = 1

SELECT "Order"."id", "Order"."state", "Order"."date_created", "Order"."date_shipped", "Order"."date_delivered", "Order"."total_price", "Order"."customer"
FROM "Order" "Order"
WHERE 0 = 1

SELECT "OrderItem"."quantity", "OrderItem"."price", "OrderItem"."order", "OrderItem"."product"
FROM "OrderItem" "OrderItem"
WHERE 0 = 1

SELECT "Product"."id", "Product"."name", "Product"."description", "Product"."picture", "Product"."price", "Product"."quantity"
FROM "Product" "Product"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET NEW CONNECTION
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Numbers" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "int8" TINYINT NOT NULL,
  "int16" SMALLINT NOT NULL,
  "int24" MEDIUMINT NOT NULL,
  "int32" INTEGER NOT NULL,
  "int64" BIGINT NOT NULL,
  "uint8" TINYINT UNSIGNED NOT NULL,
  "uint16" SMALLINT UNSIGNED NOT NULL,
  "uint24" MEDIUMINT UNSIGNED NOT NULL,
  "uint32" INTEGER UNSIGNED NOT NULL
)

SELECT "Numbers"."id", "Numbers"."int8", "Numbers"."int16", "Numbers"."int24", "Numbers"."int32", "Numbers"."int64", "Numbers"."uint8", "Numbers"."uint16", "Numbers"."uint24", "Numbers"."uint32"
FROM "Numbers" "Numbers"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Department" (
  "number" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT UNIQUE NOT NULL
)

CREATE TABLE "Course" (
  "name" TEXT NOT NULL,
  "semester" INTEGER NOT NULL,
  "lect_hours" INTEGER NOT NULL,
  "lab_hours" INTEGER NOT NULL,
  "credits" INTEGER NOT NULL,
  "dept" INTEGER NOT NULL REFERENCES "Department" ("number"),
  PRIMARY KEY ("name", "semester")
)

CREATE INDEX "idx_course__dept" ON "Course" ("dept")

CREATE TABLE "Group" (
  "number" INTEGER NOT NULL PRIMARY KEY,
  "major" TEXT NOT NULL,
  "dept" INTEGER NOT NULL REFERENCES "Department" ("number")
)

CREATE INDEX "idx_group__dept" ON "Group" ("dept")

CREATE TABLE "Student" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "dob" DATE NOT NULL,
  "tel" TEXT NOT NULL,
  "picture" BLOB,
  "gpa" REAL NOT NULL,
  "group" INTEGER NOT NULL REFERENCES "Group" ("number")
)

CREATE INDEX "idx_student__group" ON "Student" ("group")

CREATE TABLE "Course_Student" (
  "course_name" TEXT NOT NULL,
  "course_semester" INTEGER NOT NULL,
  "student" INTEGER NOT NULL REFERENCES "Student" ("id"),
  PRIMARY KEY ("course_name", "course_semester", "student"),
  FOREIGN KEY ("course_name", "course_semester") REFERENCES "Course" ("name", "semester")
)

CREATE INDEX "idx_course_student" ON "Course_Student" ("student")

SELECT "Course"."name", "Course"."semester", "Course"."lect_hours", "Course"."lab_hours", "Course"."credits", "Course"."dept"
FROM "Course" "Course"
WHERE 0 = 1

SELECT "Course_Student"."course_name", "Course_Student"."course_semester", "Course_Student"."student"
FROM "Course_Student" "Course_Student"
WHERE 0 = 1

SELECT "Department"."number", "Department"."name"
FROM "Department" "Department"
WHERE 0 = 1

SELECT "Group"."number", "Group"."major", "Group"."dept"
FROM "Group" "Group"
WHERE 0 = 1

SELECT "Student"."id", "Student"."name", "Student"."dob", "Student"."tel", "Student"."picture", "Student"."gpa", "Student"."group"
FROM "Student" "Student"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Buildings" (
  "number" TEXT NOT NULL PRIMARY KEY,
  "description" TEXT NOT NULL
)

CREATE TABLE "Classrooms" (
  "building" TEXT NOT NULL REFERENCES "Buildings" ("number"),
  "number" TEXT NOT NULL,
  "description" TEXT NOT NULL,
  PRIMARY KEY ("building", "number")
)

CREATE TABLE "Faculties" (
  "number" INTEGER NOT NULL PRIMARY KEY,
  "name" TEXT UNIQUE NOT NULL
)

CREATE TABLE "Departments" (
  "number" INTEGER NOT NULL PRIMARY KEY,
  "name" TEXT UNIQUE NOT NULL,
  "faculty" INTEGER NOT NULL REFERENCES "Faculties" ("number")
)

CREATE INDEX "idx_departments__faculty" ON "Departments" ("faculty")

CREATE TABLE "Groups" (
  "number" INTEGER NOT NULL PRIMARY KEY,
  "grad_year" INTEGER NOT NULL,
  "dep" INTEGER NOT NULL REFERENCES "Departments" ("number")
)

CREATE INDEX "idx_groups__dep" ON "Groups" ("dep")

CREATE TABLE "Majors" (
  "name" TEXT NOT NULL PRIMARY KEY,
  "department" INTEGER NOT NULL REFERENCES "Departments" ("number")
)

CREATE INDEX "idx_majors__department" ON "Majors" ("department")

CREATE TABLE "Students" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "scholarship" DECIMAL(10, 2) NOT NULL,
  "group" INTEGER NOT NULL REFERENCES "Groups" ("number")
)

CREATE INDEX "idx_students__group" ON "Students" ("group")

CREATE TABLE "Subjects" (
  "name" TEXT NOT NULL PRIMARY KEY
)

CREATE TABLE "Courses" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "major" TEXT NOT NULL REFERENCES "Majors" ("name"),
  "subject" TEXT NOT NULL REFERENCES "Subjects" ("name"),
  "semester" INTEGER NOT NULL,
  "lect_hours" INTEGER NOT NULL,
  "pract_hours" INTEGER NOT NULL,
  "credit" INTEGER NOT NULL,
  CONSTRAINT "unq_courses__major_subject_semester" UNIQUE ("major", "subject", "semester")
)

CREATE INDEX "idx_courses__subject" ON "Courses" ("subject")

CREATE TABLE "Teachers" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "degree" TEXT NOT NULL,
  "department" INTEGER NOT NULL REFERENCES "Departments" ("number")
)

CREATE INDEX "idx_teachers__department" ON "Teachers" ("department")

CREATE TABLE "Grades" (
  "student" INTEGER NOT NULL REFERENCES "Students" ("id"),
  "course" INTEGER NOT NULL REFERENCES "Courses" ("id"),
  "teacher" INTEGER NOT NULL REFERENCES "Teachers" ("id"),
  "date" DATE NOT NULL,
  "value" TEXT NOT NULL,
  PRIMARY KEY ("student", "course")
)

CREATE INDEX "idx_grades__course" ON "Grades" ("course")

CREATE INDEX "idx_grades__teacher" ON "Grades" ("teacher")

CREATE TABLE "Lessons" (
  "day_of_week" INTEGER NOT NULL,
  "meeting_time" INTEGER NOT NULL,
  "classroom_building" TEXT NOT NULL,
  "classroom_number" TEXT NOT NULL,
  "course" INTEGER NOT NULL REFERENCES "Courses" ("id"),
  "teacher" INTEGER NOT NULL REFERENCES "Teachers" ("id"),
  PRIMARY KEY ("day_of_week", "meeting_time", "classroom_building", "classroom_number"),
  FOREIGN KEY ("classroom_building", "classroom_number") REFERENCES "Classrooms" ("building", "number")
)

CREATE INDEX "idx_lessons__classroom_building_classroom_number" ON "Lessons" ("classroom_building", "classroom_number")

CREATE INDEX "idx_lessons__course" ON "Lessons" ("course")

CREATE INDEX "idx_lessons__teacher" ON "Lessons" ("teacher")

CREATE TABLE "Group_Lesson" (
  "group" INTEGER NOT NULL REFERENCES "Groups" ("number"),
  "day_of_week" INTEGER NOT NULL,
  "meeting_time" INTEGER NOT NULL,
  "classroom_number" TEXT NOT NULL,
  "building" TEXT NOT NULL,
  PRIMARY KEY ("group", "day_of_week", "meeting_time", "classroom_number", "building"),
  FOREIGN KEY ("day_of_week", "meeting_time", "classroom_number", "building") REFERENCES "Lessons" ("day_of_week", "meeting_time", "classroom_building", "classroom_number")
)

CREATE INDEX "idx_group_lesson" ON "Group_Lesson" ("day_of_week", "meeting_time", "classroom_number", "building")

CREATE TABLE "Subject_Teacher" (
  "subject" TEXT NOT NULL REFERENCES "Subjects" ("name"),
  "teacher" INTEGER NOT NULL REFERENCES "Teachers" ("id"),
  PRIMARY KEY ("subject", "teacher")
)

CREATE INDEX "idx_subject_teacher" ON "Subject_Teacher" ("teacher")

SELECT "Buildings"."number", "Buildings"."description"
FROM "Buildings" "Buildings"
WHERE 0 = 1

SELECT "Classrooms"."building", "Classrooms"."number", "Classrooms"."description"
FROM "Classrooms" "Classrooms"
WHERE 0 = 1

SELECT "Courses"."id", "Courses"."major", "Courses"."subject", "Courses"."semester", "Courses"."lect_hours", "Courses"."pract_hours", "Courses"."credit"
FROM "Courses" "Courses"
WHERE 0 = 1

SELECT "Departments"."number", "Departments"."name", "Departments"."faculty"
FROM "Departments" "Departments"
WHERE 0 = 1

SELECT "Faculties"."number", "Faculties"."name"
FROM "Faculties" "Faculties"
WHERE 0 = 1

SELECT "Grades"."student", "Grades"."course", "Grades"."teacher", "Grades"."date", "Grades"."value"
FROM "Grades" "Grades"
WHERE 0 = 1

SELECT "Group_Lesson"."group", "Group_Lesson"."day_of_week", "Group_Lesson"."meeting_time", "Group_Lesson"."classroom_number", "Group_Lesson"."building"
FROM "Group_Lesson" "Group_Lesson"
WHERE 0 = 1

SELECT "Groups"."number", "Groups"."grad_year", "Groups"."dep"
FROM "Groups" "Groups"
WHERE 0 = 1

SELECT "Lessons"."day_of_week", "Lessons"."meeting_time", "Lessons"."classroom_building", "Lessons"."classroom_number", "Lessons"."course", "Lessons"."teacher"
FROM "Lessons" "Lessons"
WHERE 0 = 1

SELECT "Majors"."name", "Majors"."department"
FROM "Majors" "Majors"
WHERE 0 = 1

SELECT "Students"."id", "Students"."name", "Students"."scholarship", "Students"."group"
FROM "Students" "Students"
WHERE 0 = 1

SELECT "Subject_Teacher"."subject", "Subject_Teacher"."teacher"
FROM "Subject_Teacher" "Subject_Teacher"
WHERE 0 = 1
SELECT "Subjects"."name"
FROM "Subjects" "Subjects"
WHERE 0 = 1

SELECT "Teachers"."id", "Teachers"."name", "Teachers"."degree", "Teachers"."department"
FROM "Teachers" "Teachers"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
........................................
ImportError for database provider oracle:
No module named 'cx_Oracle'

....................................................Traceback (most recent call last):
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/dbapiprovider.py", line 53, in wrap_dbapi_exceptions
    try: return func(provider, *args, **kwargs)
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/dbapiprovider.py", line 263, in execute
    if arguments is None: cursor.execute(sql)
sqlite3.OperationalError: no such table: Person

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "setup.py", line 119, in <module>
    download_url=download_url
  File "/usr/lib/python3.6/site-packages/setuptools/__init__.py", line 140, in setup
    return distutils.core.setup(**attrs)
  File "/usr/lib64/python3.6/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/usr/lib64/python3.6/distutils/dist.py", line 955, in run_commands
    self.run_command(cmd)
  File "/usr/lib64/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 228, in run
    self.run_tests()
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 250, in run_tests
    exit=False,
  File "/usr/lib64/python3.6/unittest/main.py", line 94, in __init__
    self.parseArgs(argv)
  File "/usr/lib64/python3.6/unittest/main.py", line 118, in parseArgs
    self._do_discovery(argv[2:])
  File "/usr/lib64/python3.6/unittest/main.py", line 229, in _do_discovery
    self.test = loader.discover(self.start, self.pattern, self.top)
  File "/usr/lib64/python3.6/unittest/loader.py", line 341, in discover
    tests = list(self._find_tests(start_dir, pattern))
  File "/usr/lib64/python3.6/unittest/loader.py", line 398, in _find_tests
    full_path, pattern, namespace)
  File "/usr/lib64/python3.6/unittest/loader.py", line 475, in _find_test_path
    tests = self.loadTestsFromModule(package, pattern=pattern)
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 54, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/usr/lib64/python3.6/unittest/loader.py", line 190, in loadTestsFromName
    return self.loadTestsFromModule(obj)
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 54, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/usr/lib64/python3.6/unittest/loader.py", line 190, in loadTestsFromName
    return self.loadTestsFromModule(obj)
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 54, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/usr/lib64/python3.6/unittest/loader.py", line 153, in loadTestsFromName
    module = __import__(module_name)
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/tests/test_autostrip.py", line 12, in <module>
    db.generate_mapping(create_tables=True)
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/tests/testutils.py", line 139, in generate_mapping
    return Database.generate_mapping(database, filename, create_tables=False)
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/core.py", line 1042, in generate_mapping
    elif check_tables: database.check_tables()
  File "<string>", line 2, in check_tables
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/core.py", line 467, in new_func
    result = func(*args, **kwargs)
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/core.py", line 1115, in check_tables
    database.schema.check_tables(database.provider, connection)
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/dbschema.py", line 78, in check_tables
    provider.execute(cursor, sql)
  File "<string>", line 2, in execute
  File "/home/antonio/obs/home/alarrosa/branches/devel/languages/python/flask/python-pony/pony-0.7.6/pony/orm/dbapiprovider.py", line 61, in wrap_dbapi_exceptions
    raise OperationalError(e)
pony.orm.dbapiprovider.OperationalError: no such table: Person

Curiously, if I run the tests under a chrooted environment in obs, in order to build an openSUSE package for pony, the python2 build fails (and I could fix it with this patch) but the python3 build fails with a similar but different error than the above one:

> python3 setup.py test
click to open the rest of the test output
running test
running egg_info
writing pony.egg-info/PKG-INFO
writing dependency_links to pony.egg-info/dependency_links.txt
writing top-level names to pony.egg-info/top_level.txt
reading manifest file 'pony.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'pony/flask/example/templates'
warning: no files found matching '*.html'
writing manifest file 'pony.egg-info/SOURCES.txt'
running build_ext
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Group" (
  "dept" INTEGER NOT NULL,
  "grad_year" INTEGER NOT NULL,
  PRIMARY KEY ("dept", "grad_year")
)

CREATE TABLE "Student" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "age" INTEGER,
  "group_dept" INTEGER NOT NULL,
  "group_grad_year" INTEGER NOT NULL,
  FOREIGN KEY ("group_dept", "group_grad_year") REFERENCES "Group" ("dept", "grad_year")
)

CREATE INDEX "idx_student__group_dept_group_grad_year" ON "Student" ("group_dept", "group_grad_year")

CREATE TABLE "Bio" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "picture" BLOB,
  "desc" TEXT NOT NULL,
  "Student" INTEGER NOT NULL REFERENCES "Student" ("id")
)

CREATE INDEX "idx_bio__student" ON "Bio" ("Student")

CREATE TABLE "Student_friends" (
  "student" INTEGER NOT NULL REFERENCES "Student" ("id"),
  "student_2" INTEGER NOT NULL REFERENCES "Student" ("id"),
  PRIMARY KEY ("student", "student_2")
)

CREATE INDEX "idx_student_friends" ON "Student_friends" ("student_2")

SELECT "Bio"."id", "Bio"."picture", "Bio"."desc", "Bio"."Student"
FROM "Bio" "Bio"
WHERE 0 = 1

SELECT "Group"."dept", "Group"."grad_year"
FROM "Group" "Group"
WHERE 0 = 1

SELECT "Student"."id", "Student"."name", "Student"."age", "Student"."group_dept", "Student"."group_grad_year"
FROM "Student" "Student"
WHERE 0 = 1

SELECT "Student_friends"."student", "Student_friends"."student_2"
FROM "Student_friends" "Student_friends"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Groups" (
  "number" TEXT NOT NULL PRIMARY KEY,
  "department" INTEGER NOT NULL
)

CREATE TABLE "Students" (
  "record" INTEGER NOT NULL PRIMARY KEY,
  "fio" TEXT NOT NULL,
  "group" TEXT NOT NULL REFERENCES "Groups" ("number"),
  "scholarship" INTEGER NOT NULL
)

CREATE INDEX "idx_students__group" ON "Students" ("group")

CREATE TABLE "Subjects" (
  "name" TEXT NOT NULL PRIMARY KEY
)

CREATE TABLE "Exams" (
  "student" INTEGER NOT NULL REFERENCES "Students" ("record"),
  "subject" TEXT NOT NULL REFERENCES "Subjects" ("name"),
  "value" INTEGER NOT NULL,
  PRIMARY KEY ("student", "subject")
)

CREATE INDEX "idx_exams__subject" ON "Exams" ("subject")

CREATE TABLE "Group_Subject" (
  "group" TEXT NOT NULL REFERENCES "Groups" ("number"),
  "subject" TEXT NOT NULL REFERENCES "Subjects" ("name"),
  PRIMARY KEY ("group", "subject")
)

CREATE INDEX "idx_group_subject" ON "Group_Subject" ("subject")

SELECT "Exams"."student", "Exams"."subject", "Exams"."value"
FROM "Exams" "Exams"
WHERE 0 = 1

SELECT "Group_Subject"."group", "Group_Subject"."subject"
FROM "Group_Subject" "Group_Subject"
WHERE 0 = 1

SELECT "Groups"."number", "Groups"."department"
FROM "Groups" "Groups"
WHERE 0 = 1

SELECT "Students"."record", "Students"."fio", "Students"."group", "Students"."scholarship"
FROM "Students" "Students"
WHERE 0 = 1

SELECT "Subjects"."name"
FROM "Subjects" "Subjects"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Subjects" ("name") VALUES (?)
['Physics']

INSERT INTO "Subjects" ("name") VALUES (?)
['Chemistry']

INSERT INTO "Subjects" ("name") VALUES (?)
['Math']

INSERT INTO "Groups" ("number", "department") VALUES (?, ?)
['3132', 33]

INSERT INTO "Groups" ("number", "department") VALUES (?, ?)
['4145', 44]

INSERT INTO "Groups" ("number", "department") VALUES (?, ?)
['4146', 44]

INSERT INTO "Students" ("record", "fio", "group", "scholarship") VALUES (?, ?, ?, ?)
[101, 'Bob', '4145', 0]

INSERT INTO "Students" ("record", "fio", "group", "scholarship") VALUES (?, ?, ?, ?)
[102, 'Joe', '4145', 800]

INSERT INTO "Students" ("record", "fio", "group", "scholarship") VALUES (?, ?, ?, ?)
[103, 'Alex', '4145', 0]

INSERT INTO "Students" ("record", "fio", "group", "scholarship") VALUES (?, ?, ?, ?)
[104, 'Brad', '3132', 500]

INSERT INTO "Students" ("record", "fio", "group", "scholarship") VALUES (?, ?, ?, ?)
[105, 'John', '3132', 1000]

INSERT INTO "Exams" ("student", "subject", "value") VALUES (?, ?, ?)
[101, 'Physics', 4]

INSERT INTO "Exams" ("student", "subject", "value") VALUES (?, ?, ?)
[101, 'Math', 3]

INSERT INTO "Exams" ("student", "subject", "value") VALUES (?, ?, ?)
[102, 'Chemistry', 5]

INSERT INTO "Exams" ("student", "subject", "value") VALUES (?, ?, ?)
[103, 'Physics', 2]

INSERT INTO "Exams" ("student", "subject", "value") VALUES (?, ?, ?)
[103, 'Chemistry', 4]

EXECUTEMANY (5)
INSERT INTO "Group_Subject" ("group", "subject") VALUES (?, ?)
['4145', 'Physics']
['3132', 'Physics']
['4145', 'Chemistry']
['3132', 'Math']
['4145', 'Math']

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Person" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "first_name" TEXT NOT NULL,
  "last_name" TEXT NOT NULL,
  "favorite_color" TEXT NOT NULL
)

CREATE TABLE "Car" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "brand" TEXT NOT NULL,
  "model" TEXT NOT NULL,
  "owner" INTEGER REFERENCES "Person" ("id"),
  "year" INTEGER NOT NULL,
  "price" INTEGER NOT NULL,
  "color" TEXT NOT NULL
)

CREATE INDEX "idx_car__owner" ON "Car" ("owner")

SELECT "Car"."id", "Car"."brand", "Car"."model", "Car"."owner", "Car"."year", "Car"."price", "Car"."color"
FROM "Car" "Car"
WHERE 0 = 1

SELECT "Person"."id", "Person"."first_name", "Person"."last_name", "Person"."favorite_color"
FROM "Person" "Person"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Person" ("first_name", "last_name", "favorite_color") VALUES (?, ?, ?)
['Alexander', 'Kozlovsky', 'white']

INSERT INTO "Person" ("first_name", "last_name", "favorite_color") VALUES (?, ?, ?)
['Alexei', 'Malashkevich', 'green']

INSERT INTO "Person" ("first_name", "last_name", "favorite_color") VALUES (?, ?, ?)
['Vitaliy', 'Abetkin', '']

INSERT INTO "Person" ("first_name", "last_name", "favorite_color") VALUES (?, ?, ?)
['Alexander', 'Tischenko', 'blue']

INSERT INTO "Car" ("brand", "model", "owner", "year", "price", "color") VALUES (?, ?, ?, ?, ?, ?)
['Peugeot', '306', 1, 2006, 14000, 'red']

INSERT INTO "Car" ("brand", "model", "owner", "year", "price", "color") VALUES (?, ?, ?, ?, ?, ?)
['Honda', 'Accord', 1, 2007, 13850, 'white']

INSERT INTO "Car" ("brand", "model", "owner", "year", "price", "color") VALUES (?, ?, ?, ?, ?, ?)
['Nissan', 'Skyline', 2, 2008, 29900, 'black']

INSERT INTO "Car" ("brand", "model", "owner", "year", "price", "color") VALUES (?, ?, ?, ?, ?, ?)
['Volkswagen', 'Passat', 1, 2012, 9400, 'blue']

INSERT INTO "Car" ("brand", "model", "owner", "year", "price", "color") VALUES (?, ?, ?, ?, ?, ?)
['Koenigsegg', 'CCXR', 4, 2016, 4850000, 'white']

INSERT INTO "Car" ("brand", "model", "owner", "year", "price", "color") VALUES (?, ?, ?, ?, ?, ?)
['Lada', 'Kalina', 4, 2015, 5000, 'white']

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Department" (
  "number" INTEGER NOT NULL PRIMARY KEY
)

CREATE TABLE "Course" (
  "name" TEXT NOT NULL PRIMARY KEY,
  "department" INTEGER NOT NULL REFERENCES "Department" ("number")
)

CREATE INDEX "idx_course__department" ON "Course" ("department")

CREATE TABLE "Group" (
  "number" INTEGER NOT NULL PRIMARY KEY,
  "department" INTEGER NOT NULL REFERENCES "Department" ("number")
)

CREATE INDEX "idx_group__department" ON "Group" ("department")

CREATE TABLE "Student" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "group" INTEGER NOT NULL REFERENCES "Group" ("number")
)

CREATE INDEX "idx_student__group" ON "Student" ("group")

CREATE TABLE "Course_Student" (
  "course" TEXT NOT NULL REFERENCES "Course" ("name"),
  "student" INTEGER NOT NULL REFERENCES "Student" ("id"),
  PRIMARY KEY ("course", "student")
)

CREATE INDEX "idx_course_student" ON "Course_Student" ("student")

SELECT "Course"."name", "Course"."department"
FROM "Course" "Course"
WHERE 0 = 1

SELECT "Course_Student"."course", "Course_Student"."student"
FROM "Course_Student" "Course_Student"
WHERE 0 = 1

SELECT "Department"."number"
FROM "Department" "Department"
WHERE 0 = 1

SELECT "Group"."number", "Group"."department"
FROM "Group" "Group"
WHERE 0 = 1

SELECT "Student"."id", "Student"."name", "Student"."group"
FROM "Student" "Student"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Department" ("number") VALUES (?)
[1]

INSERT INTO "Department" ("number") VALUES (?)
[2]

INSERT INTO "Department" ("number") VALUES (?)
[3]

INSERT INTO "Group" ("number", "department") VALUES (?, ?)
[101, 1]

INSERT INTO "Group" ("number", "department") VALUES (?, ?)
[102, 1]

INSERT INTO "Group" ("number", "department") VALUES (?, ?)
[201, 2]

INSERT INTO "Course" ("name", "department") VALUES (?, ?)
['C1', 1]

INSERT INTO "Course" ("name", "department") VALUES (?, ?)
['C2', 1]

INSERT INTO "Course" ("name", "department") VALUES (?, ?)
['C3', 2]

INSERT INTO "Course" ("name", "department") VALUES (?, ?)
['C4', 2]

INSERT INTO "Course" ("name", "department") VALUES (?, ?)
['C5', 3]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S1', 101]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S2', 101]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S3', 101]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S4', 102]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S5', 102]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['A', 201]

EXECUTEMANY (11)
INSERT INTO "Course_Student" ("course", "student") VALUES (?, ?)
['C1', 5]
['C2', 4]
['C1', 1]
['C3', 3]
['C2', 3]
['C1', 2]
['C2', 5]
['C1', 4]
['C5', 6]
['C2', 1]
['C3', 2]

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Person" (
  "id" INTEGER NOT NULL PRIMARY KEY,
  "name" TEXT NOT NULL
)

SELECT "Person"."id", "Person"."name"
FROM "Person" "Person"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Person" ("id", "name") VALUES (?, ?)
[1, 'John']

INSERT INTO "Person" ("id", "name") VALUES (?, ?)
[2, 'Mary']

INSERT INTO "Person" ("id", "name") VALUES (?, ?)
[3, 'Bob']

INSERT INTO "Person" ("id", "name") VALUES (?, ?)
[4, 'Mike']

INSERT INTO "Person" ("id", "name") VALUES (?, ?)
[5, 'Ann']

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Course" (
  "name" TEXT NOT NULL,
  "semester" INTEGER NOT NULL,
  PRIMARY KEY ("name", "semester")
)

CREATE TABLE "Department" (
  "number" INTEGER NOT NULL PRIMARY KEY
)

CREATE TABLE "Group" (
  "number" INTEGER NOT NULL PRIMARY KEY,
  "dept" INTEGER NOT NULL REFERENCES "Department" ("number")
)

CREATE INDEX "idx_group__dept" ON "Group" ("dept")

CREATE TABLE "Student" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "dob" DATE,
  "gpa" REAL,
  "scholarship" DECIMAL(7, 2),
  "group" INTEGER NOT NULL REFERENCES "Group" ("number")
)

CREATE INDEX "idx_student__group" ON "Student" ("group")

CREATE TABLE "Course_Student" (
  "course_name" TEXT NOT NULL,
  "course_semester" INTEGER NOT NULL,
  "student" INTEGER NOT NULL REFERENCES "Student" ("id"),
  PRIMARY KEY ("course_name", "course_semester", "student"),
  FOREIGN KEY ("course_name", "course_semester") REFERENCES "Course" ("name", "semester")
)

CREATE INDEX "idx_course_student" ON "Course_Student" ("student")

SELECT "Course"."name", "Course"."semester"
FROM "Course" "Course"
WHERE 0 = 1

SELECT "Course_Student"."course_name", "Course_Student"."course_semester", "Course_Student"."student"
FROM "Course_Student" "Course_Student"
WHERE 0 = 1

SELECT "Department"."number"
FROM "Department" "Department"
WHERE 0 = 1

SELECT "Group"."number", "Group"."dept"
FROM "Group" "Group"
WHERE 0 = 1

SELECT "Student"."id", "Student"."name", "Student"."dob", "Student"."gpa", "Student"."scholarship", "Student"."group"
FROM "Student" "Student"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Department" ("number") VALUES (?)
[44]

INSERT INTO "Group" ("number", "dept") VALUES (?, ?)
[101, 44]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S1', 101]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S2', 101]

INSERT INTO "Student" ("name", "group") VALUES (?, ?)
['S3', 101]

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Course" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT UNIQUE NOT NULL
)

CREATE TABLE "Group" (
  "number" INTEGER NOT NULL PRIMARY KEY
)

CREATE TABLE "Student" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "scholarship" INTEGER,
  "gpa" DECIMAL(3, 1),
  "dob" DATE,
  "group" INTEGER REFERENCES "Group" ("number"),
  "biography" TEXT NOT NULL
)

CREATE INDEX "idx_student__group" ON "Student" ("group")

CREATE TABLE "Course_Student" (
  "course" INTEGER NOT NULL REFERENCES "Course" ("id"),
  "student" INTEGER NOT NULL REFERENCES "Student" ("id"),
  PRIMARY KEY ("course", "student")
)

CREATE INDEX "idx_course_student" ON "Course_Student" ("student")

SELECT "Course"."id", "Course"."name"
FROM "Course" "Course"
WHERE 0 = 1

SELECT "Course_Student"."course", "Course_Student"."student"
FROM "Course_Student" "Course_Student"
WHERE 0 = 1

SELECT "Group"."number"
FROM "Group" "Group"
WHERE 0 = 1

SELECT "Student"."id", "Student"."name", "Student"."scholarship", "Student"."gpa", "Student"."dob", "Student"."group", "Student"."biography"
FROM "Student" "Student"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Group" ("number") VALUES (?)
[1]

INSERT INTO "Group" ("number") VALUES (?)
[2]

INSERT INTO "Course" ("name") VALUES (?)
['Math']

INSERT INTO "Course" ("name") VALUES (?)
['Physics']

INSERT INTO "Course" ("name") VALUES (?)
['Computer Science']

INSERT INTO "Student" ("id", "name", "gpa", "group", "biography") VALUES (?, ?, ?, ?, ?)
[1, 'S1', '3.1', 1, 'some text']

INSERT INTO "Student" ("id", "name", "scholarship", "gpa", "dob", "group", "biography") VALUES (?, ?, ?, ?, ?, ?, ?)
[2, 'S2', 100, '3.2', '2000-01-01', 1, '']

INSERT INTO "Student" ("id", "name", "scholarship", "gpa", "dob", "group", "biography") VALUES (?, ?, ?, ?, ?, ?, ?)
[3, 'S3', 200, '3.3', '2001-01-02', 1, '']

INSERT INTO "Student" ("id", "name", "biography") VALUES (?, ?, ?)
[4, 'S4', '']

EXECUTEMANY (4)
INSERT INTO "Course_Student" ("course", "student") VALUES (?, ?)
[2, 1]
[3, 3]
[1, 1]
[2, 3]

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
PRAGMA foreign_keys = false
BEGIN IMMEDIATE TRANSACTION
CREATE TABLE "Group" (
  "number" INTEGER NOT NULL PRIMARY KEY
)

CREATE TABLE "Student" (
  "id" INTEGER PRIMARY KEY AUTOINCREMENT,
  "name" TEXT NOT NULL,
  "scholarship" INTEGER,
  "gpa" DECIMAL(3, 1),
  "group" INTEGER NOT NULL REFERENCES "Group" ("number"),
  "dob" DATE
)

CREATE INDEX "idx_student__group" ON "Student" ("group")

SELECT "Group"."number"
FROM "Group" "Group"
WHERE 0 = 1

SELECT "Student"."id", "Student"."name", "Student"."scholarship", "Student"."gpa", "Student"."group", "Student"."dob"
FROM "Student" "Student"
WHERE 0 = 1

COMMIT
PRAGMA foreign_keys = true
CLOSE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
BEGIN IMMEDIATE TRANSACTION
INSERT INTO "Group" ("number") VALUES (?)
[1]

INSERT INTO "Student" ("id", "name", "gpa", "group") VALUES (?, ?, ?, ?)
[1, 'S1', '3.1', 1]

INSERT INTO "Student" ("id", "name", "scholarship", "gpa", "group", "dob") VALUES (?, ?, ?, ?, ?, ?)
[2, 'S2', 100, '3.2', 1, '2000-01-01']

INSERT INTO "Student" ("id", "name", "scholarship", "gpa", "group", "dob") VALUES (?, ?, ?, ?, ?, ?)
[3, 'S3', 200, '3.3', 1, '2001-01-02']

COMMIT
RELEASE CONNECTION
GET NEW CONNECTION
RELEASE CONNECTION
GET CONNECTION FROM THE LOCAL POOL
SWITCH TO AUTOCOMMIT MODE
SELECT "CartItem"."id", "CartItem"."quantity", "CartItem"."customer", "CartItem"."product"
FROM "CartItem" "CartItem"
WHERE 0 = 1

ROLLBACK
RELEASE CONNECTION
Traceback (most recent call last):
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/dbapiprovider.py", line 53, in wrap_dbapi_exceptions
    try: return func(provider, *args, **kwargs)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/dbapiprovider.py", line 263, in execute
    if arguments is None: cursor.execute(sql)
sqlite3.OperationalError: no such table: CartItem

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "setup.py", line 119, in <module>
    download_url=download_url
  File "/usr/lib/python3.6/site-packages/setuptools/__init__.py", line 140, in setup
    return distutils.core.setup(**attrs)
  File "/usr/lib64/python3.6/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/usr/lib64/python3.6/distutils/dist.py", line 955, in run_commands
    self.run_command(cmd)
  File "/usr/lib64/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 228, in run
    self.run_tests()
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 250, in run_tests
    exit=False,
  File "/usr/lib64/python3.6/unittest/main.py", line 94, in __init__
    self.parseArgs(argv)
  File "/usr/lib64/python3.6/unittest/main.py", line 118, in parseArgs
    self._do_discovery(argv[2:])
  File "/usr/lib64/python3.6/unittest/main.py", line 229, in _do_discovery
    self.test = loader.discover(self.start, self.pattern, self.top)
  File "/usr/lib64/python3.6/unittest/loader.py", line 341, in discover
    tests = list(self._find_tests(start_dir, pattern))
  File "/usr/lib64/python3.6/unittest/loader.py", line 398, in _find_tests
    full_path, pattern, namespace)
  File "/usr/lib64/python3.6/unittest/loader.py", line 475, in _find_test_path
    tests = self.loadTestsFromModule(package, pattern=pattern)
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 54, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/usr/lib64/python3.6/unittest/loader.py", line 190, in loadTestsFromName
    return self.loadTestsFromModule(obj)
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 54, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/usr/lib64/python3.6/unittest/loader.py", line 190, in loadTestsFromName
    return self.loadTestsFromModule(obj)
  File "/usr/lib/python3.6/site-packages/setuptools/command/test.py", line 54, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File "/usr/lib64/python3.6/unittest/loader.py", line 153, in loadTestsFromName
    module = __import__(module_name)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/tests/sql_tests.py", line 119, in <module>
    elif lines: orphan_lines(lines)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/tests/sql_tests.py", line 96, in orphan_lines
    SQLite(None)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/tests/sql_tests.py", line 30, in SQLite
    do_test('sqlite', server_version)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/tests/sql_tests.py", line 49, in do_test
    try: __import__(module_name)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/examples/estore.py", line 59, in <module>
    db.generate_mapping(create_tables=True)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/tests/testutils.py", line 139, in generate_mapping
    return Database.generate_mapping(database, filename, create_tables=False)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/core.py", line 1042, in generate_mapping
    elif check_tables: database.check_tables()
  File "<string>", line 2, in check_tables
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/core.py", line 467, in new_func
    result = func(*args, **kwargs)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/core.py", line 1115, in check_tables
    database.schema.check_tables(database.provider, connection)
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/dbschema.py", line 78, in check_tables
    provider.execute(cursor, sql)
  File "<string>", line 2, in execute
  File "/home/abuild/rpmbuild/BUILD/pony-0.7.6/pony/orm/dbapiprovider.py", line 61, in wrap_dbapi_exceptions
    raise OperationalError(e)
pony.orm.dbapiprovider.OperationalError: no such table: CartItem

Any idea of what's happening?

@sashaaero sashaaero closed this in 890ee84 Oct 3, 2018

@sashaaero

This comment has been minimized.

Copy link
Member

sashaaero commented Oct 3, 2018

Hello, antlarr-suse! Thanks for reporting. Fixed now. You can fetch this version of pony from github or wait for next release.
Any idea of what's happening? Yes, we didn't expect for this tests running and didnt cofigure it.
We were only using python -m unittest discover.
Anyway thanks for remind.

kozlovsky added a commit that referenced this issue Jan 17, 2019

PonyORM release 0.7.7 (2019-01-17)
# Major features

* Array type support for PostgreSQL and SQLite
* isinstance() support in queries
* Support of queries based on collections: select(x for x in y.items)

# Other features

* Support of Entity.select(**kwargs)
* Support of SKIP LOCKED option in 'SELECT ... FOR UPDATE'
* New function make_proxy(obj) to make cros-db_session proxy objects
* Specify ON DELETE CASCADE/SET NULL in foreign keys
* Support of LIMIT in `SELECT FROM (SELECT ...)` type of queries
* Support for negative JSON array indexes in SQLite

# Improvements

* Improved query prefetching: use fewer number of SQL queries
* Memory optimization: deduplication of values recieved from the database in the same session
* increase DBAPIProvider.max_params_count value

# Bugfixes

* #405: breaking change with cx_Oracle 7.0: DML RETURNING now returns a list
* #380: db_session should work with async functions
* #385: test fails with python3.6
* #386: release unlocked lock error in SQLite
* #390: TypeError: writable buffers are not hashable
* #398: add auto coversion of numpy numeric types
* #404: GAE local run detection
* Fix Flask compatibility: add support of LocalProxy object
* db_session(sql_debug=True) should log SQL commands also during db_session.__exit__()
* Fix duplicated table join in FROM clause
* Fix accessing global variables from hybrid methods and properties
* Fix m2m collection loading bug
* Fix composite index bug: stackoverflow.com/questions/53147694
* Fix MyEntity[obj.get_pk()] if pk is composite
* MySQL group_concat_max_len option set to max of 32bit platforms to avoid truncation
* Show all attribute options in show(Entity) call
* For nested db_session retry option should be ignored
* Fix py_json_unwrap
* Other minor fixes
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment