Skip to main content

Falcontool: a simple utility to create and work with Falcon-based projects

Falcontool is an attempt to provide tooling for quickly and easily starting a Falcon-based project.

It is inspired by Django's django-admin and Flask's flask.

Falcontool does the following:

  • Creates a project repository given a project_name
  • Sets up the basic project scaffolding, including:
    • Creates a tests subdirectory
    • Creates a src subdirectory
    • Creates an empty src/api.py
    • Creates an empty requirements.txt file in the root directory
    • Creates an empty README.md file in the root directory
    • Creates an empty CODEOWNERS file in the root directory
  • Creates additional resources if specified by flags:
    • --dockerfile creates an empty Dockerfile in the root directory
    • --modelsfile creates an empty models.py in src/api directory
    • --dbfile creates an empty db.py in src/api directory
    • --resourcesfile creates an empty resources.py in src/api directory
    • '--tox' creates an empty tox.ini in the root directory
  • Provides the shell command to get a Python console (support IPython if installed)
  • Provides the run command to start the API server

Installation

$> pip install falcontool

Usage

$> falcon create foo
created directory foo
created directory tests
created directory src
created file requirements.txt
created file README.md
created file src/api.py
created file CODEOWNERS

$> cd foo
$> ll -a ./*
-rw-r--r-- 1 tjb tjb   40 Sep 29 20:23 ./CODEOWNERS
-rw-r--r-- 1 tjb tjb   40 Sep 29 20:23 ./README.md
-rw-r--r-- 1 tjb tjb   40 Sep 29 20:23 ./requirements.txt

./src:
total 12
drwxr-xr-x 2 tjb tjb 4096 Sep 29 20:23 ./
drwxr-xr-x 4 tjb tjb 4096 Sep 29 20:23 ../
-rw-r--r-- 1 tjb tjb   40 Sep 29 20:23 api.py

./tests:
total 8
drwxr-xr-x 2 tjb tjb 4096 Sep 29 20:23 ./
drwxr-xr-x 4 tjb tjb 4096 Sep 29 20:23 ../

$> falcon shell
Cannot find IPython. Falling back to Python console.
Python 3.7.4 (default, Aug 19 2019, 22:20:25) 
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> 

$> falcon run
[2019-09-30 18:15:25 -0400] [17047] [INFO] Starting gunicorn 19.9.0
[2019-09-30 18:15:25 -0400] [17047] [INFO] Listening at: http://127.0.0.1:8000 (17047)
[2019-09-30 18:15:25 -0400] [17047] [INFO] Using worker: sync
[2019-09-30 18:15:25 -0400] [17050] [INFO] Booting worker with pid: 17050

Metadata

Release files for falcontool 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for falcontool 0.3.1
File Size Uploaded
falcontool-0.3.1.tar.gz 3.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for falcontool 0.3.1
File Interpreter ABI Platform
falcontool-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 6.4 kB

Release files / falcontool-0.3.1.tar.gz

Download URL falcontool-0.3.1.tar.gz
Size 3.3 kB
Tags Source
SHA-256 checksum
How to use checksums
30cc29d65656aa7bc29c774fb66cd0d0e22048407c580215990218f3cd97f0bc
BLAKE2b-256 checksum
How to use checksums
b2fee542f6576acb641445b1e28f7c3af71cc86d4b11cc3584d3bee754b49ee9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

Release files / falcontool-0.3.1-py3-none-any.whl

Download URL falcontool-0.3.1-py3-none-any.whl
Size 3.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
05337ceae96e4e05188e23f826699b0c76501f2e6cfc529d75a2b863ccd45a22
BLAKE2b-256 checksum
How to use checksums
d6ac5c82a229d1be121bc3a9391b569114f061a928dc05ab8bcf0ce5ca0601d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

Release history Release notifications | RSS feed

This release

0.3.1 This release

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page