I already wrote this on the forums, but I managed to fix that by using a CheckModel. The test runner creates a CheckModel on the main process’s default database at the very start of running checks and when the ChecksDidRun test occurs, we switch the database connection temporarily to the main process’s default database, run a query to check if the CheckModel was created, and if so, the test passes.
The only problem with the above is when multiple checks are run during the same test run. We could have a false positive test pass, so I’ll have to add a delete query before switching back to the worker database.
On SQLite, the test runner cannot be run in reverse consistently, there seems to be an internal failure with tests that use the databases in the servers test app.
On PostgreSQL, there’s the m2m_through failure I mentioned to Carlton on the forums, and there’s a multiple_database failure when running the test suite in reverse.
On MySQL, there are a myriad of failures that I’ll be addressing over the next couple of days after finalizing SQLite and PostgreSQL.
SQLite and PostgreSQL should be completely done over the next 2 days and I’ll start tackling MySQL from beginning to end after.
Since backup
isn’t supported on PY<3.7, and Django officially supports 3.6, I’m going to refactor the cloning process to use VACUUM INTO
instead.
To say this has been a learning experience would be an understatement. I’ve never worked with databases before in my entire life, I’ve never written a SQL query, and I’ve never ran tests using multiprocessing or multithreading or anything like that. Being put in an environment where I must learn all of these things on my own to make my project, something I’m passionate about, work is amazing quite frankly. I’ve learned more about databases than I think I’ll learn next semester when I take an actual databases course at my university, and I’ve learned so much about software development and project management.
The last month has been an uncertain time period for many of us, myself included. I had hoped my initial planning and scheduling would suffice, but alas, no plan survives first contact. My exams cost me two weeks that I attempted to make up for by working early, and my lack of communication whether by posting more regularly on the forums or finalizing my blogposts on this blog cost me help that I could’ve gotten sooner from mentors or community members.
Moving forward, I’m going to adopt a more task-focused workflow where I’ll ping the forum posts for my current tasks, my finished tasks, and my upcoming tasks. With my exams done, my next milestone should be much easier to tackle hopefully. I’ll be posting a detailed breakdown of tasks for the Oracle milestone, when I’ll need code reviews, and how I’m going to deal with any work left over from the last milestone. This is inspired from David Smith’s comment, and all credit goes to his inner project manager.
Also, I think I’m comfortable enough writing these blog posts that I’ll be able to finalize them without much anxiety over their quality weekly.