GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
We've been using hitch for a while now and recently we noticed that the email address displayed is garbled text.
Here's a sample .hitchrc file.
What version of Hitch are you on?
I left a comment on the gist. I have not seen this behavior before. Do you a way for me to reproduce this locally? Otherwise, replacing the group_email line with something like: :group_email: email@example.com should do the trick.
My first attempt was to delete .hitchrc and .hitch_pairs but got the same problem. Next, I followed your advice and it worked.
Although I could not reproduce the problem at this time, I'll let you know if this happens again.
Sounds good. I'll close this, but let me know if you run into more issues.
Ran into the same problem on a fresh machine with a new dev. Once we replaced the line in that file it worked. Could possibly be something in newer versions on initial file creation, haven't had time to investigate deeper though cc @jmkiss @benjaminoakes
I also got this just now. Fresh install of v1.0.1. It seems to get increasingly garbled, too. After a few test commits, hitch now gives me:
Henrik Nyh and Foo Bar <Vm0xd1IxbFhSWGRPVldoVlYwZG9WRmxVU205V1ZteHpXa2M1YWxadGVEQlpN
And my .hitchrc says:
:group_email: !ruby/string:HighLine::String |-
After fixing the email in my hitchrc, hitch gives the right output but after making a commit I still get a mess:
Author: Henrik Nyh and Foo Bar <Vm1wR1lXRXdOVWhVV0doVFlUSm9WVmxzWkc5alZteDBZM3BHVG1KSGVIaFZNV2hyWVRGWmQwMVVWbGRpClJrWXpWVVpGT1ZCUlBUMD0=+henrik+foo@Vm1wR1lXRXdOVWhVV0doVFlUSm9WVmxzWkc5alZteDBZM3BHVG1KSGVIaFZNV2hyWVRGWmQwMVVWbGRpClJrWXpWVVpGT1ZCUlBUMD0=>
Not sure if that's just garbled or some intentional escaping.
@henrik it seems their's something weird going on when HighLine first acquires the group_email string. A quick fix for your situation would be to manually set the group_email, like so: :group_email: firstname.lastname@example.org
Although, I would like to know how I can reproduce this elusive heisenbug!
Looks like there should be a conversion of the HighLine::String into a string before yaml. Haven't been able to identify where this happens in the code yet...
2.0.0p247 :001 > "adfa".to_yaml
NoMethodError: undefined method `to_yaml' for "adfa":String
from /Users/zach/.rvm/rubies/ruby-2.0.0-p247/bin/irb:16:in `<main>'
2.0.0p247 :002 > require 'yaml'
2.0.0p247 :003 > "adfa".to_yaml
=> "--- adfa\n...\n"
2.0.0p247 :004 > require 'highline'
2.0.0p247 :005 > HighLine::String.new("asdf")
2.0.0p247 :006 > HighLine::String.new("asdf").to_yaml
=> "--- !ruby/string:HighLine::String |-\n YXNkZg==\n"
2.0.0p247 :007 > HighLine::String.new("asdf").to_s
2.0.0p247 :008 > HighLine::String.new("asdf").to_s.to_yaml
=> "--- asdf\n...\n"
@ZachBeta this was fixed on 1.0.3 :-) Just now.
I think you mean 1.0.2, judging by the commit history. Thanks!
Good to hear, thanks for fixing!
@henrik ha! Yes, 1.0.2. :-)
@benjaminoakes yeah, it was a fix submitted by @iamvery