Result:
found more than 407 distributions - search limited to the first 2001 files matching your query ( run in 1.292 )


Alter

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

debop||5.005000|
debprofdump||5.005000|
debprof|||
debstackptrs||5.007003|
debstack||5.007003|
debug_start_match|||
deb||5.007003|v
del_sv|||
delete_eval_scope|||
delimcpy||5.004000|
deprecate_old|||

ppport.h  view on Meta::CPAN

get_arena|||
get_av|5.006000||p
get_context||5.006000|n
get_cv|5.006000||p
get_db_sub|||
get_debug_opts|||
get_hash_seed|||
get_hv|5.006000||p
get_mstats|||
get_no_modify|||
get_num|||

ppport.h  view on Meta::CPAN

incline|||
incpush_if_exists|||
incpush|||
ingroup|||
init_argv_symbols|||
init_debugger|||
init_global_struct|||
init_i18nl10n||5.006000|
init_i18nl14n||5.006000|
init_ids|||
init_interp|||

ppport.h  view on Meta::CPAN

rsignal_save|||
rsignal_state||5.004000|
rsignal||5.004000|
run_body|||
run_user_filter|||
runops_debug||5.005000|
runops_standard||5.005000|
rvpv_dup|||
rxres_free|||
rxres_restore|||
rxres_save|||

 view all matches for this distribution


Alvis-Convert

 view release on metacpan or  search on metacpan

lib/Alvis/Buffer.pm  view on Meta::CPAN


text to enter at the end of a sequence of <documentRecord> elements.

=head2 verbose

set to a non-zero value if more debugging shoulöd be reported to STDERR.

Then the are variables that are read-only and define current buffer
statistics.

=head2 size

 view all matches for this distribution


Alvis-NLPPlatform

 view release on metacpan or  search on metacpan

lib/Alvis/NLPPlatform.pm  view on Meta::CPAN

 be writable to the user the process is running as.

=item *

C<DEBUG> : this variable indicates if the NLP platform is run in a
debug mode or not. The value are 1 (debug mode) or 0 (no debug
mode). Default value is 0. The main consequence of the debug mode is
to keep the temporary file.

=back


 view all matches for this distribution


Alvis-Pipeline

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

	  server on localhost port 80 -- too many people inexplicably
	  do not run web servers :-)

0.04  Mon Oct  3 14:14:43 BST 2005
	- Total rewrite, not using OAI.  Much simpler and more reliable.
	- Better debugging output.
	- Better documentation.

0.03  Fri Sep 16 17:22:37 BST 2005
	- Fixes to documentation (dependencies listed in "README")
	- Added "INSTALL.Debian" file (Marc).

 view all matches for this distribution


Alvis-QueryFilter

 view release on metacpan or  search on metacpan

lib/Alvis/QueryFilter.pm  view on Meta::CPAN

    close(F);

    return \%dict;
}

