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

Drop most of djblets and replace it by custom models to store stuff #236

Merged
merged 17 commits into from
Apr 8, 2014

Conversation

unho
Copy link
Member

@unho unho commented Apr 6, 2014

No description provided.

unho and others added 8 commits April 4, 2014 19:51
We can do way with it by subclassing Django’s Form directly.

Pick notes: Partial pick of khaledhosny/pootle@1eb6c2bd. The rest of the
    changes don't apply since we dropped the ability to alter the settings
    from the home page in b4d46d6.

Conflicts:
	pootle/apps/pootle_app/views/admin/adminpages.py
	pootle/apps/pootle_app/views/index/index.py
Also this code accomplishes the same thing and is much more easy to
understand than djblets one we were using.
Exposing each separate use for siteconfig makes easier to replace it.

Add functions to retrieve site title and description. This avoids us
retrieving all the site config in the place where we need the title or
the description.
Exposing each separate use for siteconfig makes easier to replace it.

This moves the ability to save buildversion to pootle_misc. This avoids
us retrieving all the site config in the place where we save the build
versions.
Exposing each separate use for siteconfig makes easier to replace it.

This moves the code to retrieve buildversion to pootle_misc. This avoids
us retrieving the build versions in the place where we need the build
versions.
Also adjust the GeneralSettingsForm to use PootleSite.
@jleclanche
Copy link
Member

Yay :) Ill review this on the plane.

@jleclanche
Copy link
Member

Other than the build failure, gtm.

@dwaynebailey
Copy link
Member

I've only previously seen this issue when using sqlite and putting the database under load. The fact that this is now happening on all 3 supported databases is a bit of a concern :/

@unho
Copy link
Member Author

unho commented Apr 7, 2014

The last fix seems to have solved all the tests failures. If you don't have any further issue I will merge this tomorrow.

@jleclanche
Copy link
Member

@unho Please use "except Exception" instead of naked except clauses. Once that's fixed, all GTM.

unho added 9 commits April 8, 2014 10:10
Since the previous commit the code works fine just using POOTLE_BUILDVERSION
instead of BUILDVERSION.

Note that this requires treating the build version as a string.
…model

But keep the old functions to retrieve the data stored using djblets.
Even when saving old build versions. This requires migrate to PootleConfig
ASAP on the upgrading cycle.

This will allow to simplify a bit our code to save and retrieve the build
versions so it only relies on the new PootleConfig.
Also drop code that is unused now that the middleware is not used.
@unho unho merged commit 9fdfb70 into translate:master Apr 8, 2014
@unho unho deleted the kill-djblets branch April 8, 2014 08:42
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.

4 participants