Closed Bug 1477468 Opened 6 years ago Closed 6 years ago

Redirect request for /en-US/docs/Mozilla/QA/Marionette

Categories

(developer.mozilla.org Graveyard :: General, enhancement, P2)

enhancement

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: ato, Assigned: rjohnson)

Details

(Keywords: in-triage, Whiteboard: [points:2])

jwhitlock: Perhaps you can help me find the right person to take
this on?
Flags: needinfo?(jwhitlock)
Flags: needinfo?(jwhitlock)
Product: Developer Documentation → developer.mozilla.org
Keywords: in-triage
Priority: -- → P1
Whiteboard: [points:2]
Assignee: nobody → rjohnson
We don't support in-content redirects to external websites, because of the high potential for abuse. We have a different, in-code mechanism for external redirects:

https://github.com/mozilla/kuma/blob/master/kuma/redirects/redirects.py

We have headless tests (like curl, not FF headless) that verify these redirects:

https://github.com/mozilla/kuma/blob/master/tests/headless/test_redirects.py

If you have a developer that is comfortable with Python, I could mentor them through creating the pull request. If not, we'll get it into the tasks for our next sprint, starting in 3 weeks.

Here are the pages under that tree:

https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Builds
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Developer_setup
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Protocol
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Python_Tests
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Test_Runner
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/MarionetteTestCase
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Client
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Running_Tests
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Tests
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver/Status

It appears each of the 12 pages has their own target, so there will be 12 redirect patterns.

Some of these pages have translations, such as:

https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette

I suggest deleting these translations, so that they will redirect to the English version, which will redirect to the https://firefox-source-docs.mozilla.org docs.
fscholz: Can you please delete the French translation found on
https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette?
Flags: needinfo?(fscholz)
cmills: I can’t seem to get a reply from fscholz.  Can you delegate
accordingly?
Flags: needinfo?(fscholz) → needinfo?(cmills)
ato: Sorry the writers are non-responsive. Page deletion requests are usually filed under the Developer Documentation product, and follow-on requests should get new bugs rather than being added to an existing bug.

That page can't be deleted because it has a child page:

https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette/WebDriver

Do you want this page deleted as well? Do you want all translations of the Marionette tree deleted?
Flags: needinfo?(ato)
Priority: P1 → P2
(In reply to John Whitlock [:jwhitlock] from comment #5)

> ato: Sorry the writers are non-responsive. Page deletion requests
> are usually filed under the Developer Documentation product, and
> follow-on requests should get new bugs rather than being added to
> an existing bug.

Sorry about that, I wasn’t aware.  I’ve moved the bug under
Developer Documentation :: General.

> That page can't be deleted because it has a child page:
> 
> https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette/WebDriver
> 
> Do you want this page deleted as well? Do you want all
> translations of the Marionette tree deleted?

Yes, following your advice from above my understanding is that the
correct procedure is:

  (1) Delete any translations so that they redierct to en-US.

  (2) Add redirect patterns to kuma for the en-US originals.

In order to achieve 1, all child pages must also be deleted.  That
is obviously fine, since the purpose of this bug is to redirect
everything under /en-US/docs/Mozilla/QA/Marionette to
https://firefox-source-docs.mozilla.org/testing/marionette/marionette/.

The first step I can’t do myself.  The second I’m wary of doing
because I don’t have any kuma experience, so I guess the best
self-service option we have here is to not redirect pages but put
in place hard-coded links in the articles?
Flags: needinfo?(ato)
Product: developer.mozilla.org → Developer Documentation
Bah, sorry for missing this for so long. My email filters/folders are not working properly, I've just found out, so I've not been seeing some Bugzilla messages. I've had a play with them to see if I can improve things.

I have gone through all the existing translations and redirected them to the English versions of the pages, so they then see your link to the new home.

I am not sure if we need to do anything else here. We can't use the redirect tool to redirect to external sites.

Let me know if you need anything else.
Flags: needinfo?(cmills)
OK, we're back to Kuma tasks. 

This is an internal redirect, already handled:

https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver -> https://developer.mozilla.org/en-US/docs/Web/WebDriver

These are external redirects, need a code change:

https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/index.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Developer_setup -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Contributing.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Protocol -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Protocol.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Python_Tests -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Test_Runner -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/MarionetteTestCase -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Client -> http://marionette-client.readthedocs.io/en/latest/
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Running_Tests -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Tests -> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver/status -> https://bugzilla.mozilla.org/showdependencytree.cgi?id=721859&hide_resolved=1
Status: NEW → ASSIGNED
Product: Developer Documentation → developer.mozilla.org
After some research, I found more to do here. Here is my current task list, which is a superset of the 10 items listed above:

# Here are the 22 redirects that I need to create:
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/index.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Builds --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Building.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Client --> https://marionette-client.readthedocs.io/en/latest/
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Python_Client --> https://marionette-client.readthedocs.io/en/latest/
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Developer_setup --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Contributing.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/MarionetteTestCase --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Python_Tests --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Test_Runner --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Running_Tests --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Tests --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Protocol --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Protocol.html
- https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver/status --> https://bugzilla.mozilla.org/showdependencytree.cgi?id=721859&hide_resolved=1
- https://developer.mozilla.org/en-US/docs/Marionette --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/index.html
- https://developer.mozilla.org/en-US/docs/Marionette/Builds --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Building.html
- https://developer.mozilla.org/en-US/docs/Marionette/Client --> https://marionette-client.readthedocs.io/en/latest/
- https://developer.mozilla.org/en-US/docs/Marionette/Debugging --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Debugging.html
- https://developer.mozilla.org/en-US/docs/Marionette/Developer_setup --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/Contributing.html
- https://developer.mozilla.org/en-US/docs/Marionette/MarionetteTestCase --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_Python_Tests --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Marionette/Running_Tests --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Marionette/Tests --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html
- https://developer.mozilla.org/en-US/docs/Marionette_Test_Runner --> https://firefox-source-docs.mozilla.org/testing/marionette/marionette/PythonTests.html

# Here are the 28 documents that I need to delete:
- https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/pl/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/pt-BR/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/ru/docs/Marionette
- https://developer.mozilla.org/zh-CN/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Builds
- https://developer.mozilla.org/ru/docs/Marionette/Builds
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Connecting_to_B2G
- https://developer.mozilla.org/pt-BR/docs/Mozilla/QA/Marionette/Conectando_ao_B2G
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Developer_setup
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Marionette_JavaScript_Tests
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Running_Tests
- https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/pl/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/zh-CN/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/pl/docs/Mozilla/QA/Marionette/WebDriver/status
- https://developer.mozilla.org/en-US/docs/Marionette/Connecting_to_B2G (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Connecting_to_B2G which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Emulator (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Emulator which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/EmulatorBattery (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/EmulatorBattery which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette which doesn't exist)
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_JavaScript_Tests (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_JavaScript_Tests which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_JavaScript_Tools (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_JavaScript_Tools which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_Python_Tests/Emulator_Integrated_Tests (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Marionette_Python_Tests/Emulator_Integrated_Tests which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Performance_tests (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Performance_tests which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Python_Marionette (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Python_Marionette which has been deleted)
- https://developer.mozilla.org/en-US/docs/Marionette/Setup (currently a redirect to https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Setup which has been deleted)


# I don't know what to do with this one (ato: Is this still valid, or would you like it redirected somewhere?):
- https://developer.mozilla.org/en-US/docs/Marionette/B2Gisms


--Ryan
Flags: needinfo?(ato)
I deleted (hard delete -- a delete followed by a purge) these documents yesterday:

- https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/pl/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/pt-BR/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/ru/docs/Marionette
- https://developer.mozilla.org/zh-CN/docs/Mozilla/QA/Marionette
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Builds
- https://developer.mozilla.org/ru/docs/Marionette/Builds
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Connecting_to_B2G
- https://developer.mozilla.org/pt-BR/docs/Mozilla/QA/Marionette/Conectando_ao_B2G
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Developer_setup
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Marionette_JavaScript_Tests
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/Running_Tests
- https://developer.mozilla.org/fr/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/ja/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/pl/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/zh-CN/docs/Mozilla/QA/Marionette/WebDriver
- https://developer.mozilla.org/pl/docs/Mozilla/QA/Marionette/WebDriver/status
- https://developer.mozilla.org/en-US/docs/Marionette/Connecting_to_B2G
- https://developer.mozilla.org/en-US/docs/Marionette/Emulator
- https://developer.mozilla.org/en-US/docs/Marionette/EmulatorBattery
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_JavaScript_Tests
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_JavaScript_Tools
- https://developer.mozilla.org/en-US/docs/Marionette/Marionette_Python_Tests/Emulator_Integrated_Tests
- https://developer.mozilla.org/en-US/docs/Marionette/Performance_tests
- https://developer.mozilla.org/en-US/docs/Marionette/Python_Marionette
- https://developer.mozilla.org/en-US/docs/Marionette/Setup
First of all, massive thanks to Ryan for doing all this work!  This
is astounding! 👍

(In reply to Ryan Johnson (:rjohnson) from comment #9)

> # I don't know what to do with this one (ato: Is this still valid, or would
> you like it redirected somewhere?):
> - https://developer.mozilla.org/en-US/docs/Marionette/B2Gisms

This should also be deleted.  B2G/FirefoxOS is not something we support.

Please let me know if there’s anything I can do to help.
Flags: needinfo?(ato)
Awesome, thanks Andreas! I've deleted https://developer.mozilla.org/en-US/docs/Marionette/B2Gisms as requested.
Commits pushed to master at https://github.com/mozilla/kuma

https://github.com/mozilla/kuma/commit/bd04852c064ee8e84382c0f0d01b184022a3e35a
bug 1477468: add redirects for marionette

* add redirects
* add tests for redirects

https://github.com/mozilla/kuma/commit/f0a2bc300dc23dd93d54f9c0ff794247888d8451
Merge pull request #5051 from escattone/marionette-redirects-1477468

bug 1477468: add redirects for marionette
This has been released to production, and passes the tests:

(mdntest) rjohnson-25186:kuma rjohnson$ pytest --base-url https://developer.mozilla.org tests/headless/test_redirects.py::test_marionette_redirects
=============================================== test session starts ===============================================
platform darwin -- Python 2.7.15, pytest-3.1.3, py-1.4.33, pluggy-0.4.0
metadata: {'Python': '2.7.15', 'Driver': None, 'Capabilities': {}, 'Base URL': 'https://developer.mozilla.org', 'Platform': 'Darwin-17.7.0-x86_64-i386-64bit', 'kuma': {u'services': {u'search': {u'available': True, u'count': 61210, u'populated': True}, u'kumascript': {u'available': True, u'revision': u'519b2fd2e829e9e9344d369dc16aab5e7a09c1d7'}, u'test_accounts': {u'available': False}, u'database': {u'available': True, u'document_count': 131306, u'populated': True}}, u'version': 1, u'request': {u'url': u'https://developer.mozilla.org/_kuma_status.json', u'is_secure': True, u'host': u'developer.mozilla.org', u'scheme': u'https'}, 'response': {'headers': {'X-Cache': 'Miss from cloudfront', 'strict-transport-security': 'max-age=63072000', 'x-content-type-options': 'nosniff', 'Content-Language': 'en-US', 'Content-Encoding': 'gzip', 'Transfer-Encoding': 'chunked', 'Expires': 'Wed, 31 Oct 2018 22:32:12 GMT', 'Vary': 'Accept-Encoding', 'Server': 'meinheld/0.6.1', 'Connection': 'keep-alive', 'x-xss-protection': '1; mode=block', 'X-Amz-Cf-Id': '_REw-0BAwsizya_PiRTF23D7wrv08pQYIUKJzGXxIto9MWarzj600Q==', 'Cache-Control': 'no-cache, no-store, must-revalidate, max-age=0', 'Date': 'Wed, 31 Oct 2018 22:32:11 GMT', 'X-Frame-Options': 'DENY', 'Content-Type': 'application/json', 'Via': '1.1 97c5dcf9c391508cdebbbfdcf304912f.cloudfront.net (CloudFront)'}}, u'settings': {u'ATTACHMENT_HOST': u'mdn.mozillademos.org', u'PROTOCOL': u'https://', u'INTERACTIVE_EXAMPLES_BASE': u'https://interactive-examples.mdn.mozilla.net', u'MAINTENANCE_MODE': False, u'STATIC_URL': u'https://developer.mozilla.org/static/', u'SITE_URL': u'https://developer.mozilla.org', u'ATTACHMENT_ORIGIN': u'demos-origin.mdn.mozit.cloud', u'DEBUG': False, u'ALLOWED_HOSTS': [u'developer.mozilla.org', u'cdn.mdn.mozilla.net', u'mdn.mozillademos.org', u'demos.mdn.mozit.cloud', u'demos-origin.mdn.mozit.cloud', u'developer-prod.mdn.mozit.cloud', u'prod.mdn.mozit.cloud', u'developer.mozilla.com', u'mdn.mozilla.org', u'developer-new.mozilla.org', u'developers.mozilla.org'], u'REVISION_HASH': u'f5edc039881450fc0e7bc9f5a4c87056814afc80', u'LEGACY_HOSTS': [u'cdn.mdn.mozilla.net', u'developer.mozilla.com', u'mdn.mozilla.org', u'developer-new.mozilla.org', u'developers.mozilla.org']}}, 'Plugins': {'variables': '1.7.1', 'selenium': '1.14.0', 'rerunfailures': '2.1.0', 'html': '1.16.1', 'base-url': '1.4.1', 'metadata': '1.5.1'}, 'Packages': {'py': '1.4.33', 'pytest': '3.1.3', 'pluggy': '0.4.0'}}
baseurl: https://developer.mozilla.org
sensitiveurl: .* *** WARNING: sensitive url matches https://developer.mozilla.org ***
rootdir: /Users/rjohnson/repos/kuma, inifile: pytest.ini
plugins: metadata-1.5.1, base-url-1.4.1, variables-1.7.1, html-1.16.1, selenium-1.14.0, rerunfailures-2.1.0
collected 176 items

tests/headless/test_redirects.py ................................................................................................................................................................................

=========================================== 176 passed in 29.21 seconds ===========================================
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Product: developer.mozilla.org → developer.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.