Skip to content

shizomanya/python-project-lvl3

Repository files navigation

Page Analyzer

Analyze specified pages for SEO suitability.

Hexlet tests and linter status:

Actions Status Python CI

AboutInstallationUsage

Table of Contents

PAGE ANALYZER

About:

Page Analyzer is a web application that checks web pages for SEO suitability. By running the check, you can get basic information from the main page of the site.

Requirements:

App developed with:

Makefile commands:

Install poetry project: make install

Install poetry project and start postgresql server: make build

Run flask app: make dev

Start gunicorn server: make start

Installation:

Python

Before installing the package make sure you have Python version 3.10 or higher installed:

>> python --version
Python 3.10.12

Poetry

The project uses the Poetry dependency manager. To install Poetry use its official instruction.

PostgreSQL

As database the PostgreSQL database system is being used. You need to install it first. You can download the ready-to-use package from official website or use Homebrew:

>> pip install postgresql

Application

To use the application, you need to clone the repository to your computer. This is done using the git clone command. Clone the project:

>> git clone https://github.com/shizomanya/python-project-lvl3.git && cd python-project-lvl3

Then you have to install all necessary dependencies:

>> make install

Create .env file in the root folder and add following variables:

DATABASE_URL = postgresql://{provider}://{user}:{password}@{host}:{port}/{db}
SECRET_KEY = '{your secret key}'

Run commands from database.sql to create the required tables.


Usage

Start the gunicorn Flask server by running:

make start

By default, the server will be available at http://0.0.0.0:8000.

It is also possible to start it local in development mode with debugger active using:

make dev

The dev server will be at http://127.0.0.1:5000.

How to use this App:

  1. Open the main page of the application.
  2. Enter the address of the web page you want to check.
  3. Run the analyzer test.
  4. You can get information from the main page of the site by clicking on the “Run check” button. The result with the response code, h1 tag, title, description and creation date will appear if the test is successful.
  5. All checks can be viewed in the “websites” tab (You can see all added URLs on the /urls page.)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published