Skip to main content

A modular toolkit for analytics.

Project description

# newslynx

the API and SousChefs that Power Newslynx.

## (Re)Setting up the dev environment

  • Install newslynx, prefrerably in a virtual environment.

` pip install newslynx `

  • (re)create a postgresql database

` dropdb newslynx createdb newslynx `

  • fill out [example_config/config.yaml](example_config/config.yaml) and move it to ~/.newslynx/config.yaml

  • modify default recipes and tags in [example_config/defaults/recipes/](example_config/defaults/recipes/) and [example_config/defaults/tags/](example_config/defaults/tags/), respectively. These tags and recipes will be created everytime a new organization is added.

  • initialize the database:

` newslynx init `

  • populate with sample data

` newslynx gen_random_data `

  • start the server in debug mode

` newslynx runserver -d `

## TODO

  • [x] Migrate common utilites from other repos into single repo.

  • [x] Create Database Schema / Models

  • [x] Create Blueprint-based app workflow

  • [x] Re-implement OAuth endpoints

  • [x] Implement Facebook OAuth

  • [x] Re-implement User / Login API

  • [x] Implement Org API

  • [x] Re-implement Settings API

  • [x] Re-implement Events API
    • [x] Implement Postgres-based search

  • [x] Re-implement Things API (aka Articles)
    • [x] Implement Postgres-based search

  • [x] Re-implement Tags API

  • [x] Write out SousChefs JSONSchema

  • [x] Write out initial schemas:
    • [x] article

    • [x] twitter-list

    • [x] twitter-user

    • [x] facebook-page

  • [x] Write out default recipes + tags:
    • [x] article

    • [x] twitter-list

    • [x] twitter-user

    • [x] facebook-page

    • [x] promotion impact tag

  • [x] Update create org endpoint to generate default recipes + tags.

  • [x] Implement SousChefs API

  • [x] Implement Recipes API

  • [ ] Implement Thing Creation API

  • [ ] Implement Event Creation API

  • [ ] Implement Metrics API:
    • [x] Figure out how to use tablefunc for pivot tables.

  • [ ] Implement Reports API (Are these just metrics?)
    • [ ] Figure out how to use pypostgresql for custom postgres functions.

  • [ ] Implement Task Queue (Celery, Redis?)

  • [ ] Implement Modular SousChefs

  • [x] Figure out how best to use OAuth tokens in SousChefs. Ideally these should not be exposed to users.

  • [x] Implement API client

  • [ ] Re-implement SousChefs
    • [ ] RSS Feeds => Thing

    • [ ] Google Analytics => Metric

    • [ ] Google Alerts => Event

    • [ ] Social Shares => Metric

    • [ ] Homepage Promotions => Metric

    • [ ] Twitter Promotions => Metric

    • [ ] Facebook Promotions => Metric

    • [ ] Twitter List => Event

    • [ ] Twitter User => Event

    • [ ] Facebook Page => Event

    • [ ] Reddit => Event

    • [ ] HackerNews => Event

  • [ ] Implement New SousChefs
    • [ ] IFTTT integrations
      • [ ] Wordpress Publish => Thing

      • TK

    • [ ] Regex Thing URL => Tag

    • [ ] Search Things => Tag

    • [ ] Meltwater Emails => Event

    • [ ] Newsletter Email Promotions => Metric

  • [x] Implement Recipe scheduler

  • [ ] Implement Admin Panel

  • [ ] Migrate Core Beta Users (Lauren, Lindsay, Blair)

  • [ ] Automate Deployment

  • [ ] App Integration

  • [ ] Document, Document, Document

## References

### API Design

### Crosstab in Postgres * [http://www.postgresonline.com/journal/archives/14-CrossTab-Queries-in-PostgreSQL-using-tablefunc-contrib.html](http://www.postgresonline.com/journal/archives/14-CrossTab-Queries-in-PostgreSQL-using-tablefunc-contrib.html)

### filling in zeros for a timezeries * [http://stackoverflow.com/questions/346132/postgres-how-to-return-rows-with-0-count-for-missing-data]

### fetching column names from table * [http://www.postgresql.org/message-id/AANLkTilsjTAXyN5DghR3M2U4c8w48UVxhov4-8igMpd1@mail.gmail.com](http://www.postgresql.org/message-id/AANLkTilsjTAXyN5DghR3M2U4c8w48UVxhov4-8igMpd1@mail.gmail.com)

### timeseries tips * [http://no0p.github.io/postgresql/2014/05/08/timeseries-tips-pg.html](http://no0p.github.io/postgresql/2014/05/08/timeseries-tips-pg.html)

### Getting bigger with flask (+ dynamic subdomains): * [http://maximebf.com/blog/2012/11/getting-bigger-with-flask/#.VVYvUZNVhBc](http://maximebf.com/blog/2012/11/getting-bigger-with-flask/#.VVYvUZNVhBc)

### Nonblocking with flask, gevent, + psycopg2 * [https://github.com/kljensen/async-flask-sqlalchemy-example](https://github.com/kljensen/async-flask-sqlalchemy-example)

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

newslynx-0.0.8.tar.gz (64.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

newslynx-0.0.8.macosx-10.10-intel.exe (195.9 kB view details)

Uploaded Source

File details

Details for the file newslynx-0.0.8.tar.gz.

File metadata

  • Download URL: newslynx-0.0.8.tar.gz
  • Upload date:
  • Size: 64.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for newslynx-0.0.8.tar.gz
Algorithm Hash digest
SHA256 017f9b048a823682ac7e3c2bb9ecc4b06ef1adb60deb8799ce90ddc1c483fb17
MD5 8903e740971bbc9be933fdc7e569791b
BLAKE2b-256 2727c267a39601e5fd5be21839fa3092f9c65888d140e0c523bf43ebd43774f5

See more details on using hashes here.

File details

Details for the file newslynx-0.0.8.macosx-10.10-intel.exe.

File metadata

File hashes

Hashes for newslynx-0.0.8.macosx-10.10-intel.exe
Algorithm Hash digest
SHA256 84d0608ad201a98c06101fbea22c3ef6c9fbb8ac53285024020f3256c29cf655
MD5 0613573db693487363f29e3c9805107d
BLAKE2b-256 3fabeca5ffbe76714ce52dedbbbd1eca325c9f961b5215dda526bf0ccf77bfa1

See more details on using hashes here.

Supported by

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