sub transform   # just for testing and debugging
{
    my $self=shift;
    my $query=shift; # list of word forms
    
    my $expanded_query_struct=$self->_expand_qword_list($query);

 view all matches for this distribution


Alvis-Saa

 view release on metacpan or  search on metacpan

lib/Alvis/Saa.pm  view on Meta::CPAN

use IO::Socket;
use IO::Select;
use Fcntl;

my $LOCALADDR_PREFIX = "/var/tmp/searchrpc_localsoc_";
my $debug = 0;

######################################################################
#
#  Public methods
#

lib/Alvis/Saa.pm  view on Meta::CPAN

#				      Type => SOCK_STREAM,
#				      Timeout => 10);
#    }
    if(!defined($conn))
    {
#	$debug && print STDERR "Saa::connect(): domain socket $LOCALADDR_PREFIX$port failed with $!, trying inet\n";
	if(!($conn = IO::Socket::INET->new(PeerAddr => $host,
					   PeerPort => $port,
					   Proto => "tcp",
					   Type => SOCK_STREAM)))
	{
	    $debug && print STDERR "Saa::connect(): tcp connect failed with $@\n";
	    $this->{'err'} = "$@";
	    return 0;
	}
    }
    else
    {
	$debug && print STDERR "Saa::connect(): Successfully opened localsoc!\n";
    }

    binmode($conn, ":raw");

    $cn->{'conn'} = $conn;

lib/Alvis/Saa.pm  view on Meta::CPAN

#	{
#	    my $sn = $client->sockname();
#	    $sn =~ /$LOCALADDR_PREFIX([0-9]+)/;
#	    $port = $1;
#	    $str_ip = inet_ntoa($this->{'my_addr'});
#	    $debug && print STDERR "Saa::process_accept(): AF_UNIX connection with ip $str_ip port $port\n";
#	}

	my $cn = 
	{
	    'host' => $str_ip,

lib/Alvis/Saa.pm  view on Meta::CPAN

	{
	    my $cb = $cn->{'callback'};
	    my $func = undef;
	    my @param = ();
	    
	    $debug && print STDERR "Callback = ", ref($cb), "\n";
	    if(ref($cb) eq 'CODE')
	    {
		$func = $cb;
	    }
	    else
	    {
		@param = @$cb;
		$func = shift(@param);
	    }
	    $debug && print STDERR "Func cb ref = ", ref($func), "\n";
	    $func->($this, $entry, @param);
	}
	else
	{
	    push(@$received, $entry);

 view all matches for this distribution


Alzabo-GUI-Mason

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


0.10    2004-06-29

- If an Alzabo::Exception::RDBMSRules exception is thrown, the full
  exception (with stack trace) is now output to STDERR.  This helps
  debugging in case the exception is due to an error in Alzabo, as
  opposed to user error.

- Some submission handling components were redirecting to the wrong
  place after handling a RDBMSRules exception.

 view all matches for this distribution


Alzabo

 view release on metacpan or  search on metacpan

lib/Alzabo.pm  view on Meta::CPAN

L<The Alzabo::Runtime::UniqueRowCache
docs|Alzabo::Runtime::UniqueRowCache> - This describes the simple
caching system included with Alzabo.

L<The Alzabo::Debug docs|Alzabo::Debug> - How to turn on various kinds
of debugging output.

L<The Alzabo::Exceptions docs|Alzabo::Exceptions> - Describes the
nature of all the exceptions used in Alzabo.

L<The FAQ|Alzabo::FAQ>.

 view all matches for this distribution


Amazon-API

 view release on metacpan or  search on metacpan

lib/Amazon/API.pm  view on Meta::CPAN

__PACKAGE__->follow_best_practice;

__PACKAGE__->mk_accessors(qw/action api api_methods version content_type
			     http_method credentials response protocol
			     region url service_url_base 
			     signer target user_agent debug last_action
			     aws_access_key_id aws_secret_access_key token
			    /);

use vars qw/@EXPORT $VERSION/;

lib/Amazon/API.pm  view on Meta::CPAN


=item url

The service url.  Example: https://events.us-east-1.amazonaws.com

=item debug

0/1 - will dump request/response if set to true.

=item action

lib/Amazon/API.pm  view on Meta::CPAN

    $content = $parameters;
  }
   
  my $rsp = $self->submit(content => $content, content_type => $content_type);
  
  if ( $self->get_debug ) {
    print STDERR Dumper [$rsp];
  }
    
  # probably want to decode content when there is an error, but this
  # will do for now

lib/Amazon/API.pm  view on Meta::CPAN

		 
  # sign the request
  $self->get_signer->sign($request);

  # make the request, return response object
  if ( $self->get_debug ) {
    print STDERR Dumper([$request]);
  }
  
  $self->get_user_agent->request($request);
}

 view all matches for this distribution


Amazon-Credentials

 view release on metacpan or  search on metacpan

lib/Amazon/Credentials.pm  view on Meta::CPAN


use parent qw/Class::Accessor Exporter/;

__PACKAGE__->follow_best_practice;
__PACKAGE__->mk_accessors(qw/aws_secret_access_key aws_access_key_id token region
			     user_agent profile debug expiration role container order 
			     serialized logger
			    /);

use Data::Dumper;
use Date::Format;

lib/Amazon/Credentials.pm  view on Meta::CPAN


$VERSION = '1.0.10-1'; $VERSION=~s/\-.*$//;

@EXPORT = qw/$VERSION/;

# we only log at debug level, create a default logger
{
  no strict 'refs';
  
  *{'Amazon::Credentials::Logger::debug'} = sub {
    shift;
    my @tm = localtime(time);
    print STDERR sprintf("%s [%s] %s", strftime("%c", @tm), $$, @_);
  };
}

lib/Amazon/Credentials.pm  view on Meta::CPAN


=head2 new

 new( options );

 my $aws_creds = new Amazon::Credential( { profile => 'sandbox', debug => 1 });

C<options> is a hash of keys that represent options.  Any of the
options can also be retrieved using their corresponding 'get_{option}
method.

lib/Amazon/Credentials.pm  view on Meta::CPAN

AWS secret access key.

I<Note: If you pass the access keys in the constructor then the
constructor will not look in other places for credentials.>

=item debug

Set to true for verbose troubleshooting information.

=item logger

Pass in your own logger that has a C<debug()> method.  Otherwise the
default logger will output debug messages to STDERR.

=item user_agent

Pass in your own user agent, otherwise LWP will be used. I<Probably
only useful to override this for testing purposes.>

lib/Amazon/Credentials.pm  view on Meta::CPAN

	  }
	}
	  
	close $fh;
	  
	$self->get_logger->debug(Dumper [ $creds ])
	  if $self->get_debug;
	
	$creds->{source} = $config if $creds->{aws_secret_access_key} && $creds->{aws_access_key_id};
      }
	
      last if $creds->{source};

lib/Amazon/Credentials.pm  view on Meta::CPAN

    $g -= $window_interval * 60;

    # (expiration_time - window_interval) - current_time = # of seconds left before expiration
    my $seconds_left = $g - time;

    if ( $self->get_debug ) {
      my $hours = int($seconds_left/3600);
      my $minutes = int(($seconds_left - $hours * 3600)/60);
      my $seconds = $seconds_left - ($hours * 3600 + $minutes * 60);
      $self->get_logger->debug(sprintf("%d hours %d minutes %d seconds until expiry\n", $hours, $minutes, $seconds));
    }
    
    $expired = ($seconds_left < 0) ? 1 : 0;
    
    $self->get_logger->debug(Dumper [ "EXPIRATION TIME: " . $expiration_date, "EXPIRED: " . $expired])
      if $self->get_debug;
  }

  return $expired;
}

