Giter Club home page Giter Club logo

pa11y-webservice's Introduction

Pa11y

Pa11y is your automated accessibility testing pal. It runs accessibility tests on your pages via the command line or Node.js, so you can automate your testing process.

NPM version Node.js version support Build status LGPL-3.0-only licensed

On the command line:

pa11y https://example.com

In JavaScript:

const pa11y = require('pa11y');

pa11y('https://example.com').then((results) => {
    // Use the results
});

Requirements

Pa11y 8 requires Node.js 18 or 20. An older version of Node.js can be used with Pa11y 6 or below.

Linux and macOS

To install Node.js you can use nvm. For example, to install with nvm with Homebrew, and then install the latest version of Node:

brew install nvm
nvm install node
nvm install-latest-npm

Alternatively, download a pre-built package from the Node.js website for your operating system.

Windows

On Windows 10, download a pre-built package from the Node.js website. Pa11y will be usable via the bundled Node.js application as well as the Windows command prompt.

Command-line interface

Install Pa11y globally with npm:

npm install -g pa11y
$ pa11y --help

Usage: pa11y [options] <url>

  Options:

    -V, --version                  output the version number
    -n, --environment              output details about the environment Pa11y will run in
    -s, --standard <name>          the accessibility standard to use: WCAG2A, WCAG2AA (default), WCAG2AAA – only used by htmlcs runner
    -r, --reporter <reporter>      the reporter to use: cli (default), csv, json
    -e, --runner <runner>          the test runners to use: htmlcs (default), axe
    -l, --level <level>            the level of issue to fail on (exit with code 2): error, warning, notice
    -T, --threshold <number>       permit this number of errors, warnings, or notices, otherwise fail with exit code 2
    -i, --ignore <ignore>          types and codes of issues to ignore, a repeatable value or separated by semi-colons
    --include-notices              Include notices in the report
    --include-warnings             Include warnings in the report
    -R, --root-element <selector>  a CSS selector used to limit which part of a page is tested
    -E, --hide-elements <hide>     a CSS selector to hide elements from testing, selectors can be comma separated
    -c, --config <path>            a JSON or JavaScript config file
    -t, --timeout <ms>             the timeout in milliseconds
    -w, --wait <ms>                the time to wait before running tests in milliseconds
    -d, --debug                    output debug messages
    -S, --screen-capture <path>    a path to save a screen capture of the page to
    -A, --add-rule <rule>          WCAG 2.1 rules to include, a repeatable value or separated by semi-colons – only used by htmlcs runner
    -h, --help                     output usage information

Testing with pa11y

Find accessibility issues at a URL:

pa11y https://example.com

The default test runner is HTML_CodeSniffer, but axe is also supported. To use axe:

pa11y https://example.com --runner axe

Use both axe and HTML_CodeSniffer in the same run:

pa11y https://example.com --runner axe --runner htmlcs

Generate results in CSV format, and output to a file, report.csv:

pa11y https://example.com > report.csv --reporter csv 

Find accessibility issues in a local HTML file (absolute paths only, not relative):

pa11y ./path/to/your/file.html

Exit codes

The command-line tool uses the following exit codes:

  • 0: Pa11y ran successfully, and there are no errors
  • 1: Pa11y failed run due to a technical fault
  • 2: Pa11y ran successfully but there are errors in the page

By default, only accessibility issues with a type of error will exit with a code of 2. This is configurable with the --level flag which can be set to one of the following:

  • error: exit with a code of 2 on errors only, exit with a code of 0 on warnings and notices
  • warning: exit with a code of 2 on errors and warnings, exit with a code of 0 on notices
  • notice: exit with a code of 2 on errors, warnings, and notices
  • none: always exit with a code of 0

Command-line configuration

The command-line tool can be configured with a JSON file as well as arguments. By default it will look for a pa11y.json file in the current directory, but you can change this with the --config flag:

pa11y https://example.com --config ./path/to/config.json 

If any configuration is set both in a configuration file and also as a command-line option, the value set in the latter will take priority.

For more information on configuring Pa11y, see the configuration documentation.

Ignoring

The ignore flag can be used in several different ways. Separated by semi-colons:

pa11y https://example.com --ignore "issue-code-1;issue-code-2" 

or by using the flag multiple times:

pa11y https://example.com --ignore issue-code-1 --ignore issue-code-2 

Pa11y can also ignore notices, warnings, and errors up to a threshold number. This might be useful if you're using CI and don't want to break your build. The following example will return exit code 0 on a page with 9 errors, and return exit code 2 on a page with 10 or more errors.

pa11y https://example.com --threshold 10 

Reporters

The command-line tool can provide test results in a few different ways using the --reporter flag. The built-in reporters are:

  • cli: output test results in a human-readable format
  • csv: output test results as comma-separated values
  • html: output test results as an HTML page
  • json: output test results as a JSON array
  • tsv: output test results as tab-separated values

You can also write and publish your own reporters. Pa11y looks for reporters in your node_modules folder (with a naming pattern), and the current working directory. The first reporter found will be loaded. So with this command:

pa11y https://example.com --reporter rainbows 

The following locations will be checked:

<cwd>/node_modules/pa11y-reporter-rainbows
<cwd>/rainbows

A Pa11y reporter must export a string property named supports. This is a semver range which indicates which versions of Pa11y the reporter supports:

exports.supports = '^8.0.0';

A reporter should export the following methods, each returning one string. If your reporter needs to perform asynchronous operations, then it may return a promise which resolves to a string:

begin(); // Called when pa11y starts
error(message); // Called when a technical error is reported
debug(message); // Called when a debug message is reported
info(message); // Called when an information message is reported
results(results); // Called with a test run's results

JavaScript interface

Add Pa11y to your project with npm, most commonly as a development dependency:

npm install pa11y --save-dev

Require Pa11y:

const pa11y = require('pa11y');

Run Pa11y against a URL, the pa11y function returns a Promise:

pa11y(url).then((results) => {
    // Use the results
});

Pa11y can also be run with options:

const options = { /* ... */ };
pa11y(url, options)).then((results) => {
    // Use the results
});

Pa11y resolves with a results object, containing details about the page, and an array of accessibility issues found by the test runner:

{
    pageUrl: 'The tested URL',
    documentTitle: 'Title of the page under test',
    issues: [
        {
            code: 'WCAG2AA.Principle1.Guideline1_1.1_1_1.H30.2',
            context: '<a href="https://example.com/"><img src="example.jpg" alt=""/></a>',
            message: 'Img element is the only content of the link, but is missing alt text. The alt text should describe the purpose of the link.',
            selector: 'html > body > p:nth-child(1) > a',
            type: 'error',
            typeCode: 1
        }
    ]
}

Transforming the results

If you wish to transform these results with a command-line reporter, require it into your code. The csv, tsv, html, json, and markdown reporters each expose a method process:

// Assuming you've already run tests, and the results
// are available in a `results` variable:
const htmlReporter = require('pa11y/lib/reporters/html');
const html = await htmlReporter.results(results);

async/await

Pa11y uses promises, so you can use async functions and the await keyword:

async function runPa11y() {
    try {
        const results = await pa11y(url);
        // Use the results
    }
    catch (error) {
        // Handle error
    }
}

runPa11y();

Callback interface

For those who prefer callbacks to promises:

pa11y(url, (error, results) => {
    // Use results, handle error
});

Validating actions

Pa11y's isValidAction function can be used to validate an action string ahead of its use:

pa11y.isValidAction('click element #submit');  // true
pa11y.isValidAction('open the pod bay doors'); // false

Configuration

Pa11y has lots of options you can use to change the way Headless Chrome runs, or the way your page is loaded. Options can be set either as a parameter on the pa11y function or in a JSON configuration file. Some are also available directly as command-line options.

Below is a reference of all the options that are available:

actions (array)

Actions to be run before Pa11y tests the page. There are quite a few different actions available in Pa11y, the Actions documentation outlines each of them.

pa11y(url, {
    actions: [
        'set field #username to exampleUser',
        'set field #password to password1234',
        'click element #submit',
        'wait for path to be /myaccount'
    ]
});

Defaults to an empty array.

browser (Browser) and page (Page)

A Puppeteer Browser instance which will be used in the test run. Optionally you may also supply a Puppeteer Page instance, but this cannot be used between test runs as event listeners would be bound multiple times.

If either of these options are provided then there are several things you need to consider:

  1. Pa11y's chromeLaunchConfig option will be ignored, you'll need to pass this configuration in when you create your Browser instance
  2. Pa11y will not automatically close the Browser when the tests have finished running, you will need to do this yourself if you need the Node.js process to exit
  3. It's important that you use a version of Puppeteer that meets the range specified in Pa11y's package.json
  4. You cannot reuse page instances between multiple test runs, doing so will result in an error. The page option allows you to do things like take screen-shots on a Pa11y failure or execute your own JavaScript before Pa11y

Note: This is an advanced option. If you're using this, please mention in any issues you open on Pa11y and double-check that the Puppeteer version you're using matches Pa11y's.

const browser = await puppeteer.launch({
    ignoreHTTPSErrors: true
});

pa11y(url, {
    browser: browser
});

browser.close();

A more complete example can be found in the puppeteer examples.

Defaults to null.

chromeLaunchConfig (object)

Launch options for the Headless Chrome instance. See the Puppeteer documentation for more information.

pa11y(url, {
    chromeLaunchConfig: {
        executablePath: '/path/to/Chrome',
        ignoreHTTPSErrors: false
    }
});

Defaults to:

{
    ignoreHTTPSErrors: true
}

headers (object)

A key-value map of request headers to send when testing a web page.

pa11y(url, {
    headers: {
        Cookie: 'foo=bar'
    }
});

Defaults to an empty object.

hideElements (string)

A CSS selector to hide elements from testing, selectors can be comma separated. Elements matching this selector will be hidden from testing by styling them with visibility: hidden.

pa11y(url, {
    hideElements: '.advert, #modal, div[aria-role=presentation]'
});

ignore (array)

An array of result codes and types that you'd like to ignore. You can find the codes for each rule in the console output and the types are error, warning, and notice. Note: warning and notice messages are ignored by default.

pa11y(url, {
    ignore: [
        'WCAG2AA.Principle3.Guideline3_1.3_1_1.H57.2'
    ]
});

Defaults to an empty array.

ignoreUrl (boolean)

Whether to use the provided Puppeteer Page instance as is or use the provided url. Both the Puppeteer Page instance and the Puppeteer Browser instance are required alongside ignoreUrl.

const browser = await puppeteer.launch();
const page = await browser.newPage();

pa11y(url, {
    ignoreUrl: true,
    page: page,
    browser: browser
});

Defaults to false.

includeNotices (boolean)

Whether to include results with a type of notice in the Pa11y report. Issues with a type of notice are not directly actionable and so they are excluded by default. You can include them by using this option:

pa11y(url, {
    includeNotices: true
});

Defaults to false.

includeWarnings (boolean)

Whether to include results with a type of warning in the Pa11y report. Issues with a type of warning are not directly actionable and so they are excluded by default. You can include them by using this option:

pa11y(url, {
    includeWarnings: true
});

Defaults to false.

level (string)

The level of issue which can fail the test (and cause it to exit with code 2) when running via the CLI. This should be one of error (the default), warning, or notice.

{
    "level": "warning"
}

Defaults to error. Note this configuration is only available when using Pa11y on the command line, not via the JavaScript Interface.

log (object)

An object which implements the methods debug, error, and info which will be used to report errors and test information.

pa11y(url, {
    log: {
        debug: console.log,
        error: console.error,
        info: console.info
    }
});

Each of these defaults to an empty function.

method (string)

The HTTP method to use when running Pa11y.

pa11y(url, {
    method: 'POST'
});

Defaults to GET.

postData (string)

The HTTP POST data to send when running Pa11y. This should be combined with a Content-Type header. E.g to send form data:

pa11y(url, {
    headers: {
        'Content-Type': 'application/x-www-form-urlencoded'
    },
    method: 'POST',
    postData: 'foo=bar&bar=baz'
});

Or to send JSON data:

pa11y(url, {
    headers: {
        'Content-Type': 'application/json'
    },
    method: 'POST',
    postData: '{"foo": "bar", "bar": "baz"}'
});

Defaults to null.

reporter (string)

The reporter to use while running the test via the CLI. More about reporters.

{
    "reporter": "json"
}

Defaults to cli. Note this configuration is only available when using Pa11y on the command line, not via the JavaScript Interface.

rootElement (element)

The root element for testing a subset of the page opposed to the full document.

pa11y(url, {
    rootElement: '#main'
});

Defaults to null, meaning the full document will be tested. If the specified root element isn't found, the full document will be tested.

runners (array)

An array of runner names which correspond to existing and installed Pa11y runners. If a runner is not found then Pa11y will error.

pa11y(url, {
    runners: [
        'axe',
        'htmlcs'
    ]
});

Defaults to:

[
    'htmlcs'
]

rules (array)

An array of WCAG 2.1 guidelines that you'd like to include to the current standard. You can find the codes for each guideline in the HTML Code Sniffer WCAG2AAA ruleset. Note: only used by htmlcs runner.

pa11y(url, {
    rules: [
        'Principle1.Guideline1_3.1_3_1_AAA'
    ]
});

screenCapture (string)

A file path to save a screen capture of the tested page to. The screen will be captured immediately after the Pa11y tests have run so that you can verify that the expected page was tested.

pa11y(url, {
    screenCapture: `${__dirname}/my-screen-capture.png`
});

Defaults to null, meaning the screen will not be captured. Note the directory part of this path must be an existing directory in the file system – Pa11y will not create this for you.

standard (string)

The accessibility standard to use when testing pages. This should be one of WCAG2A, WCAG2AA, or WCAG2AAA. Note: only used by htmlcs runner.

pa11y(url, {
    standard: 'WCAG2A'
});

Defaults to WCAG2AA.

threshold (number)

The number of errors, warnings, or notices to permit before the test is considered to have failed (with exit code 2) when running via the CLI.

{
    "threshold": 9
}

Defaults to 0. Note this configuration is only available when using Pa11y on the command line, not via the JavaScript Interface.

timeout (number)

The time in milliseconds that a test should be allowed to run before calling back with a timeout error.

Please note that this is the timeout for the entire test run (including time to initialise Chrome, load the page, and run the tests).

pa11y(url, {
    timeout: 500
});

Defaults to 30000.

userAgent (string)

The User-Agent header to send with Pa11y requests. This is helpful to identify Pa11y in your logs.

pa11y(url, {
    userAgent: 'A11Y TESTS'
});

Defaults to pa11y/<version>.

viewport (object)

The viewport configuration. This can have any of the properties supported by the puppeteer setViewport method.

pa11y(url, {
    viewport: {
        width: 320,
        height: 480,
        deviceScaleFactor: 2,
        isMobile: true
    }
});

Defaults to:

{
    width: 1280,
    height: 1024
}

wait (number)

The time in milliseconds to wait before running HTML_CodeSniffer on the page.

pa11y(url, {
    wait: 500
});

Defaults to 0.

Actions

Actions are additional interactions that you can make Pa11y perform before the tests are run. They allow you to do things like click on a button, enter a value in a form, wait for a redirect, or wait for the URL fragment to change:

pa11y(url, {
    actions: [
        'click element #tab-1',
        'wait for element #tab-1-content to be visible',
        'set field #fullname to John Doe',
        'clear field #middlename',
        'check field #terms-and-conditions',
        'uncheck field #subscribe-to-marketing',
        'screen capture example.png',
        'wait for fragment to be #page-2',
        'wait for path to not be /login',
        'wait for url to be https://example.com/',
        'wait for #my-image to emit load',
        'navigate to https://another-example.com/'
    ]
});

Below is a reference of all the available actions and what they do on the page. Some of these take time to complete so you may need to increase the timeout option if you have a large set of actions.

click element <selector>

Clicks an element:

pa11y(url, {
    actions: [
        'click element #tab-1'
    ]
});

You can use any valid query selector, including classes and types.

set field <selector> to <value>

Sets the value of a text-based input or select:

pa11y(url, {
    actions: [
        'set field #fullname to John Doe'
    ]
});

clear field <selector>

Clears the value of a text-based input or select:

pa11y(url, {
    actions: [
        'clear field #middlename'
    ]
});

check field <selector>, uncheck field <selector>

Checks/unchecks an input of type radio or checkbox:

pa11y(url, {
    actions: [
        'check field #terms-and-conditions',
        'uncheck field #subscribe-to-marketing'
    ]
});

screen capture <to-file-path.png>

Captures the screen, saving the image to a file, which can be useful between actions for debugging, or just for visual reassurance:

pa11y(url, {
    actions: [
        'screen capture example.png'
    ]
});

wait for

wait for <fragment|path|url>

