Giter VIP home page Giter VIP logo

beneath-stream's Introduction

Beneath SDK Demo

This repo starts to build streaming pipelines with the Beneath Python SDK, a hosted streaming solution for data engineers and data scientists. For setup, I signed up at beneath.dev and created a secret token.

Installing the SDK and Setup

First, create a secret in the Console. Then:

  • pip3 install -r requirements.txt
  • beneath auth [YOUR_SECRET]. NOTE: This is needed for the CLI, but a secret can be passed in with the Python SDK.

To run in Docker (preferred):

  • make build then make run
  • This puts you in bash. cd beneath-stream and python main.py runs the script. NOTE: This can be improved by successfully mounting the beneath-stream folder as a volume. This isn't done yet so it's a bit clunky right now.

Further setup:

  • Create a .env file copying secrets_example.env, updating to your Beneath secret. NOTE: This seems to be quirky, explained below (in reference to secrets.txt)

Notes:

  • On Mac: Python 3.9.0
  • In Docker ubuntu container: Python 3.7.5

Suggestions

  • Schema for stream to be an object of some sort instead of string; a string might be more prone to types or syntax errors.

Issues

MacOS related:

  • On MacOS, need to run xcode-select --install to avoid the error documented in beneath_sdk_error.txt
  • When creating a project from the commandline on a Mac, ran into error documented in cli_create_project_error.txt. This also occurs when trying to authenticate via Python SDK. No solution found.

Running in Docker (on ubuntu 18.04 image):

  • Running on Docker, I get the issue in beneath_sdk_get_secret_docker.txt. However, this is resolved by copying the secret.txt file to /root/.beneath/secret.txt in the container.
  • When running the script I get ModuleNotFoundError: No module named 'importlib_metadata'. This is solved by installing importlib-metadata. This is documented in beneath_dependency.txt
  • It's not immediately clear when I need to start the client; I run await stream.write() and get the Client not started error documented in client_error.txt - this is in the API Docs on the stream, but not in the general docs. NOTE: UNRESOLVED

beneath-stream's People

Contributors

sarahmk125 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.