Skip to content
This repository has been archived by the owner on Apr 30, 2023. It is now read-only.
/ store Public archive

Proof of Concept (PoC) for a mobile app store controller, supporting sell operation.

Notifications You must be signed in to change notification settings

91nunocosta/store

Repository files navigation

App Store

Code style: black linting: pylint pre-commit Lint codebase Run tests

Proof of Concept (PoC) for a mobile app store controller, supporting sell operation.

Installation

pip install -e git+ssh://[email protected]/91nunocosta/store.git#egg=appstore

Usage

Enter the appstore Read-Eval-Print Loop (REPL) Command Line Interface (CLI), and type help.

appstore
>help

Documentation

See the internal API's documentation here.

The implementation includes the following classes:

UML Classes Diagram

Next steps

The PoC focuses on app sales business logic, implemented in appstore module.

In a real world-scenario, some steps would likely follow:

  1. Implementing app persistence and distributed access. I.e., providing an AppsDB interface connected to a database.

  2. Implementing user persistence and distributed access. I.e., providing an UsersDB interface connected to a database. There could be a combination of DBMS. We could keep the purchases counter in a key-value memory DB as Redis.

  3. Implementing a full-fledged AccountsController. It likely implies connecting to external services. Such services could support functionalities such as currency exchange. They could accept accounts in many currencies and perform the transferences accordingly.

Development

Preparing the development environment

If you want to test or change the source code, prepare your local environment.

  1. Clone the repository.

    git clone [email protected]:91nunocosta/store.git
  2. Change to the project directory.

    cd appstore
  3. Install poetry package and dependency manager. Follow the poetry installation guide. Chose the method that is more convenient to you, for example:

    curl -sSL\
         https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py \
       | python -
  4. Create a new virtual environment (managed by poetry) with the project dependencies.

    poetry install --with lint --with test --with cd
  5. Activate the virtual environment.

    poetry shell

Pre-commit

Pre-commit runs the linters configured in .pre-commit-config.yaml.

You can run it as follows:

  1. Prepare the development environment, as described in Preparing the development environment.

  2. Run pre-commit with all files.

pre-commit run --all-files

Tests

You can execute all tests and test coverage with tox.ini.

  1. Prepare the development environment, as described in Preparing the development environment.

  2. Run tox.

tox

About

Proof of Concept (PoC) for a mobile app store controller, supporting sell operation.

Topics

Resources

Stars

Watchers

Forks

Languages