lib/Amazon/Credentials.pm  view on Meta::CPAN

      
      $url .= $role if $role;
      
      my $req = HTTP::Request->new( GET => $url );
      
      $self->get_logger->debug(Dumper [ "HTTP REQUEST:\n", $req ])
	if $self->get_debug;
      
      my $rsp = $ua->request($req);
      
      $self->get_logger->debug(Dumper [ "HTTP RESPONSE:\n", $rsp ])
	if $self->get_debug;
      
      # if not 200, then get out of Dodge
      last unless $rsp->is_success;
      
      if ( $role ) {

lib/Amazon/Credentials.pm  view on Meta::CPAN

	@{$creds}{qw/source role aws_access_key_id aws_secret_access_key token expiration/} =
	  ('IAM',$role, @{$this}{qw/AccessKeyId SecretAccessKey Token Expiration/});
      }
      else {
	$role = $rsp->content;
	$self->get_logger->debug(Dumper ['role', $role])
	  if $self->get_debug;

	last unless $role;
      }
    }
  };

lib/Amazon/Credentials.pm  view on Meta::CPAN

   }
  elsif ( $self->get_role ) {
    $creds = $self->get_creds_from_role;
  }

  $self->get_logger->debug(Dumper [$creds])
    if $self->get_debug;

  die "unable to refresh token!"
    unless ref($creds);
  
  $self->set_credentials($creds);

lib/Amazon/Credentials.pm  view on Meta::CPAN

    
    my $ua = $self->get_user_agent;
    my $req = HTTP::Request->new( GET => $url );
    $req->header("Accept", "*/*");
    
    $self->get_logger->debug(Dumper [ "HTTP REQUEST:\n", $req ])
      if $self->get_debug;

    $self->get_logger->debug(Dumper [ $req->as_string ])
      if $self->get_debug;
    
    my $rsp = $ua->request($req);
    
    $self->get_logger->debug(Dumper [ "HTTP RESPONSE:\n", $rsp ])
      if $self->get_debug;
    
    # if not 200, then get out of Dodge
    if ( $rsp->is_success ) {
      $creds->{serialized} = $rsp->content;
      my $this = from_json($rsp->content);
      @{$creds}{qw/source container aws_access_key_id aws_secret_access_key token expiration/} =
	('IAM','ECS', @{$this}{qw/AccessKeyId SecretAccessKey Token Expiration/});
    }
    else {
      $self->get_logger->debug( "return code: " . $rsp->status_line . "\n");
    }
    
    $creds->{error} = $@ if $@;
  }
  

 view all matches for this distribution


Amazon-Dash-Button

 view release on metacpan or  search on metacpan

lib/Amazon/Dash/Button/Device.pm  view on Meta::CPAN

    die "mac address is undefined" unless defined $self->mac();

    return $self;
}

sub debug {
	warn join( ' ', map { $_ // 'undef' } @_ );
}

sub check {
    my ( $self, $mac2check ) = @_;

lib/Amazon/Dash/Button/Device.pm  view on Meta::CPAN


    $mac2check =~ s{:}{}g;

    return if $self->mac() ne lc($mac2check);

    debug( "Find Button", $self->name() );
    my $now = time();
    return
      if $self->timeout > 0 && ( $now - $self->last_click ) <= $self->timeout;
    $self->last_click($now);
    debug( "perform onClick for", $self->name() );

    # we want to fork to run the onClick action
    #	we can disable it during unit tests or others
    return
      if $self->_fork_for_onClick()

 view all matches for this distribution


Amazon-DynamoDB

 view release on metacpan or  search on metacpan

lib/Amazon/DynamoDB.pm  view on Meta::CPAN

     use_iam_role   => 1, 

     host => 'dynamodb.us-east-1.amazonaws.com',
     scope => 'us-east-1/dynamodb/aws4_request',
     ssl => 1,
     debug => 1);

  $ddb->batch_get_item(
     sub {
       my $tbl = shift;
       my $data = shift;

 view all matches for this distribution


Amazon-MWS

 view release on metacpan or  search on metacpan

lib/Amazon/MWS/Routines.pm  view on Meta::CPAN

            $content  = $response->content;

        }


	if ($self->{debug}) {
                open LOG, ">>$self->{logfile}";
		print LOG Dumper($response);
            }

        my $xs = XML::Simple->new( KeepRoot => 1 );

lib/Amazon/MWS/Routines.pm  view on Meta::CPAN

    $opts{access_key_id} ||= $xmlconfig->{access_key_id};
    $opts{secret_key} ||= $xmlconfig->{secret_key};
    $opts{merchant_id} ||= $xmlconfig->{merchant_id};
    $opts{marketplace_id} ||= $xmlconfig->{marketplace_id};
    $opts{endpoint} ||= $xmlconfig->{endpoint};
    $opts{debug} ||= $xmlconfig->{debug};
    $opts{logfile} ||= $xmlconfig->{logfile};
 }

 my $attr = $opts->{agent_attributes};
    $attr->{Language} = 'Perl';

lib/Amazon/MWS/Routines.pm  view on Meta::CPAN

    die 'No access key id' unless  $opts{access_key_id};
    die 'No secret key' unless $opts{secret_key};
    die 'No merchant id' unless $opts{merchant_id};
    die 'No marketplace id' unless $opts{marketplace_id};

    if ($opts{debug}) {
       open LOG, ">$opts{logfile}" or die "Cannot open logfile.";
       print LOG DateTime->now();
       print LOG "\nNew instance created. \n";
       print LOG Dumper(\%opts);
       close LOG; 

lib/Amazon/MWS/Routines.pm  view on Meta::CPAN

    endpoint => $opts{endpoint},
    access_key_id => $opts{access_key_id},
    secret_key => $opts{secret_key},
    merchant_id => $opts{merchant_id},
    marketplace_id => $opts{marketplace_id}, 
    debug => $opts{debug}, 
    logfile => $opts{logfile},
	}, $pkg;

}

 view all matches for this distribution


Amazon-S3-Thin

 view release on metacpan or  search on metacpan

lib/Amazon/S3/Thin.pm  view on Meta::CPAN


    bless $self, $class;

    $self->secure(0)                unless defined $self->secure;
    $self->ua($self->_default_ua)   unless defined $self->ua;
    $self->debug(0)                 unless defined $self->debug;
    $self->virtual_host(0)          unless defined $self->virtual_host;

    $self->{signature_version} = 4  unless defined $self->{signature_version};
    if ($self->{signature_version} == 4 && ! $self->{region}) {
        croak "Please set region when you use signature v4";

lib/Amazon/S3/Thin.pm  view on Meta::CPAN

    } else {
        return $self->{secure};
    }
}

sub debug {
    my $self = shift;
    if (@_) {
        $self->{debug} = shift;
    } else {
        return $self->{debug};
    }
}

sub ua {
    my $self = shift;

lib/Amazon/S3/Thin.pm  view on Meta::CPAN

    }
}

sub _send {
    my ($self, $request) = @_;
    warn "[Request]\n" , $request->as_string if $self->{debug};
    my $response = $self->ua->request($request);
    warn "[Response]\n" , $response->as_string if $self->{debug};
    return $response;
}

# API calls

lib/Amazon/S3/Thin.pm  view on Meta::CPAN

Default is an instance of L<LWP::UserAgent>.

=item * C<signature_version> - AWS signature version to use. Supported values
are 2 and 4. Default is 4.

=item * C<debug> - debug option. Default is 0 (false). 
If set 1, contents of HTTP request and response are shown on stderr

=item * C<virtual_host> - whether to use virtual-hosted style request format. Default is 0 (path-style).

=back

lib/Amazon/S3/Thin.pm  view on Meta::CPAN


The user agent used internally to perform requests and return responses.
If you set this attribute, please make sure you do so with an object
compatible with L<LWP::UserAgent> (i.e. providing the same interface).

=head2 debug

Debug option.

=head1 Operations on Buckets

 view all matches for this distribution


Amazon-S3

 view release on metacpan or  search on metacpan

