Code Monkey home page Code Monkey logo

s3browser's People

Contributors

emissionnebula avatar paramanu avatar rozuur avatar senani-mayank avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

s3browser's Issues

Import error with Libmagic

Can you please help me out with this :

image

image

ubuntu@ip-172-31-1-72:~/s3browser$ docker run -t -i --env-file ~/aws.env -p9000:9000 s3browser ./s3browser/start_gunicorn.sh
[2021-04-19 07:09:07 +0000] [9] [INFO] Starting gunicorn 19.9.0
[2021-04-19 07:09:07 +0000] [9] [INFO] Listening at: http://0.0.0.0:9000 (9)
[2021-04-19 07:09:07 +0000] [9] [INFO] Using worker: gthread
[2021-04-19 07:09:07 +0000] [12] [INFO] Booting worker with pid: 12
[2021-04-19 07:09:07 +0000] [13] [INFO] Booting worker with pid: 13
[2021-04-19 07:09:08 +0000] [12] [ERROR] Exception in worker process
Traceback (most recent call last):
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 583, in spawn_worker
worker.init_process()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/workers/gthread.py", line 104, in init_process
super(ThreadWorker, self).init_process()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/workers/base.py", line 129, in init_process
self.load_wsgi()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/workers/base.py", line 138, in load_wsgi
self.wsgi = self.app.wsgi()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/base.py", line 67, in wsgi
self.callable = self.load()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/wsgiapp.py", line 52, in load
return self.load_wsgiapp()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/wsgiapp.py", line 41, in load_wsgiapp
return util.import_app(self.app_uri)
File "/opt/venv/lib/python3.7/site-packages/gunicorn/util.py", line 350, in import_app
import(module)
File "/s3browser/wsgi.py", line 1, in
from app import app
File "/s3browser/app/init.py", line 5, in
from app import routes
File "/s3browser/app/routes.py", line 4, in
import magic
File "/opt/venv/lib/python3.7/site-packages/magic.py", line 181, in
raise ImportError('failed to find libmagic. Check your installation')
ImportError: failed to find libmagic. Check your installation
[2021-04-19 07:09:08 +0000] [12] [INFO] Worker exiting (pid: 12)
[2021-04-19 07:09:08 +0000] [13] [ERROR] Exception in worker process
Traceback (most recent call last):
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 583, in spawn_worker
worker.init_process()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/workers/gthread.py", line 104, in init_process
super(ThreadWorker, self).init_process()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/workers/base.py", line 129, in init_process
self.load_wsgi()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/workers/base.py", line 138, in load_wsgi
self.wsgi = self.app.wsgi()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/base.py", line 67, in wsgi
self.callable = self.load()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/wsgiapp.py", line 52, in load
return self.load_wsgiapp()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/wsgiapp.py", line 41, in load_wsgiapp
return util.import_app(self.app_uri)
File "/opt/venv/lib/python3.7/site-packages/gunicorn/util.py", line 350, in import_app
import(module)
File "/s3browser/wsgi.py", line 1, in
from app import app
File "/s3browser/app/init.py", line 5, in
from app import routes
File "/s3browser/app/routes.py", line 4, in
import magic
File "/opt/venv/lib/python3.7/site-packages/magic.py", line 181, in
raise ImportError('failed to find libmagic. Check your installation')
ImportError: failed to find libmagic. Check your installation
[2021-04-19 07:09:08 +0000] [13] [INFO] Worker exiting (pid: 13)
Traceback (most recent call last):
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 210, in run
self.sleep()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 360, in sleep
ready = select.select([self.PIPE[0]], [], [], 1.0)
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 245, in handle_chld
self.reap_workers()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 525, in reap_workers
raise HaltServer(reason, self.WORKER_BOOT_ERROR)
gunicorn.errors.HaltServer: <HaltServer 'Worker failed to boot.' 3>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/opt/venv/bin/gunicorn", line 8, in
sys.exit(run())
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/wsgiapp.py", line 61, in run
WSGIApplication("%(prog)s [OPTIONS] [APP_MODULE]").run()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/base.py", line 223, in run
super(Application, self).run()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/app/base.py", line 72, in run
Arbiter(self).run()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 232, in run
self.halt(reason=inst.reason, exit_status=inst.exit_status)
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 345, in halt
self.stop()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 393, in stop
time.sleep(0.1)
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 245, in handle_chld
self.reap_workers()
File "/opt/venv/lib/python3.7/site-packages/gunicorn/arbiter.py", line 525, in reap_workers
raise HaltServer(reason, self.WORKER_BOOT_ERROR)
gunicorn.errors.HaltServer: <HaltServer 'Worker failed to boot.' 3>

Download Feature

Browsing csv/tsv files is a powerful feature. For such files, I cannot find any option to download. The usual browser save stores the webpage instead of csv.

Better handling of mimetypes

If we don't find the mimetype of a file try to guess the mimetype based on the contents of the file

Instead of downloading the complete file, use smart_open to read only 1024 bytes and magic library to guess the mimetype

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.