This allows you to pause the test until a condition is met, and the page has either a given fragment, path, or URL. This will wait until Pa11y times out so it should be used after another action that would trigger the change in state. You can also wait until the page does not have a given fragment, path, or URL using the to not be syntax. This action takes one of the forms:

  • wait for fragment to be <fragment> (including the preceding #)
  • wait for fragment to not be <fragment> (including the preceding #)
  • wait for path to be <path> (including the preceding /)
  • wait for path to not be <path> (including the preceding /)
  • wait for url to be <url>
  • wait for url to not be <url>

E.g.

pa11y(url, {
    actions: [
        'click element #login-link',
        'wait for path to be /login'
    ]
});

wait for element's state

This allows you to pause the test until an element on the page (matching a CSS selector) is either added, removed, visible, or hidden. This will wait until Pa11y times out so it should be used after another action that would trigger the change in state. This action takes one of the forms:

  • wait for element <selector> to be added
  • wait for element <selector> to be removed
  • wait for element <selector> to be visible
  • wait for element <selector> to be hidden

E.g.

pa11y(url, {
    actions: [
        'click element #tab-2',
        'wait for element #tab-1 to be hidden'
    ]
});

wait for element's event

This allows you to pause the test until an element on the page (matching a CSS selector) emits an event. This will wait until Pa11y times out so it should be used after another action that would trigger the event. This action takes the form wait for element <selector> to emit <event-type>. E.g.

pa11y(url, {
    actions: [
        'click element #tab-2',
        'wait for element #tab-panel-to to emit content-loaded'
    ]
});

navigate to <url>

This action allows you to navigate to a new URL if, for example, the URL is inaccessible using other methods. This action takes the form navigate to <url>. E.g.

pa11y(url, {
    actions: [
        'navigate to https://another-example.com'
    ]
});

Runners

Pa11y supports multiple test runners which return different results. The built-in options are:

You can also write and publish your own runners. Pa11y looks for runners in your node_modules folder (with a naming pattern), and the current working directory. The first runner found will be loaded. So with this command:

pa11y https://example.com --runner custom-tool

The following locations will be checked:

<cwd>/node_modules/pa11y-runner-custom-tool
<cwd>/node_modules/custom-tool
<cwd>/custom-tool

A Pa11y runner must export a string property named supports. This is a semver range which indicates which versions of Pa11y the runner supports:

exports.supports = '^8.0.0';

A Pa11y runner must export a property named scripts. This is an array of strings which are paths to scripts which need to load before the tests can be run. This may be empty:

exports.scripts = [
    `${__dirname}/vendor/example.js`
];

A runner must export a run method, which returns a promise that resolves with test results (it's advisable to use an async function). The run method is evaluated in a browser context and so has access to a global window object.

The run method must not use anything that's been imported using require, as it's run in a browser context. Doing so will error.

The run method is called with two arguments:

  • options: Options specified in the test runner
  • pa11y: The Pa11y test runner, which includes some helper methods:
    • pa11y.getElementContext(element): Get a short HTML context snippet for an element
    • pa11y.getElementSelector(element): Get a unique selector with which you can select this element in a page

The run method must resolve with an array of Pa11y issues. These follow the format:

{
    code: '123', // An identifier for this error
    element: {}, // The HTML element this issue relates to; `null` if no element is involved
    message: 'example', // A description of the issue
    type: 'error', // 'error', 'warning', or 'notice'
    runnerExtras: {} // Additional data a runner is free to provide; unused by Pa11y itself
}

Examples

Basic example

Run Pa11y on a URL and output the results. See the example.

Multiple URLs example

Run Pa11y on multiple URLs at once and output the results. See the example.

Actions example

Step through some actions before Pa11y runs. This example logs into a fictional site then waits until the account page has loaded before running Pa11y. See the example.

Puppeteer example

Pass in pre-created Puppeteer browser and page instances so that you can reuse them between tests. See the example.

Common questions and troubleshooting

See our Troubleshooting guide to get the answers to common questions about Pa11y, along with some ideas to help you troubleshoot any problems.

Tutorials and articles

You can find some useful tutorials and articles in the Tutorials section of pa11y.org.

Contributing

There are many ways to contribute to Pa11y, some of which we describe in the contributing guide for this repo.

If you're ready to contribute some code, clone this repo, commit your code to a new branch, then create a pull request to bring your changes into main. If you're an external contributor, fork this repo first, then follow the same process.

Please write unit tests for your code, and check that everything works by running the following before opening a pull request:

npm run lint                # Lint the code
npm test                    # Run every test, reporting coverage

You can also run test suites individually:

npm run test-unit           # Run the unit tests alone
npm run test-integration    # Run the integration tests alone
npm run test-coverage       # Run the unit tests alone, reporting coverage

Support and migration

Tip

We maintain a migration guide to help you migrate between major versions.

When we release a new major version we will continue to support the previous major version for 6 months. This support will be limited to fixes for critical bugs and security issues. If you're opening an issue related to this project, please mention the specific version that the issue affects.

The following table lists the major versions available and, for each previous major version, its end-of-support date, and its final minor version released.

Major version Final minor version Node.js support Puppeteer version Support end date
8 18, 20 ^22 ✅ Current major version
7 7.0 18, 20 ^20 October 2024
6 6.2 12, 14, 16 ~9.1 July 2024
5 5.3 8, 10, 12 ^1 2021-11-25
4 4.13 4, 6, 8 2018-08-15
3 3.8 0.12, 4 2016-12-05
2 2.4 0.10, 0.12 2016-10-16
1 1.7 0.10 2016-06-08

License

Pa11y is licensed under the Lesser General Public License (LGPL-3.0-only).
Copyright © 2013-2024, Team Pa11y and contributors

pa11y-webservice's People

Contributors

alex20484096 avatar andrewmee avatar carlochess avatar danyalaytekin avatar dependabot[bot] avatar dotcode avatar dracos avatar hollsk avatar joeyciechanowicz avatar joscha avatar josebolos avatar joshski avatar jsa34 avatar jtechera avatar lc512k avatar nickcall avatar paazmaya avatar rayraegah avatar robloach avatar rowanmanning avatar rtshilston avatar sangitamane avatar sudheesh001 avatar wilco42 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pa11y-webservice's Issues

Question: can I call Pa11y API directly

Hello

I have been trying to generate accessibility reports by writing a node script, pa11y is catching many errors for my pages and I'm trying to incorporate it by getting the errors in json form.
the problem is that using the webservice is a lot of boilerplate for me I need to install it on machines of every person who will generate the report and have to start the server each time I want to generate data

I am trying to get accessibility data for public pages using pa11y, for lighthouse I have been using this API endpoint Page Speed insight with ACCESSIBILITY category

the question is there a similar API for pa11y?

Fix npm audit issues

Currently, there are 61 security issues with the dependencies of pa11y-webservice. npm audit provides partial solutions to those. My approach is:

  • npm install hapi@^16.7.0
  • npm install joi@^14.3.0
  • npm install --save-dev [email protected]

The problem with this is that mocha freezes after tests run. They explain why in these patch notes (https://boneskull.com/mocha-v4-nears-release/#mochawontforceexit) and I could make it stop running by appending the mocha command with --exit, but that would require a pull request to https://github.com/rowanmanning/makefiles/blob/master/Makefile.node

So, can you guide me on the best way to fix this?

Cheers!

Pagination

It would be handy if the webservice would be able to accommodate pagination. Either with prev/next functionality or splitting the tasks up alphabetically.

Update shields.io node version badge

The node version badge in the README currently points to the following URL:

https://img.shields.io/badge/node.js%20support-4–6-brightgreen.svg

This specifies the wrong version (should be >=8), and requires an update every time that support changes.

We should change the badge's URL so we use the version that automatically figures out the supported versions.

Upgrade mongodb client to v3

If we want to upgrade MongoDB to v3 then we will have to have a think as it makes a change that the DB is not selected by default. One has to manually select the database using .db(name).
This means we will have to add a section to the configuration to pass this in, which will be a breaking change.

Issue with Mongo Db

Hi,
I am getting following error while running the webservice:

(node:39060) UnhandledPromiseRejectionWarning: MongoError: user is not allowed to do action [listIndexes] on [pa11y-webservice-dev.results]

pa11y behind a proxy?

Well I'm trying pa11y dashboard and webservice but my virtualmachine is set behind a proxy. I've already set my ENV shell variables http_proxy but wasn't helpful.

As far I can see, I should invoke PhantomJS using --proxy ip:port arguments. Any advice about bootstrapping pa11y-webservice with PhantomJS arguments?

UnhandledPromiseRejectionWarning: MongoError: w has to be a non-negative number and not greater than 50

After git cloning / npm i / mongodb installation under Ubuntu 18.04 LTS and changing the webservice -> port in config.js to anything else than 3000, e. g. 5001 leads to following error:

root@didd-dev:/var/www/http/pa11y-dashboard# node index.js 

Pa11y Dashboard started
mode: undefined
uri:  http://:::5000
Server running at: http://0.0.0.0:5001

Pa11y Webservice started
mode:     undefined
uri:      http://0.0.0.0:5001
database: mongodb://localhost/pa11y-webservice
cron:     0 30 0 * * *
(node:23502) UnhandledPromiseRejectionWarning: MongoError: w has to be a non-negative number and not greater than 50
    at Function.MongoError.create (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/error.js:31:11)
    at /var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/pool.js:497:72
    at authenticateStragglers (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/pool.js:443:16)
    at Connection.messageHandler (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/pool.js:477:5)
    at Socket.<anonymous> (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/connection.js:333:22)
    at Socket.emit (events.js:314:20)
    at addChunk (_stream_readable.js:297:12)
    at readableAddChunk (_stream_readable.js:272:9)
    at Socket.Readable.push (_stream_readable.js:213:10)
    at TCP.onStreamRead (internal/stream_base_commons.js:188:23)
(node:23502) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:23502) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
(node:23502) UnhandledPromiseRejectionWarning: MongoError: w has to be a non-negative number and not greater than 50
    at Function.MongoError.create (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/error.js:31:11)
    at /var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/pool.js:497:72
    at authenticateStragglers (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/pool.js:443:16)
    at Connection.messageHandler (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/pool.js:477:5)
    at Socket.<anonymous> (/var/www/http/pa11y-dashboard/node_modules/mongodb-core/lib/connection/connection.js:333:22)
    at Socket.emit (events.js:314:20)
    at addChunk (_stream_readable.js:297:12)
    at readableAddChunk (_stream_readable.js:272:9)
    at Socket.Readable.push (_stream_readable.js:213:10)
    at TCP.onStreamRead (internal/stream_base_commons.js:188:23)
(node:23502) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)

When leaving it at 3000 I get the following error:

root@didd-dev:/var/www/http/pa11y-dashboard# node index.js 

Pa11y Dashboard started
mode: undefined
uri:  http://:::5000
Server running at: http://0.0.0.0:3000
Error: listen EADDRINUSE: address already in use 0.0.0.0:3000
    at Server.setupListenHandle [as _listen2] (net.js:1316:16)
    at listenInCluster (net.js:1364:12)
    at doListen (net.js:1501:7)
    at processTicksAndRejections (internal/process/task_queues.js:85:21)

When checking for other applications running on port 3000 I get nothing in return:

root@didd-dev:/var/www/http/pa11y-dashboard# ps aux | grep 3000
root     23619  0.0  0.0  13136  1028 pts/0    S+   09:19   0:00 grep --color=auto 3000

Replace async dependency with native async/await

As this project only supports LTS versions of node that include full support for async/await we should be able now to remove the async dependency which will reduce the size of our releases.

Although async doesn't have any (sub)dependencies, it takes around 700-800kB in size due to the fact that includes several concatenated versions of all the code.

The tests for "WCAG2AAA" don't include some results from "WCAG2AA" tests

I'm a developer of a web accessibility testing tool that use the pa11y-webservice app.
And durring the development I found a bug in tests for "WCAG2AAA". These results don't include some errors which return tests for "WCAG2AA".

I checked this bug in Pa11y Dashboard app and got the same issue.

I made a test for four dozen sites and see the issue is repeating on all of them.
Any of these tests doesn't include any issue of the "error" type from the "AA" level.

Here's an example made in the Pa11y Dashboard app:
Test for "WCAG2AA"
Test for "WCAG2AAA"
You can see that the "Principle1.Guideline1_4.1_4_3.G18.Fail" issue (error of AA level) from the first test, doesn't appear in the second test - https://prnt.sc/10rhagd

And the same tests on our tool:
Test for "WCAG2AA"
Test for "WCAG2AAA"

Error starting Pa11y Webservice

I don't understand why the Webservice uri is 0.0.0.0 or why the connection is refused to localhost.

Any thoughts on debugging this?

MacBook:pa11y-webservice $ PORT=8080 node index.js

Pa11y Webservice started
mode: development
uri: http://0.0.0.0:3000

Error starting Pa11y Webservice:
connect ECONNREFUSED 127.0.0.1:27017

Allow posting html for auditing directly

I would like to propose an alternative POST body that would be supported in addition to the current POST body.

{
    "name": "my-name",
    "html": "<div>foo</div>",
    "standard": "WCAG2AA"
}

My use case is that I would like to catch a11y issues before they go out, so I would like to write a plugin for the text editor we use on the site (https://www.tiny.cloud/) that posts the contents of the editor on blur, and displays any a11y issues detected as validation errors on the form. This will allow us to alert users of a11y issues when they are authoring their page, and not after it has been released in production.

Set the concurrency limit as environment variable

Currently, the concurrency limit for the cron job is set to 2 workers. Since in some cases some users don't not need to use too many resources and can get the job done wih only one worker, this number could be set using an environment variable.

task/pa11y.js

const queue = async.queue(function(task, nextInQueue) {
	console.log('Starting task %s', task.id);
	app.model.task.runById(task.id, function(error) {
		if (error) {
			console.log(chalk.red('Failed to finish task %s: %s'), task.id, error.message);
		} else {
			console.log(chalk.green('Finished task %s'), task.id);
		}
		nextInQueue();
	});
}, config.nWorkers);

I can make the change but I was wondering, What do you think about it?

Add unit tests for cron job

The cron job part of the code has no testing through unit or integration tests. Integration tests don't really make sense for something that runs on a schedule, so need some unit tests around this.

There has been some issues recently with the stability of that code, so we should definitely get a bit of resliaince in our build around this.

There is currently only one unit test in the entire project 😱 .

Website Logins

Hi. I'm new to using pa11y, and I have the webservice working locally. The site I'm testing has a login page to access any other URL.

Is there any way to add authentication when trying to reach URLs past the login form?

Is there also a way to pass a list of URLs to the service when the task is run?

Sort in CosmosDB Mongo APIs mandates indexing

Expected behaviour

Pa11y dashboard should be able to integrate with Azure Cosmos DB for MongoDB

Actual behaviour

[model:task:getAll failed
Error=2, Details='Response status code does not indicate success: BadRequest (400); Substatus: 0; ActivityId: db9c9b1c-6eb2-43d9-8422-0df2991f8822; Reason: (Response status code does not indicate success: BadRequest (400); Substatus: 0; ActivityId: db9c9b1c-6eb2-43d9-8422-0df2991f8822; Reason: (Response status code does not indicate success: BadRequest (400); Substatus: 0; ActivityId: db9c9b1c-6eb2-43d9-8422-0df2991f8822; Reason: (Message: {"Errors":["The order by query does not have a corresponding composite index that it can be served from."]}
ActivityId: db9c9b1c-6eb2-43d9-8422-0df2991f8822, Request URI: /apps/d76a7012-7f63-444d-b353-8a54be2d58d5/services/f84105c4-7e32-44bf-9ebf-abc37440863d/partitions/771dbbb2-eae7-45cf-bc90-14f8bc3e5295/replicas/133203351083477204s/, RequestStats: Microsoft.Azure.Cosmos.Tracing.TraceData.ClientSideRequestStatisticsTraceDatum, SDK: Windows/10.0.17763 cosmos-netstandard-sdk/3.18.0);););

Error: Error 500
    at Request._callback (C:\Users\80992798\pa11y-dashboard\node_modules\pa11y-webservice-client-node\lib\client.js:124:16)
    at Request.self.callback (C:\Users\80992798\pa11y-dashboard\node_modules\request\request.js:185:22)
    at Request.emit (events.js:315:20)
    at Request.<anonymous> (C:\Users\80992798\pa11y-dashboard\node_modules\request\request.js:1154:10)
    at Request.emit (events.js:315:20)
    at IncomingMessage.<anonymous> (C:\Users\80992798\pa11y-dashboard\node_modules\request\request.js:1076:12)
    at Object.onceWrapper (events.js:421:28)
    at IncomingMessage.emit (events.js:327:22)
at endReadableNT (internal/streams/readable.js:1327:12)
at processTicksAndRejections (internal/process/task_queues.js:80:21)](url)

