The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,497 other followers

The biggest lie I tell myself is not about new years resolutions.

Posted by jpluimers on 2019/01/01

The biggest lie I tell myself is “I don’t need to write that down, I’ll remember it”

It’s likely older, but the oldest reference I could find was 2012 [WayBack].

So before I forget:

Happy New Year everyone!

With the above quote, it is no coincidence I started my blog even earlier (in 2009): it’s my off-line memory, way better readable than my hand-writing and indexed by various search engines.

Read the rest of this entry »

Posted in About, LifeHacker, Personal, Power User | Leave a Comment »

If you are looking for good Travis engineers, look at the #TravisAlums hashtag on Twitter

Posted by jpluimers on 2019/02/23

Idera is laying of a lot of really good Travis engineers.

If you want to hire them, then follow the [Archive.is] #TravisAlums hashtag on Twitter

Via: [WayBackJosé León Serna on Twitter: “Idera acquired Embarcadero Technologies in 2016 and fired almost all its R&D (150+ people in Spain, Russia, US, etc) so not sure why #TravisAlums are surprised, that’s what they do, that’s their business model.”

–jeroen

Posted in Continuous Integration, Development, Software Development, TravisCI | Leave a Comment »

Ubiquity UniFi SDN – Server status “UniFi Controller is starting up… Please wait a moment”

Posted by jpluimers on 2019/02/22

When your UniFi Cloud Key web interface shows this [Archive.is] after upgrading:

 

UniFi Controller is starting up…

Please wait a moment

 

Then you just ran into a bug which seems to occur most with 5.9.29 of the UniFi software: [Archive.is] “UniFi Controller is starting up…” “Please wait a moment” “5.9.29” – Google Search

The easiest way is to restore from a backup: this usually works.

For that you need ssh access, which usually is with the ubnt user. But you could have made life more complicated when you followed these:

Steps from [WayBack] UniFi Controller is starting up… Please Wait A Moment – Ubiquiti Networks Community (thanks [Archive.is] About mrfoxdk – Ubiquiti Networks Community!):

  1. SSH to the Unifi CloudKey
  2. dpkg -P unifi
  3. Open a browser and browse the URL of CloudKey
  4. Login
  5. Press “Install” under UniFi
  6. Wait for the process to complete, and then wait a bit for the service to be brought online.
  7. Recover the configuration backup from the latest backup

Removing and reinstalling the UniFi software, then restore from backup

Step 2 above will purge the unifi software of the cloud key as per dpkg --help:

Read the rest of this entry »

Posted in *nix, Power User, Ubiquiti, WiFi | Leave a Comment »

Many Mac OS X / MacOX / whatever versions: Unable to modify the volume with the keyboard – Ask Different

Posted by jpluimers on 2019/02/22

This has happened to me on most Macs with most Apple Mac OS X / MacOS / whatever versions: the built in sound controls for internal speakers and head phones fail to work (keyboard shortcuts and UI both fail).

The solution at [WayBackmavericks – Unable to modify the volume with the keyboard – Ask Different works, but be sure to require the kernel module steps:

open up a Terminal window and run:

sudo killall coreaudiod
sudo kextunload /System/Library/Extensions/AppleHDA.kext 
sudo kextload /System/Library/Extensions/AppleHDA.kext

–jeroen

Posted in Apple, Mac, Mac OS X / OS X / MacOS, MacBook, MacBook Retina, MacBook-Air, MacMini, macOS 10.12 Sierra, OS X 10.10 Yosemite, OS X 10.11 El Capitan, OS X 10.9 Mavericks, Power User | Leave a Comment »

When Windows 10 doesn’t recognise your DVD device any more

Posted by jpluimers on 2019/02/22

Yes, some people still use DVD devices. My mentally retarded brother does every now and then, so it was a big problem that one day he could not put play a photo DVD any more.

This happened:

The selected device was gone. Reboots (including cold ones) didn’t help.

What helped was selecting the “Dual Channel PCI IDE Controller”, remove it, then reboot so Windows would try to re-install the drivers. After that the DVD drive appeared again.

Later I found these two links with similar solutions:

–jeroen

 

Posted in Power User, Windows, Windows 10 | Leave a Comment »

Application shutdown: wait for all threads to terminate or not?

Posted by jpluimers on 2019/02/21

A while ago, I ran into a problem that an anonymous thread would run longer than the main thread of the application.

This caused all sorts of trouble, so in this case I decided to fix it for that particular thread.

There are various opinions if this should be done for all threads or not. Like always, it depends, so it is good to mention a few:

This particular case resulted into the memory manager shutting down earlier than the anonymous thread, but the anonymous thread was still using memory allocation functions, resulting into a few things of which you do not want the first and second to happen on a continuous integration system:

  1. Error messages during shutdown, which is unwanted on a headless system:
    ---------------------------
    MyIntegrationTests.exe: MM Operation after uninstall.
    ---------------------------
    FastMM has detected a GetMem call after FastMM was uninstalled.
    ---------------------------
    OK 
    ---------------------------

    or

    ---------------------------
    MyIntegrationTests.exe: MM Operation after uninstall.
    ---------------------------
    FastMM has detected a FreeMem call after FastMM was uninstalled.
    ---------------------------
    OK 
    ---------------------------

    either of them followed by

    ---------------------------
    Error
    ---------------------------
    Runtime error 203 at 00408EFF
    ---------------------------
    OK 
    ---------------------------

    or

    ---------------------------
    Error
    ---------------------------
    Runtime error 204 at 0040AFE9
    ---------------------------
    OK 
    ---------------------------

    The errors are mappings of:

    203, { reOutOfMemory }
    204, { reInvalidPtr }
  2. The MyIntegrationTests_MemoryManager_EventLog.txt to rapidly grow to 100s of megabytes.
  3. The MyIntegrationTests_MemoryManager_EventLog.txt not to be truncated.

This particular case was easy to fix by adding a global (but implementation section contained) boolean indicating if the thread was already finished:

unit DebugInformationLoaderUnit;

interface

implementation

uses
  JclDebug;

var
  LoadDebugInformationAsyncFinished: Boolean = False;

procedure LoadDebugInformationAsync;
begin
  TThread.CreateAnonymousThread(
    procedure
    begin
      TThread.NameThreadForDebugging('LoadDebugInforoamtionAsync');
      DebugInfoAvailable(MainInstance);
      LoadDebugInformationAsyncFinished := True;
    end).Start;
end;

initialization
  LoadDebugInformationAsync;

finalization
  while not LoadDebugInformationAsyncFinished do
  begin
    Sleep(1);
  end;
end.

In addition, I did this to suppress message boxes outside Delphi:

program MyIntegrationTests;

...

{$Include FastMM4Options.inc}

uses
  FastMM4 in '..\..\..\Shared\FastMM4.pas',
  System.Classes,
...;

{$R *.RES}

begin
  TThread.NameThreadForDebugging(ParamStr(0));

  SuppressMessageBoxes := SuppressMessageBoxes // follow pattern in FastMM4.FinalizeMemoryManager
    {$ifdef RequireIDEPresenceForLeakReporting}
        and DelphiIsRunning
    {$endif}
    {$ifdef RequireDebuggerPresenceForLeakReporting}
        and ((DebugHook <> 0)
        {$ifdef PatchBCBTerminate}
        or (Assigned(pCppDebugHook) and (pCppDebugHook^ <> 0))
        {$endif PatchBCBTerminate}
        )
    {$endif}
    ;
  {$WARN SYMBOL_PLATFORM OFF} NoErrMsg := {$WARN SYMBOL_PLATFORM ON} SuppressMessageBoxes; // Set RTL message boxes as well;

  ...
end.

–jeroen

Posted in Conference Topics, Conferences, Delphi, Development, Event, Software Development | Leave a Comment »

 
%d bloggers like this: