Skip to content
💧Osmosis IPFS Driver Implementation
Python Makefile Shell
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
osmosis_ipfs_driver
tests
.bumpversion.cfg
.gitignore
.travis.yml
CHANGELOG.md
CODEOWNERS
LICENSE
MANIFEST.in
Makefile
README.md
bumpversion.sh
logging.yaml
requirements_dev.txt
setup.cfg
setup.py
tox.ini

README.md

banner

osmosis-ipfs-driver

💧 Osmosis IPFS Driver Implementation oceanprotocol.com

Build Status PyPI


Table of Contents


Setup

Install the osmosis ipfs driver and set ipfs gateway envvar

pip install osmosis-ipfs-driver
export IPFS_GATEWAY=https://gateway.ipfs.io

Instantiate an Osmosis instance and resolve an ipfs url

from osmosis_driver_interface.osmosis import Osmosis
url = "ipfs://ZnOfotxMMnLTXCCW0GPVYT8gtEugghgD8Hgz"
osm = Osmosis(url)  # the proper osmosis driver is loaded automatically to match the url

# Resolve the url
download_url = osm.data_plugin.generate_url(url)

Code Style

Information about our Python code style is documented in the python-developer-guide and the python-style-guide.

Testing

Automatic tests are setup via Travis, executing tox. Our tests use the pytest framework.

New Version

The bumpversion.sh script helps to bump the project version. You can execute the script using as first argument {major|minor|patch} to bump accordingly the version.

License

Copyright 2019 Ocean Protocol Foundation Ltd.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
You can’t perform that action at this time.