Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trigger corruption during upgrade #2306

Closed
wfaulk opened this issue Jan 5, 2017 · 8 comments
Closed

Trigger corruption during upgrade #2306

wfaulk opened this issue Jan 5, 2017 · 8 comments

Comments

@wfaulk
Copy link

wfaulk commented Jan 5, 2017

I had been running QS1.4.2. I had keyboard triggers set up to type certain text strings for me. They worked fine. After I upgraded to 1.5.1, the text string that they typed became corrupted. If the original string was abc123, then after the upgrade, it became QSID:QSPresetObjectHistory:abc123. I believe I saw this in a previous upgrade as well.

(Note that the "Type Text" action also fails to work in 1.5.1, but that's a distinct issue already reported in #2302.)

The triggers were set up like this:

  • Open QS Preferences
  • Open Triggers tab
  • Click "+", then Keyboard
  • . (Period to enter text entry mode)
  • abc123
  • Tab
  • Type Text
  • Ctrl-Return
  • Run after Delay
  • Tab
  • 0.2s
  • Return

I also assigned a keyboard shortcut to these triggers. The two that I had were assigned Ctrl-Opt-Cmd-R and Ctrl-Opt-Cmd-P.

@skurfer
Copy link
Member

skurfer commented Jan 10, 2017

I wasn’t able to reproduce this exactly, but I do see problems.

  1. Type Text with a trigger seems to be problematic in general. (The keystrokes are always sent before the modifiers can be released.) Maybe that’s why you had the delay, but…
  2. I can’t get a the trigger to do anything if I encapsulate a command and add a delay.

One thing that’s helpful is that a command encapsulated with ⌃Return is basically the same thing as a trigger, so I could compare a trigger that just did “Type Text” on something with one that encapsulated and delayed it. The former stores the desired string as text. The latter stores the ID you’re seeing with no data.

So plenty to look at, but for what it’s worth, I saw no difference in anything described above between 1.4.2 and 1.5.1.

@wfaulk
Copy link
Author

wfaulk commented Jan 13, 2017

  1. That is why I had the delay, and
  2. "Type Text" failing to do anything is a bug in 1.5.1, as reported in 'Type Text' action not working in 1.5.1 #2302, as I said

The issue I'm reporting is that when upgrading between versions, the saved triggers get corrupted.

@skurfer
Copy link
Member

skurfer commented Jan 17, 2017

I was on a newer build that no longer has the Type Text bug, and I also tried it under 1.4.2.

Could you please do this:

  1. Shut down Quicksilver
  2. Move your Triggers.plist to the Desktop
  3. Start Quicksilver 1.4.2
  4. Create the trigger and verify that it works
  5. Copy that Triggers.plist and name it something like before.plist
  6. Shut down 1.4.2 and start up 1.5.x
  7. If the Triggers.plist is any different, copy that and name it something like after.plist. If not, try opening the Triggers preferences, but don’t change anything. See if that causes Triggers.plist to get rewritten, then make a copy.
  8. Shut down Quicksilver and copy your original Triggers.plist back into place, then restart Quicksilver

Once that’s done, send me the “before” and “after” files. Thanks.

@wfaulk
Copy link
Author

wfaulk commented Mar 1, 2017

I just discovered that it's not actually the upgrade that's causing the problem. It's actually just restarting Quicksilver. I'm going to upgrade to the latest QS and see if the problem continues to occur. If so, I'll provide the Triggers.plist data you asked for.

@wfaulk
Copy link
Author

wfaulk commented Mar 1, 2017

I completely deleted all of the affected triggers after installing 1.5.2, restarted QS, added a new trigger, confirmed that it worked, restarted again, and confirmed that the problem still occurs. Other than the initial change to Triggers.plist that creates the trigger initially, nothing changes. It seems that creating the trigger loads it into memory properly, but reading the trigger from the config loads it improperly. In particular, the string to be typed (abcd in my test) is entered into the Triggers.plist file as <string>QSID:QSPresetObjectHistory:abcd</string>. After QS is restarted, it literally types out QSID:QSPresetObjectHistory:abcd when the trigger is activated. I tried editing Triggers.plist so that it just contains <string>abcd</string>, and that seems to work properly.

The Triggers.plist file, as automatically generated, is attached. (Renamed so that github will accept it.)

Triggers.afterConfig.plist.txt

@skurfer
Copy link
Member

skurfer commented Mar 2, 2017

I may have isolated the problem. Try this test build: https://cl.ly/1p1K3I2e1F3M

@wfaulk
Copy link
Author

wfaulk commented Mar 3, 2017

That fixes the problem for me.

@skurfer
Copy link
Member

skurfer commented Mar 3, 2017

Great. This will be included in a developer preview I hope to get out today or tomorrow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants