Does anyone remember when I said I wished developers couldn't use Copy-Paste?



  • Every month or so, something on our Macs will just quit working for no discernible reason whatsoever and with no way to fix it. Well we were overdue so it finally happened again this morning.

    To recap, here's some of the stuff I've encountered this past year. Keep in mind some of this was stable for months and then just quit. Nothing had changed.

    1. Domain login:  We had our Macs integrated with our Windows domain. This made login easy and accessing resources on Windows servers easier. One morning it just no longer worked and we had to switch to using local accounts. After hours of web trawling to find a fix, I was forced to conclude that we were on magic mushrooms or bath salts and only hallucinated that it worked, because evidently Active Directory login on a Mac has never worked for anyone, ever.
    2. Machine names: Okay, when I said "Macs" above I lied. We actually only have one Mac. It runs VMWare with several OS X guests, and we each have our own VM and we just VNC in from our Windows workstations. This was because having more than one Mac for our team when we're developing an iPad app (which requires Xcode which ONLY runs on a Mac) is evidentally an unreasonable request. Anyway, for months we were able to just enter our VM's machine name (i.e. Mott-iMac) into our VNC app to connect. One day that no longer worked, and we now have to enter in the VM's IP address to connect. They're assigned by DHCP, so every week or so we have to physically go to the Mac, connect directly to each VM, and look up its IP address. Perhaps TRWTF here is I'm too lazy to assign static IPs to the VMs, since they only change every week or two.
    3. Instruments: Instruments is the profiling app included with Xcode. If you want to track memory usage, look for leaks, or time methods, you use Instruments. The only problem is at some point it quit working for all but one of the OS X installs. It's so bad that if I try to run Instruments in MY virtual machine, it causes ALL virtual machines on the system to kernel panic (Mac version of a BSOD, which actually happens at least 20 times as often as a Windows 7 BSOD and please smack anyone who tells you Macs are more stable than PCs).

    And today's feature that has nonsensically broken and will probably be gone for the rest of my life is, of all things, (imaginary drum roll here since Community Server isn't WTF enough for me to attach a sound effect to this post): PASTING FROM THE CLIPBOARD (or whatever the clipboard is called on OS X). That's right. That nifty feature abused by developers worldwide, usually triggered by Ctrl-V, Cmd-V, or WindowsKey-V depending on platform and keyboard, is now GONE from my machine.

    This must be my punishment for once stating somewhere in these forums that I wish developers did not have access to copy-paste. I can't wait to see what feature I lose next.



  • @mott555 said:

    That's right. That nifty feature abused by developers worldwide, usually triggered by Ctrl-V, Cmd-V, or WindowsKey-V depending on platform and keyboard
     

    CTRL+SHIFT+Insert is the only true way.

    CTRL+Y is attured, as a small sin. Assigning the Windows key to an application shortcut is a fatal sin.



  • Maybe it's not a problem with MacOS but with the VNC connection configuration? Don't get me wrong, I'm not defending it, just that maybe your latest problem has an easy solution. I work with a Mac over VNC and I haven't been able to get around fixing the keyboard mappings to work fine.



  • Copy-Paste using the mouse doesn't really work anymore either. And when it does, it doesn't necessarily paste in the last text I copied, it always seems to be the copied text from before the last copy.

    I agree using the Windows key is insane, but over the VNC connection the Windows key is mapped to the Command key. There isn't much I can do about it. Modifying any of my VNC client's options makes the Mac refuse the connection.



  • @Mcoder said:

     Assigning the Windows key to an application shortcut is a fatal sin.

     

    In Linux it's quite common. X considers it to be a modifier key, so it has no inherent function on its own (although some distributions, such as Ubuntu, give it one by default).

     



  • @mott555 said:

    ... They're assigned by DHCP, so every week or so we have to physically go to the Mac, connect directly to each VM, and look up its IP address...
    That's bizarre.  DHCP clients generally request the same IP they perviously had, so they only change IPs when the one they prefer has been taken by another.  Also, when a client shuts down, at least half of its lease time is still remaining.  So, if you have a lease time of eight days, then a computer would have to be turned off for at least four days, and then another client would have to lease that same IP (it would have to be something that didn't previously have a lease because those would request their old IP).

    Also, any halfway decent DHCP server should be able to create a DNS entry on behalf of the client, so the whole "can't use the name" issue would never happen, regardless of client OS.



  • @Mcoder said:

    Assigning the Windows key to an application shortcut is a fatal sin.
    Not when it's Copy+Paste. These shortcuts should work exactly the same in any application, so you might as well consider them to be system-level shortcuts.

    Besides, this happens only because PCs don't have a Command key. Since macs don't need a Windows key, they'll use the Win keys of a PC keyboard as Cmd; which is a good thing.

    Now, if only there were Home and End keys on macs...



  • @ubersoldat said:

    Maybe it's not a problem with MacOS but with the VNC connection configuration? Don't get me wrong, I'm not defending it, just that maybe your latest problem has an easy solution. I work with a Mac over VNC and I haven't been able to get around fixing the keyboard mappings to work fine.
     

    It's weird that you already say that you're not defending it. Did you expect an unreasonable ad-hominem attack? Not unlikely.

    Anyway, I'd say the origin of your problems is most likely your use of VMWare. I've noticed a few odd things back when I was using it. It's a pretty tricky piece of software to get right. If it isn't the problem, then you should be able to restore your orginal image, and your problems should be solved.

    And why do you use a mac to run VMWare in the first place? Just for "legal" reasons?



  • @TGV said:

    And why do you use a mac to run VMWare in the first place? Just for "legal" reasons?

    OS X only runs on a Mac. Running multiple copies on a Mac through VMWare not only works but is legal too. Getting OS X to install on non-Mac hardware is extremely tricky, prone to breaking on updates, and will incur the wrath of Apple if discovered.

    Running a Hackintosh as a hobbyist for home use is one thing. But as workstations in a for-profit corporation? Bad idea.



  • IIRC Apple's EULA states that you can only install the OS on "Apple-branded hardware", which means at the very least you should put a sticker with the Apple logo on your computer case.



  •   Ahh, that's what those apple logo stickers are for that they send with every Apple purchase!  I have always wondered!  That's brilliant, but I wonder if Apple legal is aware of that little "loophole" provided by marketing?



  • Why don't you spell it properly, like a true Klingon would? Or are you a Ferengi?

     And why does the reply button redirect to the front page?



  • Doesn't proper dhcp clients release their lease when they shut down?


  • BINNED

    @jetcitywoman said:

      Ahh, that's what those apple logo stickers are for that they send
    with every Apple purchase!  I have always wondered!  That's brilliant,
    but I wonder if Apple legal is aware of that little "loophole" provided by marketing?

    That's clearly a better use for them than providing cheap advertising for Apple by putting them on your vehicle.



  • I was going to suggest the right-click menu, but then I realized you were using a Mac...

    ...oh, wait, Macs have right mouse buttons now, that won't work! Stupid Apple killing all the good jokes!

    I wonder if Macs actually have "paste" on the right-click menu anyway?



  • They do. They don't have "cut" though.

    Edit: oh, looks like Lion introduced "Copy+Move". Yay.



  • It has since OS8. What decade are you from?



  • @mott555 said:

    please smack anyone who tells you Macs are more stable than PCs
    People like to bash microsoft, marketing majors will tell you microsofts success is due to "being first to market, even if its shitty." I don't think this is true, i think that idea is more a case of seeing the world with marketing colored glasses, i.e. it is an illusion perpetrated by the the delusion that the only thing that matters is marketing, a common delusion among marketing majors/drones. The real secret to microsofts success is that their real customer is developers, and despite microsofts sterotypical image, they have always caterd to developers, i.e. windows is very developer friendly.



  • @Zecc said:

    Now, if only there were Home and End keys on macs...
     

    Control-A and Control-E respectively.

    @Zecc said:

    Besides, this happens only because PCs don't have a Command key. Since macs don't need a Windows key, they'll use the Win keys of a PC keyboard as Cmd; which is a good thing.

    I use SynergyKM to connect from my work Mac to Windows PC (three screens on my desk: two are Mac and one Windows). I mapped the Cmd->Ctrl, Alt->Alt, Control->Win. It's in a different order but at least muscle memory for Cmd/Ctrl shortcuts are consistent.

    I don't consider myself anti or pro Mac/Apple, and my previous "M$" rage has subsided since XP SP2. (I still use an ancient Nokia, for example. My MP3 player is a "Laser" brand. I was given an iPad, but I wouldn't have bought one. If I was given a Windows phone/Surface/Zune/whatever I'd accept it but wouldn't buy it). I like to keep my computing in a wide range: I'm currently typing this on an Ubuntu netbook!



  • @henke37 said:

    Doesn't proper dhcp clients release their lease when they shut down?
    MAC OS stopped doing that a long time ago. Releasing on shut down defeats one of the primary benefits of the lease - the ability for the network to function (at least for a while) when the DHCP server is unavailable. If all clients released their leases on shutdown, then a DHCP server failure would cause every computer to stop working on its next reboot.



  • @esoterik said:

    i.e. windows is very developer friendly.
     

    That's the reason they deployed MS Foudation Classes? Or that they created COM?

     

     



  • @Jaime said:

    @henke37 said:
    Doesn't proper dhcp clients release their lease when they shut down?
    MAC OS stopped doing that a long time ago. Releasing on shut down defeats one of the primary benefits of the lease - the ability for the network to function (at least for a while) when the DHCP server is unavailable. If all clients released their leases on shutdown, then a DHCP server failure would cause every computer to stop working on its next reboot.
    Better not let morbs hear you say that; he'll rip you a new one for even suggesting the possibility that DHCP might not be available -- as he did me just before he disappeared.

    DHCP loans out IP addresses on a temporary basis.  So long as you're using it, it's fine to claim ownership.  But it's bad form to not release it when you're done with it.

    I opine that it's a violation of RFC 2131 to not release it if the system was in a state that it was capable of doing so.  Section 4.4.6 states:

    4.4.6 DHCPRELEASE
    

    If the client no longer requires use of its assigned network address
    (e.g., the client is gracefully shut down), the client sends a
    DHCPRELEASE message to the server. Note that the correct operation
    of DHCP does not depend on the transmission of DHCPRELEASE messages.

    While there is no language of "MUST" or "SHOULD" or "MAY", the text is clear:  "the client sends a DHCPRELEASE message to the server."  It doesn't say "the client considers sending a DHCPRELEASE."  It even gives a specific example where "the client is gracefully shut down."

    And yes, it also says that correct operation does not depend on the transmission.  That's because there may be times when sending such a message is impossible (the client crashed; the wireless card was shut down; the network cable was disconnected).  In that case, the lease just expires on its own and returns to the pool.  We lease for two days; other places lease for different amounts of time.  If you're a site that leases for a week, guaranteed the address is unavailable for a minimum of 3.5 days.  If you've got other machines coming and going, you can run out of available IP addresses due to this incorrect behavior.

    I was unaware of this.  Since our leases are two days, our addresses recycle back into the pool sooner.  But I'm going to bring this to the rest of our team and confirm how our Mac OS standard build is configured.



  • @Zemm said:

    Control-A and Control-E respectively.
    Yes, I know. I just wish they were single dedicated keys.

    I admit that my experience with macs is limited, so my preconception that there are many applications that don't respect these key combinations is just that, a preconception. Ican't think of an example off the top of my head, but I think I've been frustated by this before.

    Oh, and Cmd+Horizontal arrows works too. I just haven't created the habit yet. So yeah, I guess I'm the weakest link.



  • Command plus arrows gets you to the beginnings and ends of lines and whole texts. TBH I find the OS X navigation shortcuts to be easier to use, because they don't require you to move your hand from one block of keys (the arrows) to another (Home/End/etc.), which usually (for someone like me anyway) means glancing down to make sure your hand is on the right key. Just move your left thumb between ⌥ and ⌘ as needed and you can access all the navigation functions. (For completeness, the "Page Up" etc. keys operate scrolling, not the position of the text cursor.)



  • @Mcoder said:

    @esoterik said:

    i.e. windows is very developer friendly.
     

    That's the reason they deployed MS Foudation Classes? Or that they created COM?

     

     

    If Apple even deigned to release some sort of "Apple Foundation Classes", they would attach a 300 page EULA to them and sue anyone who used them to make applications without first getting the approval of at least three C-level executives at Apple...

    Well, OK, I'm exaggerating just a bit... :P



  • @ekolis said:

    If Apple even deigned to release some sort of "Apple Foundation Classes", they would attach a 300 page EULA to them and sue anyone who used them to make applications without first getting the approval of at least three C-level executives at Apple...

    Well, OK, I'm exaggerating just a bit... :P

    Yeah, but the EULA would look GREAT!

    (Point taken, you are right.)

     



  • @ekolis said:

    @Mcoder said:

    @esoterik said:

    i.e. windows is very developer friendly.
     

    That's the reason they deployed MS Foudation Classes? Or that they created COM?

     

     

    If Apple even deigned to release some sort of "Apple Foundation Classes", they would attach a 300 page EULA to them and sue anyone who used them to make applications without first getting the approval of at least three C-level executives at Apple...

    Well, OK, I'm exaggerating just a bit... :P

     

     

    Anybody who's developed on both platforms know that Microsoft are miles ahead of Apple in regards to developers. Visual Studio vs Xcode, anyone? I like macs and I'm typing this on one right now, but Apple's developer tools are surprisingly horrible. I seriously don't know what I'd do without MonoDevelop.

     



  • Wait, so a process in the guest can affect other guests? And you think this is somehow a problem with the Mac (guest) and not a problem with the hypervisor? Interesting...



  • We had our Macs integrated with our Windows domain. This made login easy and accessing resources on Windows servers easier. One morning it just no longer worked and we had to switch to using local accounts. After hours of web trawling to find a fix, I was forced to conclude that we were on magic mushrooms or bath salts and only hallucinated that it worked, because evidently Active Directory login on a Mac has never worked for anyone, ever.

    Usually when I've run into that problem it's because the system time has gone too far out of sync with the AD server. Since you're running them all as VM guests it's quite possible that they're not syncing with the host time and getting screwed up or if they are syncing then the host's time is off and screwing up all the guests.

    Anyway, for months we were able to just enter our VM's machine name (i.e. Mott-iMac) into our VNC app to connect. One day that no longer worked, and we now have to enter in the VM's IP address to connect. They're assigned by DHCP, so every week or so we have to physically go to the Mac, connect directly to each VM, and look up its IP address. Perhaps TRWTF here is I'm too lazy to assign static IPs to the VMs, since they only change every week or two.

    There's also the option of setting DHCP reservations so you can be half-lazy ...



  • @Mcoder said:

    @esoterik said:

    i.e. windows is very developer friendly.
     

    That's the reason they deployed MS Foudation Classes? Or that they created COM?

     

    You need to consider the historical state of sotfware engineering when the technology was released, i.e. coding for 16-bit windows today would be a pain, but when 16-bit windows was new, it was a huge leap over 16-bit DOS programming and was probably a pleasant experience in the historical context. MFC was a huge leap forward at the time it was released, I remember subclassing MFC classes to rapidly create new UI widgets that just worked. MFC was great when it was current, and i think its refusual to die is proof.

    COM is easy to consume but it is, however, much harder to produce. They cant all be winners, but even the losers had some merit.

    Even today, the technical advances in windows 8, i.e. API projections etc., excite me while the consumer/marketing image of windows 8 makes me go "meh."



  • @error_NoError said:

    Usually when I've run into that problem it's because the system time has gone too far out of sync with the AD server. Since you're running them all as VM guests it's quite possible that they're not syncing with the host time and getting screwed up or if they are syncing then the host's time is off and screwing up all the guests.

    I might have to investigate that further. Our primary domain controller functions as the time server for our network, but it doesn't update itself from the Internet and the Mac doesn't update from it. Our domain controller is known to lose several minutes a month.

    Weird. My phone and watch say its 7:14 AM but my OS X VM says 1:04 AM. So I clicked on the time to update it and possibly correct the time zone, but when the dialog came up it had the correct date, timezone, and time.



  • Have you tried rebooting windows to fix your clipboard? Clipboard deadlock is the bane of anyone who uses windows and:

    • uses virtual PC or VMWare or anything
    • uses a windows X server
    • uses RDP or other remote desktop stuff (such as VNC)

    I do all of these things and the windows clipboard deadlocks roughly once a week forcing a reboot.

    Anyway, my guess is that it is your setup, not OSX that is the problem here.



  • @mott555 said:

    Keep in mind some of this was stable for months and then just quit. Nothing had changed.
     

    Incorrect.

    It is statistically proven to a degree of 100% certainity that within the specified timeframe there were at least 20 to 60 silent mandatory updates of iTunes (anywhere from 20 to 200 Mb each) with 20 to 60% of them probably affecting Finder, 268 non-silent updates of Adobe Acrobat that were so obtuse that they were completely erased from any Mac user's memory, 5 updates of Safari regardless of whether it was ever run on said computers, and about 5 to 10 updates of iLife regardless of whether it's even installed on said computers.

    @mott555 said:

    (which requires Xcode which ONLY runs on a Mac)

    I have no imaginary data on Xcode update rate, but we all know that it contains offline self-updating mechanism with random number generator that upon every operation decides which part of itself will it horribly break forever. There might have been int overflow in the RNG which caused it to think it might be a good time to perform this update on core system files.

    @mott555 said:

    Perhaps TRWTF here is I'm too lazy to assign static IPs to the VMs, since they only change every week or two.

    Correct.

    @mott555 said:

    (Mac version of a BSOD, which actually happens at least 20 times as often as a Windows 7 BSOD and please smack anyone who tells you Macs are more stable than PCs).

    Doing that religiously since Apple switched to intel processors, every time I find a discussion along the lines "help me decide whether to buy a mac or a pc". None of the BFUs posting to those discussions believes me.

    @mott555 said:

    I can't wait to see what feature I lose next.

    All my bets are on the "Shut down" item in the Finder menu. After that, the actual hardware on/off button.



  • @esoterik said:

    COM is easy to consume but it is, however, much harder to produce. They cant all be winners, but even the losers had some merit.

    It has always been easy to create COM servers. When Microsoft Transaction Server came along it even became easy to create COM servers that could be consumed over the network. If you wanted to be lazy, you could whip up a server in five minutes in VB5 or VB6. You can still do it with almost no effort in any .Net language.



  • @SEMI-HYBRID code said:

    @mott555 said:

    I can't wait to see what feature I lose next.

    All my bets are on the "Shut down" item in the Finder menu. After that, the actual hardware on/off button.

     

    "Has anyone seen the host machine? It was right here on my desk."

     


Log in to reply