Giter Club home page Giter Club logo

compatipede's Introduction

  • ๐Ÿ”ญ Work: Axiom
  • ๐Ÿ’ฌ Passion: Data-Structures, DBs, Algorithms

compatipede's People

Contributors

hallvors avatar karlcow avatar seiflotfy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

compatipede's Issues

Let plug-ins contribute to pass/fail status for a site

To target pass/fail heuristics at specific sites, we can let plug-ins override the logic in the rest of the script.

For example, given the fictive jQuery 1.6 problem in the spec.txt file we'd probably want to say that sites where this plugin found a match were "fails" regardless of other results. We could add a new property to the JSON:

{
"name": "jQuery-1.6-check",
"javascript": "try{ jQuery().jquery === "1.6" }catch(e){}",
"markMatchesAs": "fail"

And add a little bit of code handling this.

Save and compare console error messages

This is a little harder than it sounds - there may be hundreds if not thousands of messages for some sites. We should probably make a unique set for each browser instance - not saving any duplicate messages - and then check if both sets contain the same entries (order is irrelevant).

Compare only host, path for redirects (not query string)

To handle Google and others who redirect to URLs with random session nonces in the query string, we should parse the result URLs and compare only host and pathname. If both host and path matches, the redirects should be considered equal.

Review the Accept header

make sure that the Accept: HTTP header the Gecko instance sends matches the one a real Gecko instance would send..

Keeping an archive of all the markup and assets for a run

When creating a run on X number of sites, it is sometimes useful to be able to compare the code, HTTP trace, Redirections, etc. from date1 and date2 for each sites.

It might create a huge volume of data. It would be good to define what is the best model to keep the record of this snapshot.

Compatipede gets confused by WAP content?

When pushing m.ireader.com to Compatipede it seems to take a loooong time to conclude the analysis. I think it is confused by the WAP Content-type header and waits for some timeout.

We should add testing for text/vnd.wap.wml by default, and mark page as failed if any content is delivered with this MIME type.

Store failure reasons

We have the status:pass/fail field, but when we keep adding heuristics and rules it will eventually take us more and more time to figure out why the script said pass or fail for that site.

We should probably add a "failing tests" list to make this clear. For example

"pass":"false",
"failures": ["redirect", "content", "plugin: foo"]

will save us some head-scratching later on.

Document requirements

To get the new webcompat.py running, I had to do

apt-get install rabbitmq-server
pip install pika
pip install pymongo

Should be added to readme.md :)

Don't track sub-resource redirects

I get the below output for "redirects" - it seems to add information for every resource, including external scripts, img and stylesheets. We don't need this data - we should figure out a way to track redirects for the main URL only:

'redirects': {'ios': [u'http://video.ft.com/2836530119001/Typhoon-damage-exacerbated-by-poverty/Editors-Choice', u'http://media.ft.com/null.js', u'http://4235225.fls.doubleclick.net/activityi;src=4235225;type=homeo886;cat=ft-ho780;u7=NOR;u5=1;u1=;ord=1;num=8885692604817.45;~oref=http%3A%2F%2Fvideo.ft.com%2F2836530119001%2FTyphoon-damage-exacerbated-by-poverty%2FEditors-Choice?&_dc_ck=try', u'http://ib.adnxs.com/bounce?%2Fseg%3Fadd%3D1001722%26t%3D2', u'https://www.facebook.com/fr/u.php?p=391363987594223&m=0', u'http://beacon.krxd.net/usermatch.gif?partner=exelate', u'http://api.bizographics.com/v1/profile.redirect?api_key=595bae8dbc0c4c42b4544e688b10c002&callback_url=http%3A//beacon.krxd.net/data.gif%3F_kdpid%3D890a6228-04af-4630-85b6-0b49dee6157f%26pid%3Dbcbe1a6d-fa90-4db5-b4dc-424c69802310&3pc=true', u'http://beacon.krxd.net/data.gif?_kdpid=890a6228-04af-4630-85b6-0b49dee6157f&pid=bcbe1a6d-fa90-4db5-b4dc-424c69802310'], 'fos': [u'http://video.ft.com/2836530119001/Typhoon-damage-exacerbated-by-poverty/Editors-Choice', u'http://media.ft.com/null.js', u'http://4235225.fls.doubleclick.net/activityi;src=4235225;type=homeo886;cat=ft-ho780;u7=;u5=1;u1=;ord=1;num=9517158693633.973;~oref=http%3A%2F%2Fvideo.ft.com%2F2836530119001%2FTyphoon-damage-exacerbated-by-poverty%2FEditors-Choice?&_dc_ck=try', u'http://ib.adnxs.com/bounce?%2Fseg%3Fadd%3D1001722%26t%3D2', u'https://www.facebook.com/fr/u.php?p=391363987594223&m=0', u'http://api.bizographics.com/v1/profile.redirect?api_key=595bae8dbc0c4c42b4544e688b10c002&callback_url=http%3A//beacon.krxd.net/data.gif%3F_kdpid%3D890a6228-04af-4630-85b6-0b49dee6157f%26pid%3Dbcbe1a6d-fa90-4db5-b4dc-424c69802310&3pc=true', u'http://beacon.krxd.net/data.gif?_kdpid=890a6228-04af-4630-85b6-0b49dee6157f&pid=bcbe1a6d-fa90-4db5-b4dc-424c69802310', u'http://beacon.krxd.net/usermatch.gif?partner=exelate']

Rewrite view.py to view.js

To enable proper compatibility tests we will need test with gecko and webkit instead of webkit only. I suggest we rewrite view.py in JS and execute it from the browser.py via phantomjs (webkit) and slimerjs (gecko). This should work flawlessly since slimerjs is based on phantomjs

http://phantomjs.org/
http://slimerjs.org/

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.