Coder Social home page Coder Social logo

dcsil / lampsz-app Goto Github PK

View Code? Open in Web Editor NEW
2.0 0.0 0.0 1.32 MB

Source code for Lampsz influencer marketing platform

Home Page: https://lampsz.herokuapp.com/

Python 45.66% HTML 0.85% CSS 0.07% TypeScript 51.96% JavaScript 0.33% Shell 0.71% Dockerfile 0.40% Procfile 0.03%
f2022

lampsz-app's Introduction

Lampsz-App

Source code for Lampsz platform

Architecture Diagram

architecture_diagram

Development Setup

Make sure to have the following on your host:

  • Python 3.10
  • Node.js 18 and npm
  • Poetry
  • PostgresSQL

For UNIX system, also install the following packages:

  • build-essential
  • libpq-dev

Some Django settings are loaded through environment variables. For local development, copy the .env.example file to .env file in the project directory and fill in the content.

Also obtain the client_secret.json file from Google developer console and update the GOOGLE_CLIENT_SECRETS field with the content of the file.

Also obtain API KEY from Google developer console and update the GOOGLE_API_KEY field with the string of the api key

To get started with local development:

  1. Install required Python dependencies:

     $ poetry install
    
  2. Install frontend Javascript dependencies:

     $ npm install
    
  3. Build frontend files:

     $ npm run dev
    
  4. Activate virtual environment:

     $ poetry shell
    
  5. Export environment variable for Django settings:

     $ export DJANGO_SETTINGS_MODULE=lampsz.settings.local
     $ export OAUTHLIB_RELAX_TOKEN_SCOPE=1
     $ export OAUTHLIB_INSECURE_TRANSPORT=1
    
  6. Apply Django database migrations:

     $ python manage.py migrate
    
  7. To start django development server:

     $ python manage.py runserver
    

And you can now access the home page by going to 127.0.0.1:8000

To run Django tests with coverage:

  $ coverage run --source='.' manage.py test

Linters

After installing the required packages through the steps above, the pre-configured linters can be run.

Code Style Enforcement

Running code style enforcement with flake8:

$ flake8 --config=setup.cfg

Type checks

Running type checks with mypy:

$ mypy lampsz

Pre-commit

All the linters have been configured into git pre-commit hooks. To utilize this, run

$ pre-commit install

And the hook should be run everytime when you commit.

lampsz-app's People

Contributors

larryworm1127 avatar matticyang avatar zekai128 avatar dependabot[bot] avatar

Stargazers

 avatar  avatar

lampsz-app's Issues

This repo is nearing usage of GitHub Actions minutes

This repo is nearing the limit on Actions usage.

We have a limited number of GitHub Actions Runners. To ensure one team does not monopolize those workers we impose a monthly usage limit.
We impose a limit of 500 minutes per month.

You repo has currently used 436 minutes out of the allowed 500.
Once you reach 300 used minutes, we reach out to warn you that your workflows will be disabled at the 500 limit until the next month.

Please see if you can reduce your CI usage.
This could include caching, optimizing your CI flow, and pushing commits in bulk rather than 1 at a time (will run CI once for the batch instead of for each commit).

This repo is nearing usage of GitHub Actions minutes

This repo is nearing the limit on Actions usage.

We have a limited number of GitHub Actions Runners. To ensure one team does not monopolize those workers we impose a monthly usage limit.
We impose a limit of 500 minutes per month.

You repo has currently used 436 minutes out of the allowed 500.
Once you reach 300 used minutes, we reach out to warn you that your workflows will be disabled at the 500 limit until the next month.

Please see if you can reduce your CI usage.
This could include caching, optimizing your CI flow, and pushing commits in bulk rather than 1 at a time (will run CI once for the batch instead of for each commit).

This repo is nearing usage of GitHub Actions minutes

This repo is nearing the limit on Actions usage.

We have a limited number of GitHub Actions Runners. To ensure one team does not monopolize those workers we impose a monthly usage limit.
We impose a limit of 500 minutes per month.

You repo has currently used 436 minutes out of the allowed 500.
Once you reach 300 used minutes, we reach out to warn you that your workflows will be disabled at the 500 limit until the next month.

Please see if you can reduce your CI usage.
This could include caching, optimizing your CI flow, and pushing commits in bulk rather than 1 at a time (will run CI once for the batch instead of for each commit).

Disabling GitHub Actions

Congratulations on finishing the course!

To make sure we have enough GitHub Actions minutes for the next term, we have automatically disabled your repository's actions.

Feel free to make this repo public or fork to your own org, but we do ask that you leave a copy in the DCSIL org :)

Some workflows have no defined timeouts or are not using ubuntu-latest

This repo has workflows that have no defined timeouts and/or are not using ubuntu-latest.

We use self hosted runners to avoid overage costs associated with GitHub Actions. However, we don't have a lot of workers to handle all of the load.
To ensure a single build doesn't spend hours and monopolize our workers, we limit each job to 20 minutes.
Please add a timeout to your jobs. We will disable your actions until you add them.

Your build may also be missing ubuntu-latest in the runs-on field.

Docs: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#jobsjob_idtimeout-minutes
Example:

jobs:
  build:
    runs-on: ubuntu-latest # This is required
    timeout-minutes: 20 # Add this line here

Affected Workflows:

Workflow Path Job Re-enable
.github/workflows/ci.yml deploy https://github.com/dcsil/Lampsz-App/actions/workflows/ci.yml

Some workflows have no defined timeouts or are not using ubuntu-latest

This repo has workflows that have no defined timeouts and/or are not using ubuntu-latest.

We use self hosted runners to avoid overage costs associated with GitHub Actions. However, we don't have a lot of workers to handle all of the load.
To ensure a single build doesn't spend hours and monopolize our workers, we limit each job to 20 minutes.
Please add a timeout to your jobs. We will disable your actions until you add them.

Your build may also be missing ubuntu-latest in the runs-on field.

Docs: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#jobsjob_idtimeout-minutes
Example:

jobs:
  build:
    runs-on: ubuntu-latest # This is required
    timeout-minutes: 20 # Add this line here

Affected Workflows:

Workflow Path Job Re-enable
.github/workflows/ci.yml build https://github.com/dcsil/Lampsz-App/actions/workflows/ci.yml

Disabling GitHub Actions

Congratulations on finishing the course!

To make sure we have have workers for the next term, we have automatically disabled your repository's actions.

Feel free to make this repo public or fork to your own org, but we do ask that you leave a copy in the DCSIL org :)

This repo is nearing usage of GitHub Actions minutes

This repo is nearing the limit on Actions usage.

We have a limited number of GitHub Actions Runners. To ensure one team does not monopolize those workers we impose a monthly usage limit.
We impose a limit of 500 minutes per month.

You repo has currently used 436 minutes out of the allowed 500.
Once you reach 300 used minutes, we reach out to warn you that your workflows will be disabled at the 500 limit until the next month.

Please see if you can reduce your CI usage.
This could include caching, optimizing your CI flow, and pushing commits in bulk rather than 1 at a time (will run CI once for the batch instead of for each commit).

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.