3763 Commits

Author SHA1 Message Date
ayleph
8cf9d64328 Updates per request of moggers87 2014-10-30 11:34:23 -05:00
ayleph
c7236fd0da Unit tests
Added unit tests for lowercasify username on login.
2014-10-30 11:34:23 -05:00
ayleph
a2b3c623fd Pass validated username to check_login_simple
The login function in mediagoblin/auth/views.py grabs the username prior to
form validation. If validation passes, the pre-validated username is passed to
the check_login_simple function.

Lowercasifying of the username occurs as part of form validation. By sending
the pre-validated username, there's a chance of sending a username with
uppercase letters. This will fail to match any user ids in the database, as
all of the usernames are lowercased during the registration process.

This change sends the post-validated username to check_login_simple, so that
any username that was entered by the user with uppercase letters has a chance
to be properly lowercased before being passed.
2014-10-30 11:34:23 -05:00
Christopher Allan Webber
aa50cab0dc Template hook to allow plugin authors to add extra things to the header
Thanks to Andrew Browning for requesting this and suggesting where to
put it!
2014-10-30 11:15:19 -05:00
Jessica Tallon
bc2c06a10d Fix #1017 - Exception caused by activity being set on incorrect foreign key
The .activity ForeignKey on several models such as MediaEntry expects
	a ActivityIntmediatory ID not an Activity ID however in submit code the
	activity attribute was being set the Activity, simply removing this
	assignment should fix the issue as everything is set correctly at this point.

	I have also moved the creation of the activity above the processing of media
	to avoid race conditions.
2014-10-29 08:47:12 +00:00
Jessica Tallon
c5f258fec0 Fix #1007 - get location object not string of location name; caused 500 when editing profile 2014-10-27 11:11:43 +00:00
Jessica Tallon
0dc2e731d6 Fix #1010 - Typos in mediagoblin/media_types/image/migrations.py 2014-10-27 09:45:23 +00:00
Jessica Tallon
790e1a96eb Fix #1005 - location.position is a dictionary so 'value' in dict check needed 2014-10-27 09:28:56 +00:00
Jessica Tallon
63c865790a Only create a slug after a media upload via the API when there is a title 2014-10-22 21:42:57 +01:00
Jessica Tallon
c785f3a090 Fix problem where duplicate slug would cause an update exception 2014-10-22 18:59:04 +01:00
Jessica Tallon
44c53d3bc4 Merge branch '984-ai-improvements' 2014-10-21 11:57:15 +01:00
Jessica Tallon
5ddc85e071 Fix #984 - Improvements to Activity and ActivityIntermediator
- Add unit tests to cover get and set methods on Activity
- Rewrite the set to remove set and use Session.flush instead
- Use sqlalchemy's validator instead of .save hack
2014-10-21 11:44:11 +01:00
Meg Ford
4f1a34b84d airy.css: Override white text in TOS
Fixes bug https://issues.mediagoblin.org/ticket/808
2014-10-16 15:01:49 -05:00
Christopher Allan Webber
4c03d45f6a Make a mediagoblin.ini file for the user if needed.
This is to prevent our docs from confusing people in this
transitionary time period...
2014-10-10 19:35:09 -05:00
Christopher Allan Webber
03969d8521 Bring back the ascii art goblin! For python 2 anyway.
This does a "friendly" fallback where it skips the middleware on python 3.
2014-10-10 15:46:08 -05:00
Christopher Allan Webber
227a81b534 Add and use paste server selector. Yeah! Smart solutions!
This commit sponsored by Tryggvi Björgvinsson.  Thank you!
2014-10-10 14:42:17 -05:00
Jessica Tallon
ed48454558 Merge branch 'location'
Add Location model which holds textual, geolocation coordiantes
	or postal addresses. This migrates data off Image model metadata
	onto the general Location model. It also adds the ability for location
	to be set on MediaEntry, User, MediaComment and Collection models.

	The geolocation plugin has been updated so that the location can be displayed
	in more general places rather than explicitely on the MediaEntry view.
	If GPS coordiantes are set for the User the profile page will also have the
	OSM provided by the geolocation plugin.
2014-10-09 19:20:13 +01:00
Jessica Tallon
c0434db469 Add location model and migrations 2014-10-09 19:16:54 +01:00
Jessica Tallon
9a1fc423ac Merge branch '905-activities'
Add Activity and Generator models which allow for
    activities to be created. This now works with the
    feed API.
