This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import tokenizer | |
from constants import tokenTypes, tagTokenTypes | |
class HTMLParser(object): | |
def __init__(self): | |
self.reset() | |
def reset(self): | |
self._tokenizer = None | |
pass |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -r 639d5836906a apisample3.htm | |
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 | |
+++ b/apisample3.htm Tue May 08 17:17:26 2012 +0200 | |
@@ -0,0 +1,17 @@ | |
+<!DOCTYPE HTML> | |
+<html> | |
+<head> | |
+<title>Sample HTML5 API Tests</title> | |
+</head> | |
+<script src="testharness.js"></script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class StructuredLogger(object): | |
def __init__(self): | |
self._log = logger | |
def _test_log_func(level_name): | |
def log(self, params): | |
all_params = {"_thread":threading.current_thread().name, | |
"_process":multiprocessing.current_process().name} | |
all_params.update(params) | |
self._log.log_structured(level_name, all_params) |
This file has been truncated, but you can view the full file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"items": { | |
"reftest": [ | |
{ | |
"url": "/html/dom/elements/global-attributes/dir_auto-EN-L.html", | |
"path": "html/dom/elements/global-attributes/dir_auto-EN-L.html", | |
"ref_type": "==", | |
"ref_url": "/html/dom/elements/global-attributes/dir_auto-EN-L-ref.html" | |
}, | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set -e | |
echo "Ensure server and celery are running and press Enter" | |
read | |
sed -i 's|BUILDAPI_BUILDS4H_URL = ".*"|BUILDAPI_BUILDS4H_URL = "https://secure.pub.build.mozilla.org/builddata/buildjson/builds-2015-11-03.js.gz"|' treeherder/config/settings.py | |
python manage.py ingest_push mozilla-inbound 2530cf72c8e7 | |
echo "Wait for log parsing mark push, then press Enter" | |
read | |
python manage.py ingest_push mozilla-inbound c615bf9eae4f |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cPickle | |
import re | |
import os | |
from collections import defaultdict | |
import numpy | |
from sklearn.feature_extraction import DictVectorizer | |
from sklearn.linear_model import SGDClassifier | |
from treeherder.model.models import Job |