4337 links
  • Arnaud's links
  • Home
  • Login
  • RSS Feed
  • ATOM Feed
  • Tag cloud
  • Picture wall
  • Daily
Links per page: 20 50 100
◄Older
page 2 / 5
Newer►
97 results tagged python x
  • Python logging - under the hood
    30 novembre 2020 à 15:55:54 UTC+1 - permalink - archive.org - https://blog.urbanpiper.com/understanding-python-logging-library/
    log python
  • Rate limiting using Python and Redis
    14 novembre 2020 à 15:08:34 UTC+1 - permalink - archive.org - https://www.hackdoor.io/articles/rate-limiting-using-python-and-redis-9b7dbce8c7a5
    python rate ratelimiter
  • thumbnail
    73 Examples to Help You Master Python's f-strings
    14 novembre 2020 à 15:03:10 UTC+1 - permalink - archive.org - https://miguendes.me/73-examples-to-help-you-master-pythons-f-strings
    python string
  • Time zones | Django documentation | Django
    6 novembre 2020 à 17:55:45 UTC+1 - permalink - archive.org - https://docs.djangoproject.com/en/3.1/topics/i18n/timezones/
    django python timezone
  • thumbnail
    python - Displaying a timedelta object in a django template - Stack Overflow

    Here's my filter code

    from django import template

    register = template.Library()

    @register.filter()
    def smooth_timedelta(timedeltaobj):
    """Convert a datetime.timedelta object into Days, Hours, Minutes, Seconds."""
    secs = timedeltaobj.total_seconds()
    timetot = ""
    if secs > 86400: # 60sec 60min 24hrs
    days = secs // 86400
    timetot += "{} days".format(int(days))
    secs = secs - days*86400

    if secs > 3600:
        hrs = secs // 3600
        timetot += " {} hours".format(int(hrs))
        secs = secs - hrs*3600
    
    if secs > 60:
        mins = secs // 60
        timetot += " {} minutes".format(int(mins))
        secs = secs - mins*60
    
    if secs > 0:
        timetot += " {} seconds".format(int(secs))
    return timetot

    Then in my template I did

    {% load smooth_timedelta %}

    {% timedeltaobject|smooth_timedelta %}

    29 octobre 2020 à 10:25:50 UTC+1 - permalink - archive.org - https://stackoverflow.com/questions/16348003/displaying-a-timedelta-object-in-a-django-template
    django filter python
  • Note: python natural sort

    def atoi(text):
    return int(text) if text.isdigit() else text

    def natural_keys(text):
    return [ atoi(c) for c in re.split(r'(\d+)', text) ]

    my_list.sort(key=natural_keys)

    9 octobre 2020 à 15:01:43 UTC+2 - permalink - archive.org - https://links.infomee.fr/?6OC8rw
    python sort
  • Everything You Need to Know About Python's Namedtuples
    4 octobre 2020 à 17:03:53 UTC+2 - permalink - archive.org - https://miguendes.me/everything-you-need-to-know-about-pythons-namedtuples-ckfim70u102jbots197jn0zmh#why-should-i-use-namedtuples
    data namedtuple python type
  • typing — Support for type hints — Python 3.8.6 documentation
    4 octobre 2020 à 16:50:14 UTC+2 - permalink - archive.org - https://docs.python.org/3/library/typing.html
    python typing
  • thumbnail
    Making Concurrent HTTP requests with Python AsyncIO | LAAC Technology
    4 octobre 2020 à 16:49:58 UTC+2 - permalink - archive.org - https://www.laac.dev/blog/concurrent-http-requests-python-asyncio/
    async python
  • thumbnail
    simple-term-menu · PyPI

    Au top pour faire des petits helper en cmd line

    2 octobre 2020 à 15:26:36 UTC+2 - permalink - archive.org - https://pypi.org/project/simple-term-menu/
    interactif menu python
  • thumbnail
    Primer on Python Decorators – Real Python
    17 septembre 2020 à 11:30:06 UTC+2 - permalink - archive.org - https://realpython.com/primer-on-python-decorators/#debugging-code
    decorator python
  • Note: str to bool

    from distutils.util import strtobool

    bool(strtobool('true'))

    FOO = bool(strtobool(os.environ['FOO']))

    7 septembre 2020 à 11:52:44 UTC+2 * - permalink - archive.org - https://docs.python.org/3/distutils/apiref.html#distutils.util.strtobool
    boolean python
  • Benchmarks - FastAPI
    2 septembre 2020 à 14:51:05 UTC+2 - permalink - archive.org - https://fastapi.tiangolo.com/benchmarks/
    async fastapi python web
  • thumbnail
    How to hide output of subprocess in Python 2.7 - Stack Overflow

    retcode = subprocess.call(['echo', 'foo'], stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT)

    30 juillet 2020 à 17:00:46 UTC+2 * - permalink - archive.org - https://stackoverflow.com/questions/11269575/how-to-hide-output-of-subprocess-in-python-2-7
    null python stdout
  • Welcome to Click — Click Documentation (7.x)
    8 juillet 2020 à 11:54:37 UTC+2 - permalink - archive.org - https://click.palletsprojects.com/en/7.x/
    arg python
  • JSON Schema | The home of JSON Schema
    4 juin 2020 à 10:41:39 UTC+2 - permalink - archive.org - https://json-schema.org/
    json python validation
  • pytz - World Timezone Definitions for Python — pytz 2014.10 documentation
    29 mai 2020 à 10:52:27 UTC+2 - permalink - archive.org - http://pytz.sourceforge.net/
    python timezone
  • Logging Cookbook — Python 3.8.3rc1 documentation
    14 mai 2020 à 09:41:12 UTC+2 - permalink - archive.org - https://docs.python.org/3/howto/logging-cookbook.html
    cookbook log python
  • Apache Hadoop Amazon Web Services support – Working with IAM Assumed Roles
    23 avril 2020 à 16:00:22 UTC+2 - permalink - archive.org - https://hadoop.apache.org/docs/current/hadoop-aws/tools/hadoop-aws/assumed_roles.html#AccessDeniedException_.2B_AmazonDynamoDBException
    assume hadoop python role spark
  • Apache Hadoop Amazon Web Services support – Working with IAM Assumed Roles
    22 avril 2020 à 17:23:26 UTC+2 - permalink - archive.org - https://hadoop.apache.org/docs/current/hadoop-aws/tools/hadoop-aws/assumed_roles.html
    assume aws hadoop python role spark
Links per page: 20 50 100
◄Older
page 2 / 5
Newer►
Shaarli - The personal, minimalist, super-fast, database free, bookmarking service by the Shaarli community - Help/documentation