Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moving to Py3 #101

Merged
merged 6 commits into from
Feb 11, 2020
Merged

Moving to Py3 #101

merged 6 commits into from
Feb 11, 2020

Conversation

iambibhas
Copy link
Contributor

@iambibhas iambibhas commented Jan 7, 2020

Related to hasgeek/hgapp#39

Copy link
Member

@jace jace left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on one odd change. Otherwise okay.

.travis.yml Outdated
@@ -14,7 +14,7 @@ env:
- FLASK_ENV=TESTING
language: python
python:
- 2.7
- 3.6
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3.7

imgee/utils.py Outdated
@@ -303,9 +303,8 @@ def is_animated_gif(local_path):

def get_file_type(fp, filename=None):
fp.seek(0)
data = fp.read(1024) # https://github.com/ahupp/python-magic#usage
result = magic.from_buffer(fp.read(), mime=True)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wasn't there a specific reason to read only the first 1024 bytes?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The docs now recommend 2048.

@iambibhas iambibhas merged commit 99ecfd8 into master Feb 11, 2020
@iambibhas iambibhas deleted the py3n2 branch February 11, 2020 06:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants