This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from flask import Flask, Response, request, jsonify, redirect, send_from_directory | |
from flask_restful import Api, Resource | |
from werkzeug.utils import secure_filename | |
class file_operation: | |
def __init__(self): | |
self.APP_ROOT = os.path.dirname(os.path.abspath(__file__)) | |
self.UPLOAD_FOLDER = os.path.join(self.APP_ROOT, 'upload_folder_logreg') | |
self.ALLOWED_EXTENSIONS = set(['txt', 'csv']) |