Skip to main content

Vakanties.nl pypi package

Project description

Vaknl

Package for working with Images. Contains the default Image dataclass and methods to get and upload images to gcp.

Prerequisites

These modules dependant on two things. Firstly the vaknl-gcp package for working with GCP. Secondly the environment variable GOOGLE_CLOUD_PROJECT a.k.a. gcp project id.

Images

class Image:

@dataclass
class Image:
    url: str  
    bucket_url: str  
    width: int  
    height: int  
    bytes_size: int  

get_image(image_url, auth=None):

Gets an images from the internet with a retry fall back of 3 times.

returns width, heigth, size, data

upload_image_to_storage(id, bucket_name, image_url):

Gets images from the internet and uploads it to storage.

returns width, heigth, byte_size, blob_url

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vaknl-image-1.1.4.tar.gz (2.1 kB view details)

Uploaded Source

Built Distribution

vaknl_image-1.1.4-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file vaknl-image-1.1.4.tar.gz.

File metadata

  • Download URL: vaknl-image-1.1.4.tar.gz
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

File hashes

Hashes for vaknl-image-1.1.4.tar.gz
Algorithm Hash digest
SHA256 77fc9c0ab8cd6a0e6599a5a1f62b80ef8445e648adfadc9995607fd90a3e6f43
MD5 fb3c0c24b80d3e93255b0b0e0551e505
BLAKE2b-256 a9dedae17f1867c2434fbad035e7666784e2768653792ecc86b4c63a877731ff

See more details on using hashes here.

File details

Details for the file vaknl_image-1.1.4-py3-none-any.whl.

File metadata

  • Download URL: vaknl_image-1.1.4-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

File hashes

Hashes for vaknl_image-1.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 31c6c47c675f1065ff5f2271a1b798f47e4648bce817ff27fe07e741d9ebb8a0
MD5 15f3df061384cc5b1c5f2838d154877b
BLAKE2b-256 ed77c70a827482d49c3b87c731d82b64a891f0b86f5be73f69d0c6250c103d5b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page