|
There's a bunch of articles on state machines already here on CP.
Games, like Hunt the Wumpus - Wikipedia[^] are perfect examples for using a state machine.
BTW, I actually knew Gregory Yob, he was very much a mentor to me in my early 20's.
|
|
|
|
|
A bank account is an excellent example of a state machine, since it can be viewed
on different levels.
For the bank your account is on one of two states: you have either money or a dept.
For yourself you might add states like
a. positive saldo
b. overdraft (i.e. nearing the end of the month)
c. too much for a regular bank account: need to transfer to a saving account
So, dependent on the view you take you can identify a few states your account is in
|
|
|
|
|
I was under the impression that Microsoft had listened to the pitchfork wielding masses and stopped the practice of rebooting your machine without warning. I honestly had.
I was in the middle of debugging some really messy TypeScript. Lots of windows open, Visual Studio debugging Chrome, Chrome debug tools, breakpoints everywhere, nothing really working properly in the debugger because I'm using vue and webpack and the .map files don't work, but it was all there. I had found the spot it was broken and was stepping through carefully.
I left the computer to take a break. An hour no more. There had been a notification about a Windows update and I'd lazily hit the "bother me later" button.
And so I come back an hour later to a freshly rebooted computer.
Are you effing kidding me?? I cannot even vaguely understand the mentality of this. Maybe if the machine was idle for 10 hrs. Maybe if I'd been warned 3 times with ever increasing levels of direness. Maybe if there was truly a security issue that was going to threaten my cat or something.
But to just reboot and lose an hour of sleuthing and setup?
cheers
Chris Maunder
|
|
|
|
|
In MS's defense, they do say that they'll check to see if you're using the machine before rebooting it.
Did you set your Active Hours?
The difficult we do right away...
...the impossible takes slightly longer.
|
|
|
|
|
Richard Andrew x64 wrote: Did you set your Active Hours?
I shouldn't need to, it's irrelevant, I don't ever want to them to do a reboot which wasn't triggered by a user action.
|
|
|
|
|
Theory aside, I was offering a practical solution to the problem. The fact is that it will never be the way you want it, so here's something you can do to cope.
The difficult we do right away...
...the impossible takes slightly longer.
|
|
|
|
|
Richard Andrew x64 wrote: Did you set your Active Hours?
|
|
|
|
|
What's that supposed to mean?
The difficult we do right away...
...the impossible takes slightly longer.
|
|
|
|
|
That it would have been my reaction had I been the OP.
|
|
|
|
|
|
Gary R. Wheeler wrote: They limit it to a 12 hour period
18 hours now.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Still ing useless since it assumes that either:
1) You're some sort of weirdo who completely wraps up everything you were doing on your computer leaving zero lose ends before going away but is too lazy to turn it off.
2) Every piece of software you're using supports background auto-save of data and state to recover after a reboot.
I'm not sure which of those is most preposterous.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, weighing all things in the balance of reason?
Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful?
--Zachris Topelius
Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies.
-- Sarah Hoyt
|
|
|
|
|
Dan Neely wrote: You're some sort of weirdo who completely wraps up everything you were doing on your computer leaving zero lose ends That's me. When I'm done for the day, nothing's running except the normal background stuff. Some of this is so that I don't have to worry about my automated nightly backup having to deal with access conflicts. The other part of it is from bitter lessons learned from applications and/or their data being corrupted from an unwanted restart.
Software Zen: delete this;
|
|
|
|
|
I wish I could afford to be that tidy and close things off at the end of a day.
I can be working on many different things on any given day (and typically have to task-switch multiple times in a single day), so I would leave projects opened for weeks if I could. But reality settles in and always finds a way to prevent me from doing that.
It would only get worse if I actually started using the "multiple desktops" feature that Windows 10 finally got a few versions back. My desktop is typically a mess of windows piled high on top of each other. What helps in my case is that I run many VMs, each of which being dedicated to very specific subsets of tasks (meaning, I have a VM doing nothing but being a DC, a WSUS VM, a SQL VM, a development VM, etc...I'm done assigning completely different roles to the same OS instance). And that's me just being a home user.
|
|
|
|
|
It's become a necessity at work, given that our draconian IT department updates and restarts everyone's PC's without any consultation.
Fortunately I don't do web or data base development, so I don't need to have a lot of stuff running in the background in order to debug what I'm focused on.
The other part of this is rueful acknowledgement that, if I left a bunch of stuff running the night before, I wouldn't remember exactly what I was doing in each thing when I came in the next day .
Software Zen: delete this;
|
|
|
|
|
Gary R. Wheeler wrote: The other part of this is rueful acknowledgement that, if I left a bunch of stuff running the night before, I wouldn't remember exactly what I was doing in each thing when I came in the next day
At least it's still there and waiting for you.
A lot of times, if my system rebooted, I wouldn't even remember what still needed to be looked at.
|
|
|
|
|
|
are you elephanting kidding me? MS Defense? This policy is asinine from the beginning. Let me come over to your place and pull the power plug on your machine when you step away. Jesus protect us.
Charlie Gilley
<italic>Stuck in a dysfunctional matrix from which I must escape...
"Where liberty dwells, there is my country." B. Franklin, 1783
“They who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.” BF, 1759
|
|
|
|
|
My issue isn't just how much time has been lost, but that which is yet to be lost -- because Windows tries to open a few of the things I had open, but doesn't, and can't do so in the correct order, so I need to close them all and reboot again to start fresh.
How can I get it to at least not try to reopen what it shut down?
|
|
|
|
|
Settings ⇒ Accounts ⇒ Sign-in options
Make sure "Use my sign-in info to automatically finish setting up my device and reopen my apps after an update or restart" is off.
This really should have been two options: when it restarts after a major update, I do want it to finish the annoying "Please wait, we're getting things ready..." sequence as soon as possible, without waiting for me to sign in. But I don't want it to try to reopen any apps, or to run any startup apps. Just finish the setup and leave the computer logged out.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Yeah, blocked by my employer.
|
|
|
|
|
Dunno what you mean. My Dell computer never does an update unless I type
sudo apt-get update
sudo apt-get upgrade
Oh wait...
I'm retired. There's a nap for that...
- Harvey
|
|
|
|
|
These kinds of arcane invocations is why I'll probably never bother trying it out.
|
|
|
|
|
Still, there's something to be said for it, once you get used to it. It quickly becomes second nature.
That being said, I've also seen plenty of updates gone horribly, horribly wrong, on clean, hardly used Linux VMs, that should still be in such a pristine state that failures couldn't be blamed on having some uncommon, untested configuration.
|
|
|
|
|
Amen, but the sudo guy was being a smartass I haven't done Unix in a long time, but once you dive into the pool, water is fine. Avoid rm -f . though.
Charlie Gilley
<italic>Stuck in a dysfunctional matrix from which I must escape...
"Where liberty dwells, there is my country." B. Franklin, 1783
“They who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.” BF, 1759
|
|
|
|