Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8821933
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T05:58:34+00:00 2026-06-14T05:58:34+00:00

I would like to use module WWWW::Wunderground::API to download data with weather using JSON.

  • 0

I would like to use module WWWW::Wunderground::API to download data with weather using JSON.

Here is my PERL script:

use WWW::Wunderground::API;

my $wun = new WWW::Wunderground::API(location=>'KIAD', api_key=>'my key');
print 'JSON source:'.$wun->json if $wun->api_type eq 'json';

It gives me an error:

Can’t bless non-reference value at
/usr/local/share/perl5/Hash/AsObject.pm line 82.

I cannot fix it up. I have been trying to update cpan and other modules but it gives no results.

Could you tell me how can I repair it?

Thank you in advance


with Carp::Always:

Can’t bless non-reference value at
/usr/local/share/perl5/Hash/AsObject.pm line 82
Hash::AsObject::AUTOLOAD(‘Hash::AsObject’, undef) called at
/usr/local/share/perl5/WWW/Wunderground/API.pm line 37
WWW::Wunderground::API::update(‘WWW::Wunderground::API=HASH(0x1e5b178)’,
‘KIAD’) called at /home/xyz/workspace/WeatherTest/scr.pl line 4
eval {…} called at /home/xyz/workspace/WeatherTest/scr.pl line
4

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T05:58:35+00:00Added an answer on June 14, 2026 at 5:58 am

    It comes from a lack of error checking. The following unexpectedly returns undef:

    JSON::Any->jsonToObj($json)->{current_observation}
    

    You might want to have a look at what’s getting fetched by using the following:

    use LWP::Simple qw( get );
    my $api_key  = 'my key';
    my $location = 'KIAD';
    print get("http://api.wunderground.com/api/$api_key/conditions/q/$location.json");
    

    Perhaps there’s an error message in the response you can address. For example, a bad API key would result in the following response:

    {
            "response": {
                    "version": "0.1"
                    ,"termsofService": "http://www.wunderground.com/weather/api/d/terms.html"
                    ,"features": {
                    }
                    ,
            "error": {
                    "type": "keynotfound"
                    ,"description": "this key does not exist"
            }
            }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Perl module that I would like to use from Java. Is
I would like to use Python's JSON module. It was only introduced in Python
Hello I would like to use the sass module in a play application. We
I would like to use the Helicon ISAPI_REWRITE module to rewrite a url: 123.45.67.89/folder
I would like to use D3.js (or maybe Raphaël ) for backend-generated reports using
I would like to use the jenkins script console some more. Where do I
I would like to use a pre-commit hook in riak to validate the json
I would like to use the dbm module on my Windows machine, but it
I would like to use the python logging module to log all of the
I have a multi module maven project and I would like to use versions

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.