Steps to reproduce

Connect to cosmos DB by azure

Update nyc to v15 or later

#95 was created to update nyc to v14, but this version has an issue with a config change that causes not all files to be tested. If I'm not mistaken, this has been corrected in v15.

Upgrading to v15 causes the coverage to fail though, so this will need to be corrected:

-----------|---------|----------|---------|---------|-------------------
File       | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s
-----------|---------|----------|---------|---------|-------------------
All files  |     100 |       75 |     100 |     100 |
 config.js |     100 |       75 |     100 |     100 | 18,28
-----------|---------|----------|---------|---------|-------------------
✓ test-unit-coverage done
ERROR: Coverage for branches (75%) does not meet global threshold (90%)
make: *** [verify-coverage] Error 1
npm ERR! Test failed.  See above for more details.

Remove MongoDB testing dependency

The current testing suite for pa11y-webservice requires mongodb to be available and properly set up for the tests to run.

This is usually not much of a problem when running on a CI environment as we've already done the hard work to configure all that, but it makes it much harder to make changes to the project and test things locally. It rises the barrier for contributing to the project.

There's also the risk that, if you use a production DB to run the tests (in order to avoid setting up one local mongoDB instance) all the data will be wiped in the process. This is hostile to the user and fairly unforgiving.

I think that we should rework the tests so they don't depend on a MongoDB instance to be up.

