This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo add-apt-repository "deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main" | |
| wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - | |
| sudo apt-get update | |
| sudo apt-get install postgresql-9.6 | |
| sudo apt-get install postgresql-9.6-postgis-2.3 | |
| sudo apt-get install postgresql-9.6-pgrouting | |
| sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable | |
| sudo apt-get update |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1. What is the output of this C code? | |
| #include <stdio.h> | |
| int main() | |
| { | |
| int a = 10; | |
| double b = 5.6; | |
| int c; | |
| c = a + b; | |
| printf("%d", c); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| I’ve been a professional software/web developer for 2.5 years. I have worked on small (20-30) and build the product for differnt organisations. | |
| I’m glad I did because it turns out that I love it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Time: 45 Min | |
| Read the below passage carefully and answer the questions: | |
| At a small company, parking spaces are reserved for the top executives: CEO, president, vice president, secretary, and treasurer with the spaces lined up in that order. The parking lot guard can tell at a glance if the cars are parked correctly by looking at the color of the cars. The cars are yellow, green, purple, red, and blue, and the executives names are Alice, Bert, Cheryl, David, and Enid. | |
| * The car in the first space is red. | |
| * A blue car is parked between the red car and the green car. | |
| * The car in the last space is purple. | |
| * The secretary drives a yellow car. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Account: | |
| Register User: | |
| -------------------------- | |
| Method: POST | |
| End Point: /accounts/user/ | |
| data = { | |
| "name": "", | |
| "email": "", | |
| "password": "", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1. Inventory: | |
| POST: /inventory/ | |
| PATCH: /inventory/<id> | |
| DELETE: /inventory/<id> | |
| GET: /inventory/ | |
| { | |
| "id" : "", | |
| "name": "", | |
| price : | |
| quantity: "" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Api Doc | |
| ---------------------------------- | |
| login: | |
| 1. http://localhost:8000/accounts/login/ | |
| { | |
| "password": "", | |
| "username": "" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### Solr Install ### | |
| Install pysolr and django-haystack and set up django-haystack. Setup for haystack is pretty straight forward: | |
| https://django-haystack.readthedocs.org/en/v1.2.7/tutorial.html | |
| Make sure you follow the haystack instructions for the correct version of haystack that you installed, | |
| as some of the setting variables are different depending on the version. | |
| # SSH into the server that you want to install Solr on |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from rest_framework.views import exception_handler | |
| def custom_exception_handler(exc): | |
| """ | |
| Custom exception handler for Django Rest Framework that adds | |
| the `status_code` to the response and renames the `detail` key to `error`. | |
| """ | |
| response = exception_handler(exc) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Logging settings for django projects, works with django 1.5+ | |
| # If DEBUG=True, all logs (including django logs) will be | |
| # written to console and to debug_file. | |
| # If DEBUG=False, logs with level INFO or higher will be | |
| # saved to production_file. | |
| # Logging usage: | |
| # import logging | |
| # logger = logging.getLogger(__name__) | |
| # logger.info("Log this message") |
NewerOlder