Skip to main content

Documentation – GitHub

A simple package

import fesenjoon

drive = fesenjoon.Drive()
# NOTE: URI params must be strings not integers

gist_uri = 'https://api.github.com/gists{/gist_id}'
t = URITemplate(gist_uri)
print(t.expand(gist_id='123456'))
# => https://api.github.com/users/sigmavirus24/gists/123456

# or
print(expand(gist_uri, gist_id='123456'))

# also
t.expand({'gist_id': '123456'})
print(expand(gist_uri, {'gist_id': '123456'}))

Where it might be useful to have a class

from fesenjoon import Drive
drive = Drive()

When the module containing this class is loaded, GitHubUser.url is evaluated and so the template is created once. It’s often hard to notice in Python, but object creation can consume a great deal of time and so can the re module which uritemplate relies on. Constructing the object once should reduce the amount of time your code takes to run.

Installing

pip install fesenjoon

License

GPL license

Metadata

Release files for fesenjoon 0.0.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fesenjoon 0.0.5
File Size Uploaded
fesenjoon-0.0.5.tar.gz 18.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for fesenjoon 0.0.5
File Interpreter ABI Platform
fesenjoon-0.0.5-py3-none-any.whl Python 3 none any Details

Total release size: 37.6 kB

Release files / fesenjoon-0.0.5.tar.gz

Download URL fesenjoon-0.0.5.tar.gz
Size 18.6 kB
Tags Source
SHA-256 checksum
How to use checksums
87214f58ee3067a758cfa14c455bf11cc0759f559fda6e0a3d41c65a37662bab
BLAKE2b-256 checksum
How to use checksums
b3a412dbd0ff615522205b6fb787402c23c2b01fdd772a28b973dd5281a18dd1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.6

Release files / fesenjoon-0.0.5-py3-none-any.whl

Download URL fesenjoon-0.0.5-py3-none-any.whl
Size 19.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e8dc366c19c218116dd5c05facfc3ed988592fdad2a89468ca911785fa996192
BLAKE2b-256 checksum
How to use checksums
bacf15fb47a161190c6903fd86a5a10fdab32acfeb4690df5004c29e4dce367a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.10.6

Release history Release notifications | RSS feed

This release

0.0.5 This release

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page