GithubHelp home page GithubHelp logo

liangzan / contacts Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bimbiero/contacts

23.0 23.0 25.0 340 KB

A universal interface to import email contacts from various providers including Yahoo, Gmail, Hotmail, AOL, Plaxo, GMX.net, Web.de, inbox.it, sezname.cz.

License: BSD 3-Clause "New" or "Revised" License

Ruby 100.00%

contacts's People

Contributors

adamhunter avatar balepc avatar eofferma avatar eshear avatar gf3 avatar glennfu avatar ilyakatz avatar joeyaghion avatar laurynas avatar lazyatom avatar liangzan avatar onomojo avatar tonytargonski avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

contacts's Issues

error with json versions

[contacts]$ bundle
Fetching gem metadata from https://rubygems.org/........
Bundler could not find compatible versions for gem "json":
In Gemfile:
liangzan-contacts (> 1.2.8) ruby depends on
json (
> 1.6.5) ruby

rails (= 3.2.3) ruby depends on
  json (1.7.3)

Hotmail not working anymore

Didn't change anything to my server or code but since 5 days I'm getting this error (only with hotmail.)
Tried to update the gem to 1.2.26 : it didn't change anything.

"undefined method `[]' for nil:NilClass" when calling

@contacts = (site.new('login', 'password').contacts) || []

