When I upgraded two forums to phpBB 3 from phpBB 2, some text apparently got messed up. The problem is classic; it took UTF-8 text, interpreted it as Latin-1, and then re-encoded it as UTF-8. This appears to be a problem with the converter - there are several threads on the phpBB forums about it, which I would link if their forums were currently available. I can correct that with a bit of SQL.
Unfortunately, the second forum converted got doubly butchered. I'm not sure exactly how, but it seems some sequences were unrecoverably damaged. That is, some are fine (well, at least recoverable by double-decoding), but some end with an invalid character. I'll need to manually search-and-replace the most common miscoded characters.
Various technical articles, IT-related tutorials, software information, and development journals
Friday, December 30, 2016
Thursday, December 29, 2016
Policy Plus - Show the last sources
Since it's possible that people might not remember what policy sources they were editing last time, and given that Policy Plus now remembers the last policy source (which is almost always the convenient thing to do), it's important for people to be able to see what they're currently editing. Therefore, I added a bit of code to the startup routine that sets up the "Open Policy Resources" dialog to be in a state that would produce the last policy loaders.
Wednesday, December 28, 2016
When the phpBB 3 upgrade fails with 500 Internal Server Error
Today I migrated two phpBB 2 forums to phpBB 3. The first went perfectly smoothly with no unexpected messages at all. The second had a couple apparently non-fatal warnings, but then in the middle of the database upgrade process it just halted with an HTTP 500 error. I could get no useful information out of the log. After hours of fiddling and refreshing and Googling, I found that some posts in the old database were tripping up the parser.
To figure out exactly which ones were problematic, I went into the new database and got the maximum post ID out of the posts table. I then queried for the posts in the old database with an ID starting a little bit before that number. Sure enough, one a little after the last successfully migrated post was insanely long with a bunch of weird markup. After replacing its content with a little note about why I had to remove it, the updater continued successfully!
To figure out exactly which ones were problematic, I went into the new database and got the maximum post ID out of the posts table. I then queried for the posts in the old database with an ID starting a little bit before that number. Sure enough, one a little after the last successfully migrated post was insanely long with a bunch of weird markup. After replacing its content with a little note about why I had to remove it, the updater continued successfully!
Tuesday, December 27, 2016
Students can get AutoDesk products for free
AutoDesk makes software for architects, engineers, manufacturers, and animators. For example, they're the company behind 3ds Max, the powerful 3D modeling and animation program. I had heard of their products, but until recently I didn't know I could actually get them.
If you're a student with a .edu address, they let you have quite a bit of their software for free for three years for educational purposes. Visit their education section for more information and to install the software.
If you're a student with a .edu address, they let you have quite a bit of their software for free for three years for educational purposes. Visit their education section for more information and to install the software.
Monday, December 26, 2016
Policy Plus - Remember the last settings
If you open an alternate ADMX source, it's likely that you want to continue using it in future launches of Policy Plus. Before, Policy Plus just opened the default PolicyDefinitions folder and the normal local GPOs at startup. Today I added a little configuration manager to read and write settings from the Registry. At startup, Policy Plus loads the last ADMX source and policy sources. The ADMX source setting is updated whenever a full new source is opened; the policy source settings are updated when the policies are saved.
Sunday, December 25, 2016
Batch-like wildcards in PowerShell
Several commands and utilities used in batch scripting take filename filters that use * and ? as wildcards for multiple characters and exactly one character, respectively. In PowerShell, that kind of matching can be done with the -like operator, but it has a couple extra features (e.g. # for a numeric character) that make it not match batch behavior exactly. Therefore, to use it on arbitrary filters and get it to work like classic batch, you should first escape some characters in the filter:
$input -like ($filter.Replace('[', '[[]').Replace('#', '[#]'))
Based on my Super User answer.
$input -like ($filter.Replace('[', '[[]').Replace('#', '[#]'))
Based on my Super User answer.
Saturday, December 24, 2016
AbiathRPC - Little bugs
While combing through AbiathRPC, I found a couple small bugs which are now fixed.
First, authentication wasn't actually being checked in the WCF method that updates a batch of tiles. Fixed by adding the appropriate login-checking call.
The Abiathar client with the AbiathRPC state wrapper would crash when updating tiles when not connected to a server. This was caused by the replacement state wrapper trying to submit updates from a list that didn't exist to a server that didn't exist. Fixed by checking that there's actually an RPC connection and stopping with the vanilla behavior if there's not.
(Also, merry Christmas from Abiathar - from now until sometime tomorrow night, the Abiathar splash screen is Christmas-themed.)
First, authentication wasn't actually being checked in the WCF method that updates a batch of tiles. Fixed by adding the appropriate login-checking call.
The Abiathar client with the AbiathRPC state wrapper would crash when updating tiles when not connected to a server. This was caused by the replacement state wrapper trying to submit updates from a list that didn't exist to a server that didn't exist. Fixed by checking that there's actually an RPC connection and stopping with the vanilla behavior if there's not.
(Also, merry Christmas from Abiathar - from now until sometime tomorrow night, the Abiathar splash screen is Christmas-themed.)
Subscribe to:
Posts (Atom)