Coder Social home page Coder Social logo

encode-dcc / regulome-encoded Goto Github PK

View Code? Open in Web Editor NEW
1.0 18.0 3.0 126.85 MB

Temp repo for regulome development

License: MIT License

JavaScript 42.22% Makefile 0.01% Python 30.64% Mako 0.04% Shell 0.36% HTML 2.19% SCSS 24.49% Dockerfile 0.06%

regulome-encoded's Introduction

Regulome DB

Running app using docker compose

1. Running RegulomeDB using docker compose

2. Frontend development using docker compose

  • In Docker Desktop, find the running docker compose (should be named as "regulome-encoded"), there will be one docker container runing inside. Select the "CLI" to open the terminal:

    • npm run dev
  • The above command runs continually in the terminal window and watches for changes in Javascript and SCSS files, rebuilding the bundles as you make changes.

3. Running test using docker compose

  • Choose the regulome service and run the specific test command, for example:
    • docker-compose run regulome npm test

Creating a demo machine

  • Install dependency boto3 first then deploy:

    pip3 install boto3
    python src/encoded/commands/deploy.py --profile-name regulome
  • The demo link uses this format: https://[instance_name].demo.regulomedb.org/regulome-search/

  • Deploy script help (how to specify name, instance size, etc):

    python src/encoded/commands/deploy.py --help

  • For all options, including setting up ES clusters (needed for full production). After indexing (currently 8+hrs) the machine can be downsized at AWS to an m4.2xlarge, unless you are planning to submit significant data to it.

Linting your code within your code editor

To set up linting with Sublime Text 3 or Visual Studio Code, first install the linters:

pip3 install flake8
npm install -g eslint
npm install -g eslint-plugin-react

โš ๏ธ Note: You don't have to use Sublime Text 3 but you must ensure that linting in your editor behaves as it does in Sublime Text 3.

Sublime Text 3

After first setting up Package Control (follow install and usage instructions on site), use it to install the following linting packages in Sublime Text 3:

Sublime Linting with pyenv To get Sublime to lint Python code using pyenv you must add the python version and paths and python_paths to your Sublime Linter Preferences. In Sublime Text, navigate to the user linter preferences:

  • Sublime Preferences -> Package Settings -> Sublime Linter -> Settings-User

  • Add the following (modify existing preference settings file or add this entire JSON object below if the file is blank):

{
    "user": {
        "@python": 3.8,
        
        "paths": {
            "linux": [],
            "osx": [
                "/Users/YOURUSERNAME/.pyenv/versions/3.8.10/bin/",
                "/Users/YOURUSERNAME/.pyenv/versions/2.7/bin/"
            ],
            "windows": []
        },
        "python_paths": {
            "linux": [],
            "osx": [
                "/Users/YOURUSERNAME/.pyenv/versions/3.8.10/bin/python3",
                "/Users/YOURUSERNAME/.pyenv/versions/2.7/bin/python"
            ],
            "windows": []
        }
    }
}
  • Restart Sublime

Visual Studio Code

Go to the Visual Studio Code marketplace and install these extensions:

  • ESLint
  • Python
  • Sass

Check versions and linting

Versions

  • python3 --version returns Python 3.8.10 (or variant like 3.8.x)
  • node --version returns v10.15.0 (or variant like v6.x.y)

Linting check

  • Python: Open Sublime, make a change to a Python file, make an intentional syntax error (no : at the end an if evaluation). Warnings and errors should show on the left side of the line.

  • JavaScript: Make a syntax error, or style error, in a JS file. Warnings and errors should show on the left side of the line.

regulome-encoded's People

Contributors

aditin14 avatar bek avatar caseylitton avatar chloetanlimco avatar cricketsloan avatar davisagli avatar emro avatar euriehong avatar forresttanaka avatar gabdank avatar hitz avatar jahilton avatar jmdavidson avatar kakaly avatar katerose avatar keenangraham avatar kilodalton avatar kjain21 avatar lrowe avatar mingjiecn avatar nikhilrp avatar ottojolanki avatar paul-sud avatar pedrohr avatar rojeen avatar strattan avatar submarinesammitch avatar vsmalladi avatar yunhailuo avatar zoldello avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

regulome-encoded's Issues

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.