Skip to main content

Module to simplify usage of WeedFS in python.

Project description

Class to simplify communication with Weed-FS

Installation

From PyPI:

pip install pyseaweed

Tests

Install dependencies:

pip install -r test_requirements.txt

Run tests:

python setup.py tests

Or using nose:

nosetests

Note

Functional tests assumes that there is WeedFS master running on localhost:9333 (defaults). If it’s not then there will be errors in tests.

Usage

Upload file to weedFS

from pyseaweed import WeedFS

# File upload
w = WeedFS("localhost", 9333) # weed-fs master address and port
fid = w.upload_file("n.txt") # path to file

# Get file url
file_url = w.get_file_url(fid)

# Delete file
res = w.delete_file(fid)
# res is boolean (True if file was deleted)

Project details


Download files

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

Files for pyseaweed, version 1.0.0
Filename, size File type Python version Upload date Hashes
Filename, size pyseaweed-1.0.0.zip (12.1 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page