Skip to main content

Flask-Admin plus Flask-Admin PRs to extend testing and fix test failures

Project description

Flask-Admix

https://github.com/flask-admix/flask-admix/actions/workflows/test.yaml/badge.svg?branch=main https://img.shields.io/badge/license-BSD--3--Clause-blue

This is Flask-Admin plus Flask-Admin PRs to extend testing and fix test failures with newer versions of dependencies, minus features that are not compatible. It provides the flask_admin package and therefore cannot be installed in the same environment as Flask-Admin.

  • modules that were not tested or had tests that do not pass with newer dependencies have been removed

  • fixes only for test failures and some deprecation warnings

  • no new features

  • no updated documentation

  • no updated examples

  • no updated translations

The main branch may be rebased at any time. Branches are preserved for each release.

Flask-Admin

Introduction

Flask-Admin is a batteries-included, simple-to-use Flask extension that lets you add admin interfaces to Flask applications. It is inspired by the django-admin package, but implemented in such a way that the developer has total control of the look, feel and functionality of the resulting application.

Out-of-the-box, Flask-Admin plays nicely with various ORM’s, including

It also boasts a simple file management interface and a redis client console.

The biggest feature of Flask-Admin is flexibility. It aims to provide a set of simple tools that can be used for building admin interfaces of any complexity. So, to start off with you can create a very simple application in no time, with auto-generated CRUD-views for each of your models. But then you can go further and customize those views & forms as the need arises.

Flask-Admin is an active project, well-tested and production ready.

Examples

Several usage examples are included in the /examples folder. Please add your own, or improve on the existing examples, and submit a pull-request.

To run the examples in your local environment:

1. Clone the repository::

      git clone https://github.com/flask-admin/flask-admin.git
      cd flask-admin

2. Create and activate a virtual environment::

      virtualenv env -p python3
      source env/Scripts/activate

3. Install requirements::

      pip install -r examples/sqla/requirements.txt

4. Run the application::

      python examples/sqla/run_server.py

Documentation

Flask-Admin is extensively documented, you can find all of the documentation at https://flask-admin.readthedocs.io/en/latest/.

The docs are auto-generated from the .rst files in the /doc folder. So if you come across any errors, or if you think of anything else that should be included, then please make the changes and submit them as a pull-request.

To build the docs in your local environment, from the project directory:

tox -e docs-html

And if you want to preview any .rst snippets that you may want to contribute, go to http://rst.ninjs.org/.

Installation

To install Flask-Admin, simply:

pip install flask-admin

Or alternatively, you can download the repository and install manually by doing:

git clone git@github.com:flask-admin/flask-admin.git
cd flask-admin
python setup.py install

Tests

Test are run with pytest. If you are not familiar with this package you can get some more info from their website.

To run the tests, from the project directory, simply:

pip install -r requirements-dev.txt
pytest

You should see output similar to:

.............................................
----------------------------------------------------------------------
Ran 102 tests in 13.132s

OK

For all the tests to pass successfully, you’ll need Postgres & MongoDB to be running locally. For Postgres:

> psql postgres
CREATE DATABASE flask_admin_test;
\q

> psql flask_admin_test
CREATE EXTENSION postgis;
CREATE EXTENSION hstore;

If you’re using Homebrew on MacOS, you might need this:

# install postgis
> brew install postgis

# set up postgresql user
> createuser -s postgresql
> brew services restart postgresql

You can also run the tests on multiple environments using tox.

3rd Party Stuff

Flask-Admin is built with the help of Bootstrap, Select2 and Bootswatch.

If you want to localize your application, install the Flask-BabelEx package.

You can help improve Flask-Admin’s translations through Crowdin: https://crowdin.com/project/flask-admin

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

Flask_Admix-1.6.1.2.tar.gz (7.4 MB view details)

Uploaded Source

Built Distribution

Flask_Admix-1.6.1.2-py3-none-any.whl (7.4 MB view details)

Uploaded Python 3

File details

Details for the file Flask_Admix-1.6.1.2.tar.gz.

File metadata

  • Download URL: Flask_Admix-1.6.1.2.tar.gz
  • Upload date:
  • Size: 7.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for Flask_Admix-1.6.1.2.tar.gz
Algorithm Hash digest
SHA256 b2ed46859c7ba9aad6d04dbcf7b0f3385cfe494ad810f9f689ef78131d9629ea
MD5 e36466b1179a6823779fbb033a62fba7
BLAKE2b-256 3031e71a2eb0c91a8b70f755257580e4f644d20c1f0d8e4950da70d1457b7974

See more details on using hashes here.

File details

Details for the file Flask_Admix-1.6.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for Flask_Admix-1.6.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 adb74ab640d2c8278e742db50ad91809e2bed2d9a55340f5352856fc02122747
MD5 a1059de66fecd7219d3fa7d922999742
BLAKE2b-256 bbf099ae9be5d23010e2db01208a8f451cdd18ecbb34dd19cffc32bec397dfe4

See more details on using hashes here.

Supported by

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