Skip to content

error when checking CNAME "@" #60

Closed
@jldec

Description

@jldec

CNAME records might point to @ because some DNS providers use that for alias records.
This appears to confuse pages-health-check.

$ bundle exec script/check bad.example.com
/Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/domain.rb:130:in `pages_dot_github_dot_com?': undefined method `match' for nil:NilClass (NoMethodError)
Did you mean?  catch
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/domain.rb:115:in `cname_to_pages_dot_github_dot_com?'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/domain.rb:107:in `cname_to_github_user_domain?'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/domain.rb:162:in `proxied?'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/checkable.rb:33:in `public_send'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/checkable.rb:33:in `block in to_hash'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/checkable.rb:32:in `each'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/checkable.rb:32:in `to_hash'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/site.rb:21:in `to_hash'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/printer.rb:15:in `simple_string'
    from /Users/jldec/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/github-pages-health-check-1.2.0/lib/github-pages-health-check/checkable.rb:47:in `to_s'
    from ./script/check:11:in `puts'
    from ./script/check:11:in `puts'
    from ./script/check:11:in `<main>'

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions