Garbled email address #16

Closed
ngpestelos opened this Issue Jun 19, 2013 · 15 comments

Comments

Projects
None yet
5 participants

Hi,

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.

Owner

therubymug commented Jun 20, 2013

What version of Hitch are you on?

v1.0.1

Owner

therubymug commented Jun 21, 2013

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: dev@yourdevteamemail.org 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.

Thank you!

Owner

therubymug commented Jun 21, 2013

Sounds good. I'll close this, but let me know if you run into more issues.

@therubymug therubymug closed this Jun 21, 2013

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

henrik commented Oct 1, 2013

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
M0JIVkcxS1NHVklhRlpOClYyaHlXVlJHV21Rd01WVldiR1JwQ2xKcldYcFdW
VnBHVDFaQ1VsQlVNRDA9+henrik+foo@Vm0xd1IxbFhSWGRPVldoVlYwZG9WRmxVU205V1ZteHpXa2M1YWxadGVEQlpN
M0JIVkcxS1NHVklhRlpOClYyaHlXVlJHV21Rd01WVldiR1JwQ2xKcldYcFdW
VnBHVDFaQ1VsQlVNRDA9>

henrik commented Oct 1, 2013

And my .hitchrc says:

:group_email: !ruby/string:HighLine::String |-
  Vm0xd1IxbFhSWGRPVldoVlYwZG9WRmxVU205V1ZteHpXa2M1YWxadGVEQlpN
  M0JIVkcxS1NHVklhRlpOClYyaHlXVlJHV21Rd01WVldiR1JwQ2xKcldYcFdW
  VnBHVDFaQ1VsQlVNRDA9

henrik commented Oct 1, 2013

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.

Owner

therubymug commented Oct 2, 2013

@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: dev@yourdevteamemail.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 (irb):1
    from /Users/zach/.rvm/rubies/ruby-2.0.0-p247/bin/irb:16:in `<main>'
2.0.0p247 :002 > require 'yaml'
 => true
2.0.0p247 :003 > "adfa".to_yaml
 => "--- adfa\n...\n"
2.0.0p247 :004 > require 'highline'
 => true
2.0.0p247 :005 > HighLine::String.new("asdf")
 => "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
 => "asdf"
2.0.0p247 :008 > HighLine::String.new("asdf").to_s.to_yaml
 => "--- asdf\n...\n"
Owner

therubymug commented Nov 19, 2013

@ZachBeta this was fixed on 1.0.3 :-) Just now.

henrik commented Nov 19, 2013

I think you mean 1.0.2, judging by the commit history. Thanks!

Contributor

benjaminoakes commented Nov 19, 2013

Good to hear, thanks for fixing!

Owner

therubymug commented Nov 19, 2013

@henrik ha! Yes, 1.0.2. :-)

@benjaminoakes yeah, it was a fix submitted by @iamvery

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment