4240 Commits

Author SHA1 Message Date
Christopher Allan Webber
21cbf8294e json.loads(request.body) => json.loads(response.body.decode()))
This fixes python 3 stuff.

This commit sponsored by James Reilly.  Thanks, James!
2014-09-16 14:56:13 -05:00
Christopher Allan Webber
fa3f46d714 Import mock correctly on py3
This commit sponsored by Andrew McNicol.  Thank you!
2014-09-16 14:46:02 -05:00
Christopher Allan Webber
b6774d339a Simplify things here and use io.open 2014-09-16 14:37:52 -05:00
Christopher Allan Webber
58a7292fed Fix test_legacy_api.py
Or rather, reimplement one of Berker's fixes and add one of mine:
 - add back the http_auth_headers fix Berker wrote
 - decode to json when testing the response.body, since we have no
   idea what the order will be here
2014-09-16 14:37:36 -05:00
Christopher Allan Webber
3a02813c7a Import mock from unittest if on py3 2014-09-16 14:26:40 -05:00
Christopher Allan Webber
f6bad0eb26 Merge branch 'master' into merge-python3-port
Has some issues, will iteratively fix!

Conflicts:
	mediagoblin/gmg_commands/__init__.py
	mediagoblin/gmg_commands/deletemedia.py
	mediagoblin/gmg_commands/users.py
	mediagoblin/oauth/views.py
	mediagoblin/plugins/api/views.py
	mediagoblin/tests/test_api.py
	mediagoblin/tests/test_edit.py
	mediagoblin/tests/test_oauth1.py
	mediagoblin/tests/test_util.py
	mediagoblin/tools/mail.py
	mediagoblin/webfinger/views.py
	setup.py
2014-09-16 14:01:43 -05:00
Christopher Allan Webber
5b64c92e08 Temporarily disabling the mediagoblin errors middleware
We don't have paste (core) in py3, so....
2014-09-15 14:26:57 -05:00
Christopher Allan Webber
0977d10d2a No reason to wrap the rest of the options in a quote
This commit sponsored by Thane Williams.  Thank you!
2014-09-15 12:11:08 -05:00
Christopher Allan Webber
3c06c3efaf Upgrading gunicorn. Referenced issue is resolved.
Also, upgrading seems to fix weird
"RuntimeError: dictionary changed size during iteration" issues
I was seeing.  (Looked like a gunicorn issue, not ours.)
2014-09-15 11:46:56 -05:00
Christopher Allan Webber
0c32c7fe83 py2.7 compatibility with open(..., encoding="utf-8"), use io.open
This commit sponsored by Peter Baumgarten.  Thank you!
2014-09-12 12:30:09 -05:00
Christopher Allan Webber
9156ab68d0 Explicitly open READMEFILE as utf-8 2014-09-12 10:42:23 -05:00
Christopher Allan Webber
99c466045a Fix unicode error in pdf media type
(we're checking against bytestrings, so make that explicit)
2014-09-12 09:30:46 -05:00
Christopher Allan Webber
b6df960806 Set up tox.ini to run more properly:
- Don't run dbupdate... the tests themselves do this, and we might
   mess up someone's db
 - We shouldn't run setup.py develop because that installs a new
   *live* db... the tests do isolation, so...
 - Install the package's dependencies by the package itself... it
   seems that removing "skipsdist = True" fixes this
 - Run py.test manually rather than use runtests.sh (which itself uses
   ./bin/py.test if it can)
2014-09-12 09:26:01 -05:00
Odin Hørthe Omdal
1b4e199668 Raw image mediatype had a non-unicode logging call
Was causing UnicodeDecodeError when file/folder was not ascii.
Fixes bug #935.
2014-09-07 09:43:49 -05:00
Odin Hørthe Omdal
4f1a5148cb Add __repr__ for Collection and CollectionItem 2014-09-07 09:42:07 -05:00
Christopher Allan Webber
a6570fae03 Slight tweak to the description wording 2014-09-07 09:39:01 -05:00
Low Kian Seong
478e4c9365 Update setup.py
A `description` is needed so that project is not listed as `UNKNOWN` on `pypi`
2014-09-07 09:37:33 -05:00
Christopher Allan Webber
b29b4e175f Handle cr2 files through the raw_image media type
This commit sponsored by Jim Campbell.  Hey, I know that guy!  Thanks
Jim! :)
2014-09-06 10:57:13 -05:00
Jessica Tallon
1b22d51a5d Fixes navbar for sandyseventiesspeedboat 2014-09-05 16:00:06 +01:00
Christopher Allan Webber
f251d99828 now in the 0.7.1.dev cycle 2014-08-27 13:28:51 -05:00
Christopher Allan Webber
cb9f5570f9 Correcting, host-meta not webfinger. 2014-08-27 12:27:04 -05:00
Christopher Allan Webber
fcee02a776 Run the following to fix the missing git submodule init step 2014-08-27 12:26:23 -05:00
Christopher Allan Webber
c7690151cc Also add git submodule init to the release docs 2014-08-26 12:31:29 -05:00
Christopher Allan Webber
5a9111063f At version 0.7.0, at last! 2014-08-25 15:31:55 -05:00
Christopher Allan Webber
3db594557a Committing extracted and compiled translations 2014-08-25 14:44:41 -05:00
Christopher Allan Webber
551027ab0e Committing present MediaGoblin translations before pushing extracted messages 2014-08-25 14:44:17 -05:00
Christopher Allan Webber
3b56b277d1 Updating release notes. 2014-08-25 11:43:17 -05:00
Christopher Allan Webber
2352f7c862 not yet, anyway. 2014-08-22 16:21:48 -05:00
Christopher Allan Webber
b7d854bfe1 Blog media type doc 2014-08-22 16:13:09 -05:00
Christopher Allan Webber
d52638fab4 updating ayleph to Andrew Browning 2014-08-22 15:01:23 -05:00
Christopher Allan Webber
f293506d26 Updating the AUTHORS file for this release 2014-08-22 14:58:22 -05:00
Christopher Allan Webber
d60d686a14 eek, should be python2 not python22 2014-08-22 09:54:55 -05:00
Jessica Tallon
51f4911855 Make blog_post_listing easier to read
This is Elronds change on #948. As 'blog_slug' is always
set in request.matchdict there is no need to do a default-none
get on the dictionary. This change just makes it easier to read.
2014-08-19 14:30:45 +01:00
ayleph
b56cd89eb8 List blogs by URL user rather than request user
The blog_post_listing function in mediagoblin/media_types/blow/views.py
attempts to access blogs based on the requesting user rather than the url
user. This results in server errors when an unauthenticated user attempts to
follow a link from another user's blog post listing, and 404 errors when an
authenticated user attempts to follow a link from another user's blog post
listing.

This change bases blog post listings on the URL user rather than the request
user.
2014-08-19 14:30:45 +01:00
Elrond
3322a63df4 Add docs on collection_add_media hook. 2014-08-19 00:56:37 +02:00
Elrond
7610eb231e Start for documenting core hooks.
This is basicly a start by Chris Webber, I'm just commiting
it for him.
2014-08-19 00:41:21 +02:00
Odin Hørthe Omdal
b694c3de34 Add new hook 'collection_add_media' 2014-08-18 23:18:46 +02:00
Jessica Tallon
9246a6ba89 Tidy up federation code and add tests to cover more of the APIs 2014-08-18 10:51:32 -05:00
Jessica Tallon
32ff6f4dc0 Use oauthlib's safe characters when generating client_key and client_secret 2014-08-18 10:51:15 -05:00
Christopher Allan Webber
a7800e6da8 Fix a python2.6 compatibility issue. Removing a dict comprehension.
This commit sponsored by Christopher Beppler.  Thanks!
2014-08-18 10:40:08 -05:00
Christopher Allan Webber
cbc5f9500c Always remove the session when running check_db_up_to_date()
This commit sponsored by Francois Marier.  Thank you!
2014-08-15 16:30:59 -05:00
Berker Peksag
39a9035487 Implement ServeCommand.{loadserver, loadapp}.
This is partly port from PasteScript.
2014-08-15 23:07:35 +03:00
Berker Peksag
051c728c6e Add an initial "gmg serve" implementation.
The CLI is similar to "paster serve".
2014-08-15 23:02:22 +03:00
Berker Peksag
f3c1b6ff6d Restore different server options. 2014-08-15 22:35:22 +03:00
Berker Peksag
3dbdb061ea Improve mediagoblin._compat.py2_unicode.
- Encode obj.__repr__() to bytestring if its type is unicode in Python 2.
- Add internal encode_to_utf8() decorator.
- Do not raise an exception if a class does not have an __str__() method,
  just warn.
2014-08-15 18:57:48 +03:00
Berker Peksag
2064ad9450 Move the AlembicMigrationManager to top of the module.
Also, add a simple docstring.
2014-08-15 15:40:35 +03:00
Berker Peksag
de51eca53f Provide a better manager API for Alembic. 2014-08-15 15:39:45 +03:00
Berker Peksag
65f20ca435 Add initial Alembic migrations. 2014-08-13 19:30:23 +03:00
Berker Peksag
7df0793441 Fix dict.keys() in Python 3. 2014-08-13 19:27:49 +03:00
Berker Peksag
4930c2adbd Fix a comment. 2014-08-13 19:27:23 +03:00