lib/Amazon/S3.pm  view on Meta::CPAN

  $options{retry}            //= $FALSE;

  $options{_region} = delete $options{region};
  $options{_signer} = delete $options{signer};

  # convenience for level => 'debug' & for consistency with
  # Amazon::Credentials only do this if we are using internal logger,
  # call should NOT use debug flag but rather use their own logger's
  # level to turn on higher levels of logging...

  if ( !$options{logger} ) {
    if ( delete $options{debug} ) {
      $options{level} = 'debug';
    }

    $options{log_level} = delete $options{level};
    $options{log_level} //= $DEFAULT_LOG_LEVEL;

lib/Amazon/S3.pm  view on Meta::CPAN


  my $self = $class->SUPER::new( \%options );

  # setup logger internal logging

  $self->get_logger->debug(
    sub {
      my %safe_options = %options;

      if ( $safe_options{aws_secret_access_key} ) {
        $safe_options{aws_secret_access_key} = '****';

lib/Amazon/S3.pm  view on Meta::CPAN


  if (@args) {
    $self->_region( $args[0] );
  }

  $self->get_logger->debug(
    sub { return 'region: ' . ( $self->_region // $EMPTY ) } );

  if ( $self->_region ) {
    my $host = $self->host;
    $self->get_logger->debug( sub { return 'host: ' . $self->host } );

    if ( $host =~ /\As3[.](.*)?amazonaws/xsm ) {
      $self->host( sprintf 's3.%s.amazonaws.com', $self->_region );
    }
  }

lib/Amazon/S3.pm  view on Meta::CPAN


    $path .= $query_string;

  }

  $self->get_logger->debug( sprintf 'PATH: %s', $path );

  my $r = $self->_send_request(
    { method  => 'GET',
      path    => $path,
      headers => {},           # { 'Content-Length' => 0 },

lib/Amazon/S3.pm  view on Meta::CPAN

    else {
      $url = "$protocol://$bucket.$host$path$query_string";
    }
  }

  $self->get_logger->debug( sprintf 'URL (uri): %s', $url );

  my $request = HTTP::Request->new( $method, $url, $http_headers );

  $self->last_request($request);

lib/Amazon/S3.pm  view on Meta::CPAN

    $request = $self->_make_request(@args);
  }

  my $response = $self->_do_http($request);

  $self->get_logger->debug( Dumper( [$response] ) );

  $self->last_response($response);

  my $content = $response->content;

lib/Amazon/S3.pm  view on Meta::CPAN

  # respond with a temporary redirect.  In this case it is necessary
  # to try again with the new URL
  if ( $response->code =~ /\A3/xsm and defined $response->header('Location') )
  {

    $self->get_logger->debug(
      'Redirecting to:  ' . $response->header('Location') );

    $request->uri( $response->header('Location') );
    $response = $self->ua->request( $request, $filename );
  }

  $self->get_logger->debug( Dumper( [$response] ) );

  $self->last_response($response);

  return $response;
}

lib/Amazon/S3.pm  view on Meta::CPAN


  # convenient time to reset any error conditions
  $self->reset_errors;

  my $response = $self->ua->request( $request, $filename );
  $self->get_logger->debug( Dumper( [$response] ) );

  $self->last_response($response);

  return $response;
}

lib/Amazon/S3.pm  view on Meta::CPAN


  my $request = $self->_make_request(@args);

  my $response = $self->_do_http($request);

  $self->get_logger->debug( Dumper( [$response] ) );

  my $content = $response->content;

  return $TRUE
    if $response->code =~ /^2\d\d$/xsm;

lib/Amazon/S3.pm  view on Meta::CPAN

    }
    else {
      $self->_croak_if_response_error($response);
    }

    $self->get_logger->debug( 'setting override URI to ', $override_uri );
  }

  $request = $self->_make_request(
    { method  => $method,
      path    => $path,

lib/Amazon/S3.pm  view on Meta::CPAN


Returns the logger object. If you did not set a logger when you
created the object then an instance of C<Amazon::S3::Logger> is
returned. You can log to STDERR using this logger. For example:

 $s3->get_logger->debug('this is a debug message');

 $s3->get_logger->trace(sub { return Dumper([$response]) });

=head2 list_bucket_all, list_bucket_all_v2

lib/Amazon/S3.pm  view on Meta::CPAN


=head1 ADDITIONAL INFORMATION

=head2 LOGGING AND DEBUGGING

Additional debugging information can be output to STDERR by setting
the C<level> option when you instantiate the C<Amazon::S3>
object. Levels are represented as a string.  The valid levels are:

 fatal
 error
 warn
 info
 debug
 trace

You can set an optionally pass in a logger that implements a subset of
the C<Log::Log4perl> interface.  Your logger should support at least
these method calls. If you do not supply a logger the default logger

lib/Amazon/S3.pm  view on Meta::CPAN

 get_logger()
 fatal()
 error()
 warn()
 info()
 debug()
 trace()
 level()

At the C<trace> level, every HTTP request and response will be output
to STDERR.  At the C<debug> level information regarding the higher
level methods will be output to STDERR.  There currently is no
additional information logged at lower levels.

=head2 S3 LINKS OF INTEREST

 view all matches for this distribution


Amazon-S3Curl-PurePerl

 view release on metacpan or  search on metacpan

lib/Amazon/S3Curl/PurePerl.pm  view on Meta::CPAN



set_logger(
    Log::Contextual::SimpleLogger->new(
        {
            levels_upto => 'debug'
        } ) );


has curl => (
    is      => 'ro',

 view all matches for this distribution


Amazon-SNS-V4

 view release on metacpan or  search on metacpan

lib/Amazon/SNS/V4.pm  view on Meta::CPAN

use strict;
use warnings;

use base qw/ Class::Accessor::Fast /;

__PACKAGE__->mk_accessors(qw/ key secret error status_code service debug signer error_response/);

use LWP::UserAgent;
use XML::Simple;
use URI::Escape;
use AWS::Signature4;

lib/Amazon/SNS/V4.pm  view on Meta::CPAN

				: $response->status_line
		);
	}

	print STDERR 'ERROR: ', $self->error, "\n"
		if $self->debug;

	return undef;
}

sub timestamp {

lib/Amazon/SNS/V4.pm  view on Meta::CPAN


=head2 $sns->secret('...')

Get/set secret.

=head2 $sns->debug

=head2 $sns->debug(1)

Get/set debug level. When set to 1 you'll get some debug output on STDERR.

=head1 NOTES

Be sure to use ARNs in the same region as you have set the service to.

 view all matches for this distribution


Amazon-SNS

 view release on metacpan or  search on metacpan

lib/Amazon/SNS.pm  view on Meta::CPAN

use strict;
use warnings;

use base qw/ Class::Accessor::Fast /;

__PACKAGE__->mk_accessors(qw/ key secret error status_code service debug /);

use LWP::UserAgent;
use XML::Simple;
use URI::Escape;
use Digest::SHA qw(hmac_sha256_base64);

lib/Amazon/SNS.pm  view on Meta::CPAN

				: $response->status_line
		);
	}

	print STDERR 'ERROR: ', $self->error, "\n"
		if $self->debug;

	return undef;
}

