ePrivacy and GPDR Cookie Consent by Cookie Consent

Finding the value passed to a function by name

Finding the value passed to a function by name 1.2

Finding the value passed to a function by name 1.2 Download Summary

  • Language: Python
  • Platform: Windows / Linux / Mac OS / BSD / Solaris
  • License: Other Free / Open Source License - Python License
  • Databases: N/A
  • Downloads: 411
  • Released: Jun 7, 2007

Finding the value passed to a function by name 1.2 Description

Sometimes inside a decorator that creates a function with a generic (*args, **kwargs) signature, you want to access a value passed for a particular parameter name to a wrapped function, but don't know whether that value will be passed as a positional or keyword argument, or whether the wrapped function defines a default value for the parameter. 

This script contains an utility function that extracts this information for you.

This function is meant to be used inside decorators, when you want to find what value will be available inside a wrapped function for a particular argument name. It handles positional and keyword arguments and takes into account default values.


Finding the value passed to a function by name 1.2 Keywords

free download

Finding the value passed to a function by name Bookmark

Hyperlink code:
Hyperlink for Forum code:

Finding the value passed to a function by name 1.2 Script Download Notice

Top 4 Download periodically updates information of Finding the value passed to a function by name 1.2 script from the developer, but some information may be slightly out-of-date.

Our script download links are directly from our mirrors or publisher's website. Finding the value passed to a function by name 1.2 torrent files or shared files from free file sharing and free upload services, including Rapidshare, MegaUpload, YouSendIt, MailBigFile, DropSend, HellShare, HotFile, FileServe, MediaMax, zUpload, MyOtherDrive, SendSpace, DepositFiles, Letitbit, LeapFile, DivShare or MediaFire, are not allowed!

Extract a inner function from a class

This function can extract a inner function from a class or a function. It may be useful when writing a unit test code. ...
Python

Flexible enumerate

... enumerate() script adds an additional start argument to the built-in enumerate function. ...
Python

Function emulation using call

... a simple but useful class that emulates a function to gracefully permit latent assignment. In other words, you can use the emulating class as a valid function in assignments with the ability to later associate a function to perform the actual operations. ...
Python

Function composition

This script contains two classes that show two styles of function composition. The difference is only when the second function (g) returns a tuple. compose function passes the results of g as a tuple, mcompose treats ... as extra args to f(there is no standard functional behavior here to follow).
Python

Timeit module wrapper

This script contains a simple, easy to use wrapper function for doing quick tests of your functions using the timeit module.The timeit module provides an easy way of testing the performance of your Python code by running it in many iterations and averaging the timings. However it is not very obvious how ...
Python