Init flask
This commit is contained in:
@@ -1,6 +1,4 @@
|
|||||||
import morfeusz2
|
import conmorfeusz.web as web
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
morf = morfeusz2.Morfeusz()
|
web.start()
|
||||||
analysis = morf.analyse('Ala ma kota.')
|
|
||||||
for i, j, interp in analysis:
|
|
||||||
print(i, j, interp)
|
|
||||||
10
conmorfeusz/conmorfeusz/web.py
Normal file
10
conmorfeusz/conmorfeusz/web.py
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
from flask import Flask
|
||||||
|
|
||||||
|
app = Flask(__name__)
|
||||||
|
|
||||||
|
@app.route("/")
|
||||||
|
def hello():
|
||||||
|
return "Hello, world"
|
||||||
|
|
||||||
|
def start():
|
||||||
|
app.run(port=3000)
|
||||||
@@ -42,6 +42,7 @@ in
|
|||||||
|
|
||||||
propagatedBuildInputs = with pythonPackages; [
|
propagatedBuildInputs = with pythonPackages; [
|
||||||
morfeusz2
|
morfeusz2
|
||||||
|
flask
|
||||||
];
|
];
|
||||||
|
|
||||||
nativeBuildInputs = with pythonPackages; [
|
nativeBuildInputs = with pythonPackages; [
|
||||||
|
|||||||
@@ -9,7 +9,8 @@ description = "Connects Morfeusz and Concraft-pl glued together"
|
|||||||
requires-python = "==3.6"
|
requires-python = "==3.6"
|
||||||
|
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"morfeusz2==1.99.12"
|
"morfeusz2==1.99.12",
|
||||||
|
"flask"
|
||||||
]
|
]
|
||||||
|
|
||||||
[tool.setuptools]
|
[tool.setuptools]
|
||||||
|
|||||||
Reference in New Issue
Block a user