Error connecting to MongoDB

I don't think this is related to #115 but just wanted to link the two. Not sure why this isn't working for me.

$ PORT=8080 npm start

(node:26780) ExperimentalWarning: The fs.promises API is experimental

> [email protected] start
> node index.js

Error connecting to MongoDB:
{"name":"MongoError","message":"failed to connect to server [localhost:27017] on first connect [MongoError: connect ECONNREFUSED 127.0.0.1:27017]"}

Pa11y Webservice started
mode:     undefined
uri:      http://0.0.0.0:8080
database: mongodb://localhost/pa11y-webservice
cron:     false

Error starting Pa11y Webservice:
failed to connect to server [localhost:27017] on first connect [MongoError: connect ECONNREFUSED 127.0.0.1:27017]

Returns 500 without explanation

In a couple of cases the webservices returns an HTTP 500 error without explanation.

Notably when you request a task with lastres: true and there is no last result, the web services simply replies with 500.

Use a logger which labels output

Currently the logging is done using console.log/console.error. We should really be using a configured logger (winston etc) that can also label the log output so that dual dashboard/webservice deployments can differentiate between the output.

i.e.

dashboard: Started on x.x.x.x
webservice: Starting on y.y.y.y

Webservice 2.0

pa11y-webservice 2.0 should be along soon. #26 adds support for Node.js 0.10–6, however we've been left behind on a few dependencies.

