weppos / whois-parser

An intelligent — pure Ruby — WHOIS parser.
https://whoisrb.org
MIT License
99 stars 102 forks source link

Fails to parse *.sk TLD #129

Open mienkofax opened 4 years ago

mienkofax commented 4 years ago

When attempting to parse the response for sme.sk, google.sk from whois.sk-nic.sk you get an Unexpected token error.

Running the code

#!/usr/bin/env ruby

require 'whois-parser'

record = Whois.whois("sme.sk")
parser = record.parser

p Whois::Parser::PROPERTIES

p parser.domain

Fails with the following error:

./rub 
[:disclaimer, :domain, :domain_id, :status, :available?, :registered?, :created_on, :updated_on, :expires_on, :registrar, :registrant_contacts, :admin_contacts, :technical_contacts, :nameservers]
Traceback (most recent call last):
        3: from ./rub:10:in `<main>'
        2: from /var/lib/gems/2.5.0/gems/whois-parser-1.2.0/lib/whois/parser.rb:348:in `method_missing'
        1: from /var/lib/gems/2.5.0/gems/whois-parser-1.2.0/lib/whois/parser.rb:327:in `domain'
/var/lib/gems/2.5.0/gems/whois-parser-1.2.0/lib/whois/parser.rb:365:in `delegate_property_to_parsers': Unable to find a parser for property `domain' (Whois::AttributeNotImplemented)
istana commented 3 years ago

I noticed the same issue. I can take a look on this one.