sub timestamp {

lib/Amazon/SNS.pm  view on Meta::CPAN


=item $sns->secret('...')

	Get/set secret.
	
=item $sns->debug

=item $sns->debug(1)

	Get/set debug level. When set to 1 you'll get some debug output on STDERR.

=back

=head1 NOTES

 view all matches for this distribution


Amazon-SQS-Client

 view release on metacpan or  search on metacpan

bin/QueueDaemon.pl  view on Meta::CPAN


  $loglevel //= 'info';

  $loglevel = {
    error => $ERROR,
    debug => $DEBUG,
    trace => $TRACE,
    info  => $INFO,
    warn  => $WARN,
  }->{ lc $loglevel };

bin/QueueDaemon.pl  view on Meta::CPAN

     --no-daemonize       
 -D, --delete-when        never, always, error
 -E, --exit-when          never, always, error, false
 -e, --endpoint-url       default: https://sqs.amazonaws.com
 -L, --logfile            name of logfile
 -l, --loglevel           log level (trace, debug, info, warn, error)
 -H, --handler            name of the handler class, default: Amazon::SQS::QueueHandler
 -m, --max-children       not implemented (default: 1)
 -s, --max-sleep-time     default: 5 seconds
     --max-messages       fixed at 1 currently
 -M, --message-type       mime type of messages (text/plain, application/json, 

 view all matches for this distribution


Amazon-SQS-ProducerConsumer

 view release on metacpan or  search on metacpan

lib/Amazon/SQS/Consumer.pm  view on Meta::CPAN


=item wait_seconds (optional)

The number of seconds to wait for a new message when the queue is empty.

=item debug (optional)

A flag to turn on debugging. It is turned off by default.

=back

=cut

lib/Amazon/SQS/Consumer.pm  view on Meta::CPAN


sub delete_previous {
	my $me = shift;

	if ( $me->{DeleteMessageHandle} ) {
		say "deleting message $me->{DeleteMessageHandle}" if $me->{debug};
		$me->delete_message( Queue => $me->{queue}, ReceiptHandle => $me->{DeleteMessageHandle} );
	}
}

sub defer { delete $_[0]->{DeleteMessageHandle} }

 view all matches for this distribution


Amazon-SQS-Simple-AnyEvent

 view release on metacpan or  search on metacpan

lib/Amazon/SQS/Simple/AnyEvent.pm  view on Meta::CPAN

    }

    my ($query, @auth_headers) = $self->_get_signed_query($params, $post_request);
    my %http_opts = (tls_ctx => "low");

    $self->_debug_log($query);

    my $on_response = sub {
        my ($content, $headers) = @_;
        $self->_debug_log($content);
        if ($headers->{Status} =~ /^2/) {
            my $href =  XMLin($content, ForceArray => $force_array, KeyAttr => {});
            $cb->($href);
        }
        else {

 view all matches for this distribution


Amazon-SQS-Simple

 view release on metacpan or  search on metacpan

lib/Amazon/SQS/Simple/Base.pm  view on Meta::CPAN


        my $signer = AWS::Signature4->new(-access_key => $self->{AWSAccessKeyId},
                                          -secret_key => $self->{SecretKey});
        $signer->sign($req);

        $self->_debug_log($req->as_string());
        
        $response = $self->{UserAgent}->request($req);
        
        if ($response->is_success) { # note, 500 and 503 are NOT success :D
            $self->_debug_log($response->content);
            my $href = XMLin($response->content, ForceArray => $force_array, KeyAttr => {});
            return $href;
        } else {
            # advice from internal AWS support - most client libraries try 3 times in the face
            # of 500 errors, so ours should too
            # use exponential backoff.
		
            if ($response->code == 500 || $response->code == 503) {
                my $sleep_amount= 2 ** $try * 50 * 1000;
                $self->_debug_log("Doing sleep for: $sleep_amount");
                Time::HiRes::usleep($sleep_amount);
                next;
            }
            die("Got an error: " . $response->as_string());
        }

lib/Amazon/SQS/Simple/Base.pm  view on Meta::CPAN

    my $error = "ERROR: On calling $params->{Action}: " . $response->status_line;
    $error .= " ($msg)" if $msg;
    croak $error;
}

sub _debug_log {
    my ($self, $msg) = @_;
    return unless $self->{_Debug};
    chomp($msg);
    print {$self->{_Debug}} $msg . "\n\n";
}

 view all matches for this distribution


Amazon-SecretsManager

 view release on metacpan or  search on metacpan

lib/Amazon/SecretsManager.pm  view on Meta::CPAN

      service_url_base => AWS_SERVICE_URL_BASE,
      version          => AWS_API_VERSION,
      api              => AWS_API,
      api_methods      => \@API_METHODS,
      content_type     => 'application/x-amz-json-1.1',
      debug            => $ENV{DEBUG} // FALSE,
      %options
    }
  );
}

 view all matches for this distribution


Amb

 view release on metacpan or  search on metacpan

Amb.pm  view on Meta::CPAN

use Carp qw(confess croak);
use PadWalker;

BEGIN { *CORE::GLOBAL::die = \&dier } ;

my (%patched, %cv, @stack, $charged, $debug);
$debug = $ENV{AMB_DEBUG}||0;