pa11y-webservice 2.0 will include no breaking changes except that support for Node.js 0.10–0.12 will be dropped.

Run beforeScript Functions in task

In order to get past a login form, beforeScript tasks are required. This works great with JS wrappers over pa11y but does not work when combined with the webservice (which is the basis for pa11y dashboard, so login with a separate screen also doesn't work through there).

I was hoping to make this possible, or maybe I'm just missing something?

Mongodb username and password get logged on startup

Moving the issue here from pa11y/pa11y-dashboard#273 so we can track it properly.

I've noticed that when the dashboard starts, the mongo connection string is logged. When connecting to a mongo instance using username and password (e.g. mongodb://username:password@localhost/test) this means that the username and password are also logged.

Could the log line be removed, or perhaps just the database host name be logged instead?

Pa11y to test internal sites that are not on the internet but on intranet.

I installed the pa11y command line tool and am able to test any live site, I am wondering how I would go about testing development sites which can't be accessed outside of the network.

Error: PhantomJS failed to open "https://dev.test.cf.mytestsite.ca/foobar.html"
Error: Page "https://dev.test.cf.mytestsite.ca/foobar.html" could not be loaded
at /usr/local/lib/node_modules/pa11y/node_modules/truffler/lib/truffler.js:67:17
at Proto.apply (/usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/dnode/node_modules/dnode-protocol/index.js:123:13)
at Proto.handle (/usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/dnode/node_modules/dnode-protocol/index.js:99:19)
at D.dnode.handle (/usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/dnode/lib/dnode.js:140:21)
at D.dnode.write (/usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/dnode/lib/dnode.js:128:22)
at SockJSConnection.ondata (stream.js:51:26)
at SockJSConnection.emit (events.js:107:17)
at Session.didMessage (/usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/shoe/node_modules/sockjs/lib/transport.js:220:25)
at WebSocketReceiver.didMessage (/usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/shoe/node_modules/sockjs/lib/trans-websocket.js:102:40)
at /usr/local/lib/node_modules/pa11y/node_modules/truffler/node_modules/phantom/node_modules/shoe/node_modules/sockjs/lib/trans-websocket.js:75:22

Is there any way to install, pa11y as well as it's requirements onto a local server and run everything in house without any calls to outside?

Thank you for the help!

[EPIC] Release Pa11y-webservice v5

These are the tasks still missing for next release of pa11y-webservice:

  • Drop support for Node v12 (which will become unsupported in late April).
  • Add support for Node v16, and potentially v18 (which will be released in April) if the MongoDB driver adds support for it.
  • The MongoDB driver has already been upgraded from v3 to v4.4.1 on the next branch but I don't think this version of the MongoDB driver supports Node 16 already.

We should probably wait until late April / early May to see if the mongodb peeps release a 4.5 or 5.0 update for their driver in the meantime and, if not, drop support for Node 12 and release v5 of webservice anyway, as adding support for new versions of Node is not a breaking change but removing support for old versions is.

Upgrade dependencies and migrate when needed

Relating to #68, would be great to have all dependencies up to date and release a new version with minimum Node.js version 8, to match pa11y.

I would be happy to work on this via PRs, but since there are some many open PRs, not sure if there is anyone willing to review and merge...

@rowanmanning possible?

Problems with certain ssl-configurations?

Hello,

since a few weeks my setup pa11y dashboard running version 3.0.0 is not able to test my setup pages anymore. Error message on console is:

xxx.pa11y | Starting to run one-off task @ Wed Sep 11 2019 08:38:10 GMT+0000 (UTC) xxx.pa11y | Starting task 5d78ad119c5abb0700e8107f xxx.pa11y | > PhantomJS page created xxx.pa11y | > Opening "https://shop.xxx.com/de-de/" in PhantomJS xxx.pa11y | > PhantomJS page closed xxx.pa11y | > PhantomJS browser exited xxx.pa11y | Failed to finish task 5d78ad119c5abb0700e8107f: Error opening url "https://shop.xxx.com/de-de/" : Operation canceled xxx.pa11y | Finished running one-off task @ Wed Sep 11 2019 08:38:10 GMT+0000 (UTC)

The website im testing is reachable from the host-machine. The hoster recently changed the ssl cert in use and also disabled old versions of tls.

An upgrade to the most up to date version of the dashboard didnt help:

`Starting to run one-off task @ Wed Sep 11 2019 17:20:39 GMT+0200 (GMT+02:00)
Starting task 5d78ef8642e1ed0007aeb842

Running Pa11y on URL https://shop.xxx.com/de-de
Launching Headless Chrome
Opening URL in Headless Chrome
Injecting HTML CodeSniffer
Injecting Pa11y
Running Pa11y on the page
model:task:runById failed, with id: 5d78ef8642e1ed0007aeb842
Evaluation failed: [object Object]
Failed to finish task 5d78ef8642e1ed0007aeb842`

Im not sure if this is an issue with the dashboard or the webservice. Currently pa11y is running in a self build docker-container. Running it directly on the host-machine, even with newer node versions doesnt help.

Any clue?

Custom values on Task objects

Is there a way to add new keys and values to Task objects? I manually added Task objects with some extra values to categorize them, but the webservice didn't include these values when retrieving the objects.

Unable to start server

I have been unable to start the web service using the provided commands (NODE_ENV=test node .) after a fresh install with no errors. When I issue that command inside of the cloned pa11y directory, no messages are printed to the console (not even an error message). I have the proper configuration files for the environment as well.

Are there any other tricks to getting the web service started?

Automatically remove older results

If you have a large number of URLs that are audited daily, the database can get filled up really quickly. I searched in the code base and I don't think there's a mechanism in place that removes old results? For example all results older than 30 days.

Breakage when trying to run pa11y-dashboard

I've been trying unsuccessfully to run pa11y-dashboard using the unpublished version of pa11y-webservice (as it's in the master branch). There seems to be two issues at the moment:

  • Failure to find the module joy: this may be related to 1097945
  • Failure to start pa11y-webservice: this looks related to 2d8a9a0