it seems the problem come from here (don't know exactly which line since my debugguer is giving me some problems :s ):

in hotmail.rb

def real_connect
   (...)
 data, resp, cookies, forward = get(URL)
  old_url = URL
  until forward.nil?
    data, resp, cookies, forward, old_url = get(forward, cookies, old_url) + [forward]
  end

  postdata =  "PPSX=%s&PwdPad=%s&login=%s&passwd=%s&LoginOptions=2&PPFT=%s" % [
    CGI.escape(data.split("><").grep(/PPSX/).first[/=\S+$/][2..-3]),
    PWDPAD[0...([email protected])],
    CGI.escape(login),
    CGI.escape(password),
    CGI.escape(data.split("><").grep(/PPFT/).first[/=\S+$/][2..-3])
  ]

(...)
end

More informations about versions

Hi,

Currently I have some difficulty each time I want to update the contacts gem.
Before installing a new version, I'm used to check what changes comes with the new version but your gem doesn't provide any information about any change.

I think this could help:

  • adding a changelog file
  • creating a tag per release
  • mentioning version in commit message (eg. bumped the version to 1.2.25)

I also noticed that some popular gems add a <project_name>/version.rb file that they use in their gemspec file.

What do you think about this?

problem with ruby 1.9.3

Hi!

In ruby 1.9.2 gmail and yahoo work fine for me, but when switching to 1.9.3, I have following errors:

yahoo:
gems/liangzan-contacts-1.2.9/lib/contacts/yahoo.rb:17:in real_connect': undefined methodindex' for nil:NilClass (NoMethodError)

hotmail:
gems/liangzan-contacts-1.2.9/lib/contacts/hotmail.rb:21:in real_connect': undefined methodsplit' for nil:NilClass (NoMethodError)

In general it looks like data got from 'post/get' methods is nil...

gmail works fine

I tested ruby-1.9.3-p0 [ x86_64 ] and ruby-1.9.3-p125 [ x86_64 ] both have the same error.

Thanks for any suggestions.

get contact form yahoo only get 9 contacts

Hi liangzan, when I try Contacts.new(:yahoo, email_yahoo, password_yahoo).contacts.size
I only get 9 contacts, I've more than 10 contacts on my account, do you know why this happen?

Thanks

GMX import not working any more, partially fixed

Since a couple days ago, GMX has redesigned most of its website and the redirects are not working any more. This is due to two reasons (both of which I have fixed locally):

  1. Mozilla Firefox 2.0 as user agent is not supported -> changing to Firefox 18 will work
  2. GMX uses relative redirects which base.rb does not support yet

The third reason is a change of redirects. I have fixed this, but it is currently not working, and I don't understand why, since when recording the session in Firefox the redirects and cookies are exactly the same.

Would you be willing to collaborate on a fix? I can send a patch with the current status.

Remove historical reference to RubyForge

Hi,

I've been using the contacts gem for about 3 years now. I'm glad to see that there's still someone working on it.

I think it's time to forget some parts of the past. I propose to remove the RubyForge link.
It's the first url visible on the GitHub project page but the RubyForge page hasn't been updated for more than 3 years.

This could be a little bit confusing for new users of your gem.

Gmail not working.

Hi, when i try to find contacts for gmail it give authentication error although my credentials are correct.

I try:
Contacts::Gmail.new("[email protected]","password").conacts

Error:
Contacts::AuthenticationError: Username or password are incorrect
from /home/chandra/.rvm/gems/ruby-1.9.3-p194@itour/bundler/gems/contacts-a8f76537e8b1/lib/contacts/gmail.rb:38:in `rescue in real_connect'

But it works fine for other mail except gmail.

Would you please figure out why its so.

In gem file i have:
gem "liangzan-contacts", :git => 'git://github.com/liangzan/contacts.git'

Error with hotmail since some days

Didn't change anything to my code and I'm getting this error since a week with Hotmail only :
Any idea ?

CSV::MalformedCSVError in ImportedContactsController#import_provider

Missing or stray quote in line 1

can handle captcha on yahoo?

Hi

I still got Contacts::AuthenticationError: Username and password do not match on my production server but not on my local server,

when I check on data and response I get this:
The code you entered is invalid. Please try again

and show recaptcha, could this gem handle captcha on yahoo login page?

thanks

new encoding problem with hotmail

Getting some errores like this :-(

A Encoding::InvalidByteSequenceError occurred in imported_contacts#import_provider:

""T" on UTF-16
/home/rails/www.nounou-top.fr/shared/bundle/ruby/1.9.1/bundler/gems/contacts-3a3f1c269235/lib/contacts/hotmail.rb:68:in `encode'

undefined contacts for nil

If I use guess, I get this....

1.9.2p318 :002 > Contacts.guess('username', 'password').contacts
NoMethodError: undefined method contacts' for nil:NilClass from (irb):2 from /Users/aa/.rvm/gems/ruby-1.9.2-p318/gems/railties-3.2.3/lib/rails/commands/console.rb:47:instart'
from /Users/aa/.rvm/gems/ruby-1.9.2-p318/gems/railties-3.2.3/lib/rails/commands/console.rb:8:in start' from /Users/aa/.rvm/gems/ruby-1.9.2-p318/gems/railties-3.2.3/lib/rails/commands.rb:41:in<top (required)>'
from script/rails:6:in require' from script/rails:6:in

'

AND

1.9.2p318 :001 > Contacts.guess('[email protected]', 'password').contacts
NoMethodError: undefined method contacts' for #<Array:0x000001062f20e0> from (irb):1 from /Users/aa/.rvm/gems/ruby-1.9.2-p318/gems/railties-3.2.3/lib/rails/commands/console.rb:47:instart'
from /Users/aa/.rvm/gems/ruby-1.9.2-p318/gems/railties-3.2.3/lib/rails/commands/console.rb:8:in start' from /Users/aa/.rvm/gems/ruby-1.9.2-p318/gems/railties-3.2.3/lib/rails/commands.rb:41:in<top (required)>'
from script/rails:6:in require' from script/rails:6:in

However, if I use the gmail version, it works. Why would that be? How do I get guess working.

THANK YOU!

Utf-8 problem with Hotmail in haml on Ruby 1.9.3

Regarding to following commit wearedalt@4f979e6 the data returned from Hotmail is in ISO-8859-1 and if we want to show the results in a template usign HAML as template language and we got the error :

incompatible character encodings: ASCII-8BIT and UTF-8

Here is an example of a contact name returned by Hotmail using the gem :
"M\xE9la De R."

This can not be parsed by HAML, is it possible to change the hotmail return back to UTF-8?

Not working with yahoo

I am getting this error while using Contacts::Yahoo.new(login,password).contacts
undefined method []' for nil:NilClass from /home/sodel/s195/vendor/plugins/contacts/lib/contacts/yahoo.rb:53:incontacts'
from (irb):4
from /home/sodel/.rvm/gems/ruby-1.9.3-p429@sports195/gems/railties-3.0.19/lib/rails/commands/console.rb:44:in start' from /home/sodel/.rvm/gems/ruby-1.9.3-p429@sports195/gems/railties-3.0.19/lib/rails/commands/console.rb:8:instart'
from /home/sodel/.rvm/gems/ruby-1.9.3-p429@sports195/gems/railties-3.0.19/lib/rails/commands.rb:23:in <top (required)>' from script/rails:6:inrequire'
from script/rails:6:in `

'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.