Skip to content

Conversation

@Sesquipedalian
Copy link
Member

@Sesquipedalian Sesquipedalian commented Feb 8, 2024

@jdarwood007, let's use this to work collaboratively on the installer/upgrader rewrite.

  • Add Schema for 3.0
  • Add Initial framework for Maintenance logic
  • Build Installer logic
  • Setup Migration logic for upgrades from SMF 2.0 to 2.1
  • Setup Migration logic for upgrades from SMF 2.1 to 3.0
  • Test Installer logic
  • Build Upgrader logic
  • Test Upgrader logic
  • Build Converter Logic
  • Setup Converter logic for YabbSE
  • Setup Converter logic for SMF 1.0
  • Setup Converter logic for SMF 1.1
  • Build Repair Settings tool
  • Build logic for self-contained tools to utilize the maintenance logic.
  • Add logic back for installer to work with compression (?obgz)
  • Allow upgrader to support login or entering in the database password.

Fixes #8261

@Sesquipedalian Sesquipedalian added this to the 3.0 Alpha 2 milestone Feb 8, 2024
@Sesquipedalian Sesquipedalian changed the title Creates SMF\Db\Schema and descendents Installer and upgrader rewrite Feb 8, 2024
@Sesquipedalian Sesquipedalian reopened this Feb 8, 2024
@jdarwood007
Copy link
Member

jdarwood007 commented Feb 9, 2024

A lot is incoming, it's my initial work I started to write the installer logic. You should be able to get through an install. But the base logic should get it going for an upgrader and converter logic.

@jdarwood007
Copy link
Member

I've also added some task notes based on what I was thinking, please amend or adjust.

@Sesquipedalian
Copy link
Member Author

Sesquipedalian commented Feb 13, 2024

Please remember not to force-push to a shared branch, @jdarwood007. I was able to reconcile the differences in my local repository fairly easily this time, but another time I might not be so lucky.

Sesquipedalian and others added 5 commits February 13, 2024 17:06
Signed-off-by: Jon Stovell <jonstovell@gmail.com>
Co-authored-by: John Rayes <live627@gmail.com>
Signed-off-by: Jon Stovell <jonstovell@gmail.com>
Signed-off-by: Jon Stovell <jonstovell@gmail.com>
Signed-off-by: Jon Stovell <jonstovell@gmail.com>
@jdarwood007
Copy link
Member

@Sesquipedalian
I'm running into an error:
( ! ) Fatal error: Uncaught Error: Typed static property SMF\User::$me must not be accessed before initialization in /Sources/BrowserDetector.php on line 131

Its being called in the Migration/v2_1/BoardDescriptions

					'name' => Utils::htmlspecialchars(strip_tags(BBCodeParser::load()->unparse($row['name']))),

What is the optimal call here to put the best effort that SMF can do to safely startup the User::$me object? Keeping in mind we may be coming from a env in which it may not be able to startup things.

@jdarwood007
Copy link
Member

		// Load up the current user safely.
		$p = User::load(0);
		User::$me = $p[0];

This seems to call ok.

@Sesquipedalian
Copy link
Member Author

Sesquipedalian commented Aug 9, 2024

		// Load up the current user safely.
		$p = User::load(0);
		User::$me = $p[0];

This seems to call ok.

This would be better:

		// Load up the current user safely.
		User::setMe(0);

Also, is it indeed the intention here to load a guest user? Because that's what loading user 0 does.

@Sesquipedalian
Copy link
Member Author

Moved to Alpha 4 as per the internal roadmap.

@Sesquipedalian
Copy link
Member Author

Due to of a lot of ugliness and misery involved in trying to resolve conflicts, and due to @jdarwood007 informing me that he has limited time to work on it for the next while, I've decided to close this PR and reimplement this code in a new one. The fundamental logic is all there now thanks to @jdarwood007's work, so I will just need to make a few adjustments and finish off the remaining migration step classes, etc., that have not been written yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[3.0]: Check for "calendar_holidays" table during upgrade could return false positives

6 participants