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

Need ability to disable analytics on staging server #11

Closed
alexgleason opened this issue Mar 14, 2016 · 3 comments
Closed

Need ability to disable analytics on staging server #11

alexgleason opened this issue Mar 14, 2016 · 3 comments

Comments

@alexgleason
Copy link
Collaborator

Kind of like #8, but I also just realized you don't want it on the stage either, which is a completely separate problem to solve and one that comes with its own set of issues. Quite a complex problem, really. Obviously you don't want analytics on a stage as it's a waste of API calls and clutters the data with information the client shouldn't be concerned with.

But how do you detect that we're on a staging server when it uses production.py? Some sort of blacklist? Or a separate library that's installed on the stage that reports that it's a stage? Not sure how to do this and minimizing the burden of it for everyone involved.

Wondering if @ftarnell has any ideas?

@tomdyson
Copy link
Owner

This module isn't concerned with storing user activity; it assumes that you're doing that already. I should probably make that clearer in the documentation.

There are several established techniques for not recording activity in development, staging, preview etc. See http://docs.wagtail.io/en/v1.3.1/topics/writing_templates.html?highlight=analytics#varying-output-between-preview-and-live and http://stackoverflow.com/a/1272312/181793 for some pointers.

@alexgleason
Copy link
Collaborator Author

Hmm. I thought you might close all my issues for this reason. :) Didn't realize this was the case until afterwards.

That said, these are some GA problems that need solving and could use a Wagtail package. I see your linked articles, which are helpful. Though ideally with Wagtail we can get to a point where we can pip install as much as possible to have to do less work. Seems like a good opportunity to use this package to also ship some integration functionality. If not it would just be in a separate package.

@tomdyson
Copy link
Owner

I've updated the README to make it more obvious for future generations :)

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

No branches or pull requests

2 participants