"Topology was destroyed" error after returning from sleep

Yesterday I was running pa11y-dashboard locally for debugging purposes, put the laptop to sleep with the dashboard still running, and today after I tried to use the dashboard I started getting the following errors:

  1. Topology was destroyed: When trying, for example, to edit the details of a task (http://localhost:4000/5d33aae9c193490149107fa3/edit) the page will render correctly but Topology was destroyed will appear in the logs. Any attempt to access the DB will show this error. The app is unable to connect to the DB at all, which means that is in an unsafe/invalid state.
  2. When in that state, trying to browse some of the pages (e.g. the home page) will generate an HTTP 500 error, but not all of them will.

We should probably catch these errors and make the app either re-attempt to connect to the DB, or bail out and crash, so any process management (e.g. pm2, forever, etc) can re-launch the app.

It may seem unlikely that users ever see this message but there's a chance this could happen if a running instance gets temporarily suspended (doesn't Heroku do something like this?) but, regardless, because it's good behaviour to catch these errors and try to recover or exit cleanly instead of being stuck in a permanent "HTTP 500" state.

Add support for aXe runner

Pa11y (not currently published) now supports multiple test runners. We need to add the ability to select runners in the webservices.

Therse a couple of ways this could be done:

  • Specify a global runner(s) in the config
  • Specify the runner(s) for each site when it's added to the webservices
    • This would require additional work in the dashboard

Add a changelog

It's about time we started tracking changes in this project properly. We can generate one based on commits to start us off, using the pa11y one as a template.

Incompatible with MongoDB 3.0

There appears to be an issue when trying to use pa11y-webservice with the latest version of MongoDB (3.0). After rolling back to MongoDB v2.6, this issue cleared up and we were able to run pa11y without problems.

[user@pa11y pa11y-dashboard]# grunt start-test
Running "nodemon:test" (nodemon) task
8 Jun 20:38:05 - [nodemon] v0.7.10
8 Jun 20:38:05 - [nodemon] to restart at any time, enter `rs`
8 Jun 20:38:05 - [nodemon] watching: /user/repo/pa11y-dashboard
8 Jun 20:38:05 - [nodemon] starting `node index.js`

pa11y-dashboard started
mode: test
uri:  http://0.0.0.0:4000

pa11y-webservice started
mode: test
uri:  http://0.0.0.0:3000

/user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/connection/base.js:242
        throw message;      
              ^
TypeError: undefined is not a function
    at __executeInsertCommand (/user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/db.js:1829:12)
    at Db._executeInsertCommand (/user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/db.js:1930:5)
    at /user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/db.js:1442:27
    at /user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/db.js:1560:7
    at /user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/cursor.js:162:16
    at commandHandler (/user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/cursor.js:706:16)
    at /user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/db.js:1806:9
    at Server.Base._callHandler (/user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/connection/base.js:442:41)
    at /user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/connection/server.js:485:18
    at MongoReply.parseBody (/user/repo/pa11y-dashboard/node_modules/pa11y-webservice/node_modules/mongodb/lib/mongodb/responses/mongo_reply.js:68:5)
8 Jun 20:38:06 - [nodemon] app crashed - waiting for file changes before starting...

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.