sub dier
{
	CORE::die(@_) if $^S; # eval

Amb.pm  view on Meta::CPAN

		CORE::die @_;
	}

	if ( $c-> {angelic}) {
		$charged = $c;
		print "angelic/die in branch # $c->{state} at $c->{label}\n" if $debug;
		$c-> {state}++;
		goto $c-> {label};
	} else {
		print "demonic/die in branch # $c->{state} at $c->{label}\n" if $debug;
		$c-> {state} = 0;
		goto AGAIN; # that means die again
	}
}

sub after
{
	my $c = pop @stack;
	if ( $c) {
		if ( $c-> {angelic}) {
			print "angelic/after\n" if $debug;
			$c-> {state} = 0;
		} else {
			print "demonic/after\n" if $debug;
			$c-> {state}++;
			$charged = $c;
			goto $c-> {label};
		}
	}
	undef $charged;
}

sub fail($)
{
	local $Carp::CarpLevel = 3 unless $debug;
	confess "Can't call $_[0]\(\) that way";
}

sub patch
{
	my ($name, $xop, $cv, $upcontext) = @_;
	
	printf("$name: patch at COP( 0x%x)\n", $$xop) if $debug;

	my $cv_frame = $cv ? B::svref_2object($cv) : B::main_cv;

	# enter other CV's padlist
	my $savecp = B::cv_pad;

Amb.pm  view on Meta::CPAN

	$xop-> next($lab);

	# restore padlist	
	B::cv_pad( $savecp);

	if ( $debug > 1) {
		no strict;
		local $SIG{__WARN__};
		eval "*B::CV::NAME      = sub { 'fake' };" unless exists ${'B::CV'}{NAME};
		eval "*B::NV::int_value = sub { '0.0' };"  unless exists ${'B::NV'}{int_value};

Amb.pm  view on Meta::CPAN

	croak "format: amb(arg1,arg2)" if 1 != $#_;
	
	my $c;
	unless ( $charged) {
		my ($op, $cx, $up) = find_ctx('amb');
		printf("amb: 1st call at %x\n", $$op) if $debug;

		my $id;
		unless ( exists $patched{$$op}) {
			$id = patch( 'amb', $op, $cx, $up);
			$patched{$$op} = {

Amb.pm  view on Meta::CPAN

		$c = $patched{$$op};
		$c-> {state} = 0;
	} else {
		$c = $charged;
		undef $charged;
		print "amb: jump from $c->{label}\n" if $debug;
	}

	die "amb: all branches fail" if $c-> {state} > $#_;

	push @stack, $c;

Amb.pm  view on Meta::CPAN

	croak "format: demonic(arg1,arg2)" if 1 != $#_;

	my $c;
	unless ( $charged) {
		my ($op, $cx, $up) = find_ctx('demonic');
		printf("demonic: 1st call at %x\n", $op) if $debug;

		my $id;
		unless ( exists $patched{$$op}) {
			$id = patch( 'demonic', $op, $cx, $up);
			$patched{$$op} = {

Amb.pm  view on Meta::CPAN

		$c = $patched{$$op};
		$c-> {state} = 0;
	} else {
		$c = $charged;
		undef $charged;
		print "demonic: jump from $c->{label}\n" if $debug;
	}

	die "demonic: all branches succeed" if $c-> {state} > $#_;

	push @stack, $c;

 view all matches for this distribution


Ambrosia

 view release on metacpan or  search on metacpan

lib/Ambrosia/Assert.pm  view on Meta::CPAN


    assign(shift) if @_;

    no strict 'refs';
    my $package_instance = caller(0);
    if ( debug_mode($PROCESS_MAP{$$}, @_) )
    {
        *{"${package_instance}::assert"} = sub(&$) { goto &__assert; };
    }
    else
    {

lib/Ambrosia/Assert.pm  view on Meta::CPAN

sub assign
{
    $PROCESS_MAP{$$} = shift;
}

sub debug_mode
{
    my $key = shift or return 0;
    my $mode = shift;

    unless(defined $ASSERT{$key})
    {
        throw Ambrosia::error::Exception::BadParams 'First usage Ambrosia::Assert without initialize.' unless defined $mode;
        $ASSERT{$key} = lc($mode) eq 'debug';
    }
    return $ASSERT{$key};
}

1;

lib/Ambrosia/Assert.pm  view on Meta::CPAN

version 0.010

=head1 SYNOPSIS

    #foo.pm 
    use Ambrosia::Assert GLOBAL_KEY => 'debug';

    sub foo
    {
        my @params = @_;
        assert(sub {@params && $params[0] eq 'abc'}, 'invalid params in foo()');

lib/Ambrosia/Assert.pm  view on Meta::CPAN

    }

=head1 DESCRIPTION

C<Ambrosia::Assert> adds a validation method in your module.
You can on or off assert for debug.

=head1 USAGE

    use Ambrosia::Assert GLOBAL_KEY => 'debug'; #on validation
    use Ambrosia::Assert GLOBAL_KEY => 'nodebug'; #off validation

GLOBAL_KEY is any keyword, for example application name.

=head1 METHODS

 view all matches for this distribution


Amethyst

 view release on metacpan or  search on metacpan

Amethyst/Brain/Infobot/Module/Google.pm  view on Meta::CPAN



sub parse_response {
	my ($self, $response) = @_;

	$self->{_debug} = 10;

	print STDERR "Self is $self\n";

	# parse the output
	my ($HEADER, $HITS, $TRAILER, $POST_NEXT) = (1..10);

Amethyst/Brain/Infobot/Module/Google.pm  view on Meta::CPAN

	my @lines = split(/\n/, $response->content);

	foreach (@lines) {
		next unless /\S/; # short circuit for blank lines

		# print STDERR substr($_, 0, 70) . "\n" if $self->{_debug};
		print STDERR $_ . "\n" if $self->{_debug};

		if ($state == $HEADER && m/about <b>([\d,]+)<\/b>/) {
			$approx_count = $1;
			print STDERR "Found Total: $approx_count\n" ;
			$state = $HITS;

Amethyst/Brain/Infobot/Module/Google.pm  view on Meta::CPAN

			m|<p><a href=[^\s]*(http[^&>]*)[^>]*>(.*?)</a>|i) {
			my ($url, $title) = ($1, $2);
			$hit = new WWW::SearchResult();
			push(@hits, $hit);

			print STDERR "**Found HIT Line**\n" if ($self->{_debug});
			$url =~ s/(>.*)//g;
			$hit->add_url(WWW::Search::strip_tags($url));
			$title = "No Title" if ($title =~ /^\s+/);

			$hit->title(WWW::Search::strip_tags($title));
			$state = $HITS;
		} 
		elsif ($state == $HITS && m|Description:</font></span>\s*(.*)<br>|i) {
			print STDERR "**Parsing Description Line**\n" if ($self->{_debug});
			if ($hit) {
				my $desc = $1;
				$desc =~ s/<.*?>//g;
				$desc =~ s/Category.*//;
				$hit->description($desc);

Amethyst/Brain/Infobot/Module/Google.pm  view on Meta::CPAN

			else {
				print STDERR "ERROR: No hit when parsing description\n";
			}
		} 
		elsif ($state == $HITS && m@<div class=nav>@i) {
			print STDERR "**Found Last Line**\n" if ($self->{_debug});
			# end of hits
			$state = $TRAILER;
		}
		else {
			print STDERR "**No match**\n" if ($self->{_debug});
		}
	}

	return @hits;
}

 view all matches for this distribution


Amon2-Plugin-LogDispatch

 view release on metacpan or  search on metacpan

lib/Amon2/Plugin/LogDispatch.pm  view on Meta::CPAN


    # in your config.pl
    'Log::Dispatch' => {
        outputs => [
            [Screen::Color', 
                min_level => 'debug',
                name      => 'debug',
                stderr    => 1,
                color     => {
                    debug => {
                        text => 'green',
                    }
                }
            ],
        ],

 view all matches for this distribution


Amon2

 view release on metacpan or  search on metacpan

lib/Amon2.pm  view on Meta::CPAN

    return $config;
}

sub mode_name { $ENV{PLACK_ENV} }

sub debug_mode { $ENV{AMON2_DEBUG} ? 1 : 0 }

sub add_config {
    my ($class, $key, $hash) = @_; $hash or Carp::croak("missing args: \$hash");
    Carp::cluck("Amon2->add_config() method was deprecated.");

lib/Amon2.pm  view on Meta::CPAN


=item C<< MyApp->add_config() >>

DEPRECATED.

=item C<< MyApp->debug_mode() >>

B<((EXPERIMENTAL))>

This method returns a boolean value. It returns true when $ENV{AMON2_DEBUG} is true value, false otherwise.

 view all matches for this distribution


Analizo

 view release on metacpan or  search on metacpan

t/samples/mlpack-3.0.0/parse_command_line.hpp  view on Meta::CPAN

    // Otherwise just print the generalized help.
    PrintHelp();
    exit(0);
  }

  // Print whether or not we have debugging symbols.  This won't show anything
  // if we have not compiled in debugging mode.
  Log::Debug << "Compiled with debugging symbols." << std::endl;

  if (CLI::HasParam("verbose"))
  {
    // Give [INFO ] output.
    Log::Info.ignoreInput = false;

 view all matches for this distribution


Anarres-Mud-Driver

 view release on metacpan or  search on metacpan

Efun/Core/Core.pm  view on Meta::CPAN


		# System stuff

		time			=> [ 0,		T_INTEGER, ],

		debug_message	=> [ 0,		T_STRING, T_STRING, ],
		error			=> [ 0,		T_INTEGER, T_STRING, ],
		catch			=> [ 0,		T_STRING, T_UNKNOWN, ],
		shutdown		=> [ 0,		T_INTEGER, ],

		trace			=> [ 0,		T_INTEGER, T_INTEGER, ],

Efun/Core/Core.pm  view on Meta::CPAN

	package Anarres::Mud::Driver::Efun::Core::time;
	sub generate_call { "time()" }
}

{
	package Anarres::Mud::Driver::Efun::Core::debug_message;
	sub generate_call { "print STDERR $_[1], '\\n'" }
}

{
	package Anarres::Mud::Driver::Efun::Core::previous_object;

 view all matches for this distribution


( run in 1.292 second using v1.01-cache-2.11-cpan-49f99fa48dc )