2014-10-07 10:01:38 +01:00
Jessica Tallon
2b1916182d Add __repr__ to Activity and Generator class 2014-10-07 10:00:37 +01:00
Jessica Tallon
240e987016 Fix bug where activity.content was not populated 2014-10-06 11:48:08 +01:00
Jessica Tallon
6d36f75f84 Fix all the unit tests and clean up code 2014-10-06 11:48:03 +01:00
Jessica Tallon
670cdef79c Fix typo in client registration API for logo_uri 2014-10-02 20:34:25 +01:00
Berker Peksag
cca5d508ad Add initial migration guide.
This can be moved to docs/source/devel/migrations.rst.
2014-10-02 20:18:29 +03:00
Berker Peksag
2ace351bed Do not call AlembicMigrationManager.init_tables() for now.
sqlalchemy-migrate will do this for us.
2014-10-02 20:18:29 +03:00
Berker Peksag
b36c84e68a Port "gmg batchaddmedia" command to Python 3. 2014-10-02 20:18:29 +03:00
Jessica Tallon
7e15632b5a Fix #549 - Deauthorize OAuth applications 2014-10-01 19:45:53 +01:00
Christopher Allan Webber
36e27c4b76 Fix migrations on Python 2.
This commit sponsored by Loïc Grobol.  Thank you!
2014-09-30 16:34:15 -05:00
Jessica Tallon
1a2982d6e3 Fix #919 - Use class names in super call not self.__class__ 2014-09-30 12:50:51 +01:00
Jessica Tallon
ec84acacdc Fix #952 - Force the footer to the bottom of the page 2014-09-30 11:23:24 +01:00
Jessica Tallon
ffa9346cef Merge branch '942-default-location'
* 942-default-location:
  Add documentation on changing data dir and Fix stylistic changes
  Updated config_spec.ini to add %(data_basedir)s and make use of it!
  defaults now pulled from a mashup of mediagoblin.ini and config_spec.ini
2014-09-29 09:04:30 +01:00
Jessica Tallon
11f0e2f89b Add documentation on changing data dir and Fix stylistic changes 2014-09-29 09:04:04 +01:00
Alon Levy
becd160703 pdf tests: use our own pdf doc as GOOD_PDF
remove non distributable good.pdf
2014-09-26 09:31:12 -05:00
Christopher Allan Webber
98cbe47fb3 Updated config_spec.ini to add %(data_basedir)s and make use of it!
This commit sponsored by Loïc Grobol.  Thanks!
2014-09-24 18:13:19 +01:00
Christopher Allan Webber
2b1e0af03b defaults now pulled from a mashup of mediagoblin.ini and config_spec.ini
This commit sponsored by Thomas Løcke.  Thank you!
2014-09-24 18:13:19 +01:00
Christopher Allan Webber
0c78f41ac7 Switch print statement to print function 2014-09-24 09:32:13 -05:00
Jessica Tallon
ec305bda61 Fix Content-Disposition error for retrieving OAuth request tokens 2014-09-24 11:53:33 +01:00
Christopher Allan Webber
c2059c4a74 Making alembic happen with python 3 only... for now.
We want to make sure it works nicely first.
2014-09-22 14:09:59 -05:00
Christopher Allan Webber
a6252cbf21 Merge branch 'merge-python3-port'
Conflicts:
	setup.py
2014-09-22 13:58:13 -05:00
Christopher Allan Webber
c47f402d7e MediaGoblin 0.7.2 development cycle 2014-09-22 13:38:00 -05:00
Christopher Allan Webber
12fac853a4 MediaGoblin 0.7.1! 2014-09-21 14:25:06 -05:00
Christopher Allan Webber
d12373845f Committing extracted and compiled translations 2014-09-21 11:08:49 -05:00
Christopher Allan Webber
b993e32ffd Committing present MediaGoblin translations before pushing extracted messages 2014-09-21 11:08:22 -05:00
Christopher Allan Webber
1f7f2891ea Merge remote-tracking branch 'refs/remotes/moggers87/garbage-branch' 2014-09-19 16:25:35 -05:00
Christopher Allan Webber
ff1e9e96b6 Temporarily disable garbage collection
We need to make sure we safely set up transactions here... it looks
pretty clearly like we aren't yet, so we need to review this.  This
should be re-enabled by 0.8.0.
2014-09-19 15:56:26 -05:00
Christopher Allan Webber
31f8909f9b Comment out the "check if the database is up to date" stuff
... it's presently causing session issues :\
2014-09-17 18:08:54 -05:00
Christopher Allan Webber
6430ae97ec Last two issues related to the python 3 merge tests: fixed!
- Fix the "pulling the error out of excinfo" stuff for py3
 - The u"" only gets embedded in the string on py2.

This commit sponsored by Jeff Gibson.  Thanks, Jeff! :)
2014-09-16 17:39:53 -05:00
ayleph
f0e795df82 Modify deleteuser to fail gracefully
bin/gmg deleteuser will produce a traceback error if you attempt to delete a
user who does not exist. This commit provides a fix to allow deletuser to fail
gracefully.

This commit addresses https://issues.mediagoblin.org/ticket/969
2014-09-16 15:29:09 -07:00
Christopher Allan Webber
1db2bd3fe7 Annnnd another json decode fix for py3! On a roll with these!
This commit sponsored by Ramana Kumar.  Thanks!
2014-09-16 15:35:23 -05:00
Christopher Allan Webber
37865d02dd decode to unicode before loading in json again, for py3
This commit sponsored by Chris Cormack.  Thanks!
2014-09-16 15:33:46 -05:00