Skip to content

Latest commit

 

History

History
96 lines (73 loc) · 2.63 KB

CONTRIBUTING.md

File metadata and controls

96 lines (73 loc) · 2.63 KB

Contributing

This repository relates to activities in the Internet Engineering Task Force (IETF). All material in this repository is considered Contributions to the IETF Standards Process, as defined in the intellectual property policies of IETF currently designated as BCP 78, BCP 79 and the IETF Trust Legal Provisions (TLP) Relating to IETF Documents.

Any edit, commit, pull request, issue, comment or other change made to this repository constitutes Contributions to the IETF Standards Process (https://www.ietf.org/).

You agree to comply with all applicable IETF policies and procedures, including, BCP 78, 79, the TLP, and the TLP rules regarding code components (e.g. being subject to a Simplified BSD License) in Contributions.

Table Of Contents

Code of Conduct

Setting up development environment

Running tests

Code of Conduct

See Code of Conduct.

Setting up development environment

  • Set up Python 3.8+ environment.
python3.8 -m venv venv
. venv/bin/activate
  • Install required dependencies.
pip install -r requirements.txt

NOTE: Known issue with Jinja conflict.

  • Set up other dependencies for xml2rfc.

  • To use kramdown-rfc2629 and mmark, you need to have ruby and go installed.

  • Install npm dependencies

npm install
mv ./node_modules/.bin/idnits ./node_modules/.bin/idnits3
bundle install
go get github.com/mmarkdown/mmark
  • Create a tmp directory.
mkdir tmp
  • Create a configuration file.
echo "UPLOAD_DIR = '$PWD/tmp'" > at/config.py
echo "VERSION = '9.9.9'" >> at/config.py
echo "REQUIRE_AUTH = False" >> at/config.py
echo "DT_LATEST_DRAFT_URL = 'https://datatracker.ietf.org/doc/rfcdiff-latest-json'" >> at/config.py
echo "ALLOWED_DOMAINS = ['ietf.org', 'ietf.org', 'rfc-editor.org']" >> at/config.py
PATH=$PATH:./node_modules/.bin/ python docker/version.py >> at/config.py
  • Run flask server.
SITE_URL='http://localhost:5000' PATH=$PATH:./node_modules/.bin/ FLASK_APP=at FLASK_DEBUG=True flask run

Running tests

  • Install required dependencies for testing.
pip install -r requirements.dev.txt
  • Run unit tests.
PATH=$PATH:./node_modules/.bin/ python -m unittest discover tests