diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..83163ea --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,32 @@ +--- +name: Bug report +about: Create a report to help us improve +title: "[ISSUE]" +labels: '' +assignees: '' + +--- + +**Describe the bug** +A clear and concise description of what the bug is. + +**To Reproduce** +Steps to reproduce the behavior: +1. Go to '...' +2. Click on '....' +3. Scroll down to '....' +4. See error + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Desktop (please complete the following information):** + - OS: [e.g. ubuntu, macOS] + - Python version: [e.g. 3.7.1] + - Makefile installation: [Yes/No] + +**Additional context** +Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..524940e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,20 @@ +--- +name: Feature request +about: Suggest an idea for this project +title: "[FR]" +labels: enhancement +assignees: '' + +--- + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context or screenshots about the feature request here. diff --git a/.github/ISSUE_TEMPLATE/task.md b/.github/ISSUE_TEMPLATE/task.md new file mode 100644 index 0000000..f1d26b9 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/task.md @@ -0,0 +1,18 @@ +--- +name: Task +about: For setting project tasks +title: '' +labels: '' +assignees: '' + +--- + +Your main task exists here. This task should be: + +- Small and manageable, not extensive and cannot feasibly end +- Assigned to one or more people +- Given a label that best categorises the task (make a new label if a suitable one does not exist) +- Assigned to the correct stage of the project life-cycle (Discovery, Delivery or Dissemination) +- Uses milestones to assign to the correct sprint + +If the task can be divided into miniature sub-tasks, use `- [ ] subtask` to create a checklist. diff --git a/.github/ISSUE_TEMPLATE/use_query.md b/.github/ISSUE_TEMPLATE/use_query.md new file mode 100644 index 0000000..0cf948c --- /dev/null +++ b/.github/ISSUE_TEMPLATE/use_query.md @@ -0,0 +1,22 @@ +--- +name: Use query +about: Ask a question about this project +title: "[QUERY]" +labels: '' +assignees: '' + +--- + +**Describe what you are trying to do** +A clear and concise description of what you expected to happen. + +**Which parts of the manual are unclear?** +If applicable, add screenshots to help explain your problem. + +**Desktop (please complete the following information):** + - OS: [e.g. ubuntu, macOS] + - Python version: [e.g. 3.7.1] + - Makefile installation: [Yes/No] + +**Additional context** +Add any other context about the problem here. diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..cb83a8e --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,39 @@ +# Description + +Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. + +Fixes # (issue) + +## Type of change + +Please delete options that are not relevant. + +- [ ] Bug fix (non-breaking change which fixes an issue) +- [ ] New feature (non-breaking change which adds functionality) +- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) +- [ ] This change requires a documentation update + +# How Has This Been Tested? + +Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration + +- [ ] Test A +- [ ] Test B + +**Test Configuration**: +* Python version: +* OS: +* Python management system: +* Makefile version: + + +# Checklist: + +- [ ] My code follows the intended structure of this project +- [ ] I have performed a self-review of my own code +- [ ] I have commented my code, particularly in hard-to-understand areas +- [ ] I have made corresponding changes to the documentation +- [ ] My changes generate no new warnings +- [ ] I have added tests that prove my fix is effective or that my feature works +- [ ] New and existing unit tests pass locally with my changes (using make test if available) +- [ ] Any dependent changes have been merged and published in downstream modules diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..ced3cd7 --- /dev/null +++ b/.gitignore @@ -0,0 +1,22 @@ +# named files +.DS_Store +.pyre_configuration +Pipfile +Pipfile.lock + + +# named directories +.idea +__pycache__ +.pyre +.couscous +.hypothesis + + +# wildcards +*.log +models/*.bin +models/*.vec +data/* +.mypy* +output/* diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..3d3f996 --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,76 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, sex characteristics, gender identity and expression, +level of experience, education, socio-economic status, nationality, personal +appearance, race, religion, or sexual identity and orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or + advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic + address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or +reject comments, commits, code, wiki edits, issues, and other contributions +that are not aligned to this Code of Conduct, or to ban temporarily or +permanently any contributor for other behaviors that they deem inappropriate, +threatening, offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported by contacting the project team at myogibo@gmail.com. All +complaints will be reviewed and investigated and will result in a response that +is deemed necessary and appropriate to the circumstances. The project team is +obligated to maintain confidentiality with regard to the reporter of an incident. +Further details of specific enforcement policies may be posted separately. + +Project maintainers who do not follow or enforce the Code of Conduct in good +faith may face temporary or permanent repercussions as determined by other +members of the project's leadership. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, +available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html + +[homepage]: https://www.contributor-covenant.org + +For answers to common questions about this code of conduct, see +https://www.contributor-covenant.org/faq diff --git a/CONTRIBUTING b/CONTRIBUTING new file mode 100644 index 0000000..51f77f8 --- /dev/null +++ b/CONTRIBUTING @@ -0,0 +1 @@ +Guidelines pending diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..b4ad17e --- /dev/null +++ b/LICENSE @@ -0,0 +1,9 @@ +MIT License + +Copyright (c) 2019 Data Science Campus + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..303cda6 --- /dev/null +++ b/README.md @@ -0,0 +1,185 @@ +# skeletor +## A Project Template for Data Science Campus Projects + +### 1. Introduction + +This repository is intended to provide you with the documents you need to +include to get a repository started and give guidance as to what the contents +should be. The minimum content contained in the README.md for your project +should be (in the most suitable order for the content): + +- description of what the project is +- instruction on how to install the tool (if applicable) +- detailed instructions on basic use +- a demo of the code + +With the inclusion of all documents included here, your repository should meet +all of the recommended [community standards on github.com](https://help.github.com/en/categories/building-a-strong-community). + +Once you have copied this directory you should replace the content of this file +with the description of your work. + +Whilst no mandatory recommendation is made as to how to +structure the directories or manage the project itself - as this will vary based +on the needs and the abilities of those doing the development work - guidelines +are provided below on how to conduct your project in an Agile manner. + +If your project is complex enough to warrant a documentation website please add +a branch called `gh_pages` and place your documentation (in html format) there. +Once you do this your html files will be rendered at +https://datasciencecampus.github.io/projectName + +### 2. Use + +There are two ways to use this template: + +#### 2.1. Using GitHub (simple method) + +At the top of the main page of this repo is a green [Use this template](https://github.com/datasciencecampus/skeletor/generate) button, which +will clone this repository into a new repository of your choice. This will also copy over label templates. + +#### 2.2. Using Git + +Create your new repository with a suitable projectName. + +Clone this template to the new repository using + +``` sh +git clone git@github.com:datasciencecampus/skeletor projectName +``` + +which will then create a new directory with your project's name and place all of +the files into it. However, the remote address will remain as the skeletor repo +until you do + +``` sh +git remote set-url origin git@github.com:datasciencecampus/projectName +``` + +### 3. Using GitHub for Project Management + +All updates for a project must still be included in the relevant [issue on the main project kanban board](https://github.com/orgs/datasciencecampus/projects/21). +These guidelines relate to the project repository that you created using the above guidelines. + +#### 3.1. Projects + +This repository shows three projects in the [Project panel](https://github.com/datasciencecampus/skeletor/projects): +Discovery, Delivery and Dissemination. These projects are setup based on the Campus' project life-cycle and each use a kanban board +(To do, In Progress, Done). Issues (tasks) should be assigned to the relevant stage of the project life-cycle. + +Setup a project board using the 'automated Kanban' template style for each. + +#### 3.2. Issues + +This GitHub template comes with four [Issue templates](https://github.com/datasciencecampus/skeletor/issues/new/choose): +Bug report, Feature request, Use query and Task. The first three are normally used when the repository and tool has been made public. + +The [Task issue template](https://github.com/datasciencecampus/skeletor/issues/new?assignees=&labels=&template=task.md&title=) +should be used to create tasks during the project. Issues (tasks) can be created and assigned ad-hoc, or during stand-ups. + +#### 3.3. Milestones + +[GitHub Milestones](https://github.com/datasciencecampus/skeletor/milestones) can be used to assign tasks to a sprint cycle. +By assigning a task to a Project and a Milestone, progress on individual sprints as well as stages of the project life-cycle +can be viewed by the project manager and delivery manager. Milestones should be given due dates, and then all tasks assigned to this +milestone can be reviewed at the end of the sprint cycle. + +#### 3.4. Labels + +The [generic GitHub labels are limited in their use](https://medium.com/@dave_lunny/sane-github-labels-c5d2e6004b63), +this repository has additional [labels](https://github.com/datasciencecampus/skeletor/labels): + +- Priority: Low +- Priority: Medium +- Priority: High +- Priority: Critical +- Project: Background Research +- Project: Data and Methods +- Project: Ethical Review +- Project: Stakeholder Engagement +- Project: Technical Plan +- Status: Abandoned +- Status: Accepted +- Status: Available +- Status: Blocked +- Status: Completed +- Status: In Progress +- Status: On Hold +- Status: Pending +- Status: Review Needed +- Status: Revision Needed +- Type: Bug +- Type: Maintenance +- Type: Enhancement +- Type: Question + +To setup these labels do the following: + +``` +npm i -g git-labelmaker +cd projectName +git-labelmaker +``` + +Then go to 'Add labels from package' and then type: + +``` +packages/custom-labels.json +``` + +The 'Project' labels encompass the majority of Discovery tasks. However, add more labels if you need (either manually or to the JSON file). +Whereas Issues are small, manageable tasks, Labels are meant to be broad. Using labels shows where the +majority of the time is being spent on projects by the project manager and delivery manager. + +#### 3.5. Example + +For a new project, first clone this repository using the steps in section 2. Then setup the three stages +of the project life cycle as described in section 3.2, and then add the first sprint as a milestone (section 3.3). +Next, to add the custom labels, follow the steps in section 3.4. Then begin to add tasks. + +The first task in the Discovery phase may be to ask within the Campus' whether anyone has done any similar +or relevant work in the past. Therefore setup an Issue using the [Task template](https://github.com/datasciencecampus/skeletor/issues/new?assignees=&labels=&template=task.md&title=), which may be titled 'Ask within Campus about previous relevant work'. +Assign this task to the relevant person, add the label of 'Project: Background Research', +assign to the project 'Discovery' and assign to Sprint 1 in the Milestone section. + +Once this task has been completed, close this Issue. The closure of this Issue will then increase +the progress bar on both the Milestone and Project. + +#### 3.6. Benefits + +- This will aid delivery and project managers to see the progress of projects in the project life-cycle +- a comprehensive use of an 'issue' in GitHub will allow delivery and project managers to filter tasks to assign additional resource +- use of the projects board for each stage of the life-cycle will allow users to quickly see what stage a project is in +- it facilitates agile working in sprints + +### 4. Contents + +* **CODE_OF_CONDUCT.md**: a statement from the [Contributor + Covenant](https://contributor-covenant.org) regarding what is and isn't + acceptable behaviour for contributors +* **CONTRIBUTING**: guidelines for how contributions should be made to the work, + this is currently empty but should contain information such as code + formatting, how to add test fixes and how to submit patches. There is a very + good + [example](https://github.com/puppetlabs/puppet/blob/master/CONTRIBUTING.md) + from the puppet repo by puppetlabs. Because all of our teams will be varied in + terms of size, skills and project aims it is left to each project to define + this. +* **README.md**: this document, every repository should have one and it acts as + the main landing page for your repository +* **LICENSE**: the UK public sector usually operate under two different + licensing schemes. The most common for code is the MIT license which is + included in this repo. Alternatively there is an Open Government license and + a description of what OpenGov enforces can be found + [here](https://www.nationalarchives.gov.uk/doc/open-government-licence/version/3/). +* **.github**: this directory allows the user to specify templates for + contribution types, included in this repository are a bug fix submission + template, a feature request template and a pull request template. Each of them + includes a series of tickboxes which you can use to help you decide whether or + not the submission is suitable. +* **.gitignore**: this file allows you to specify which directories, files and + globbed file types are to be ignored as part of the diffs being managed by + git. This allows you to have your data in the same directory structure as your + code without it needing to be pushed and pulled along with it. If you have + data which you do need to manage I would highly advise the use of `git-annex` + ahead of including data files in your repository (unless they are small). diff --git a/packages/custom-labels.json b/packages/custom-labels.json new file mode 100644 index 0000000..42cf7e4 --- /dev/null +++ b/packages/custom-labels.json @@ -0,0 +1,32 @@ +[ + { "name": "bug", "color": "#fc2929" }, + { "name": "duplicate", "color": "#cccccc" }, + { "name": "enhancement", "color": "#84b6eb" }, + { "name": "help wanted", "color": "#159818" }, + { "name": "invalid", "color": "#e6e6e6" }, + { "name": "question", "color": "#cc317c" }, + { "name": "wontfix", "color": "#ffffff" }, + { "name": "Priority: Low", "color": "#009800" }, + { "name": "Priority: Medium", "color": "#fbca04" }, + { "name": "Priority: High", "color": "#eb6420" }, + { "name": "Priority: Critical", "color": "#e11d21" }, + { "name": "Project: Background Research", "color": "#b6db57" }, + { "name": "Project: Data and Methods", "color": "#bfc7fc" }, + { "name": "Project: Ethical Review", "color": "#ba1027" }, + { "name": "Project: Stakeholder Engagement", "color": "#0e8a16" }, + { "name": "Project: Technical Plan", "color": "#0274ff" }, + { "name": "Status: Abandoned", "color": "#000000" }, + { "name": "Status: Accepted", "color": "#009800" }, + { "name": "Status: Available", "color": "#bfe5bf" }, + { "name": "Status: Blocked", "color": "#e11d21" }, + { "name": "Status: Completed", "color": "#006b75" }, + { "name": "Status: In Progress", "color": "#cccccc" }, + { "name": "Status: On Hold", "color": "#e11d21" }, + { "name": "Status: Pending", "color": "#fef2c0" }, + { "name": "Status: Review Needed", "color": "#fbca04" }, + { "name": "Status: Revision Needed", "color": "#e11d21" }, + { "name": "Type: Bug", "color": "#e11d21" }, + { "name": "Type: Maintenance", "color": "#fbca04" }, + { "name": "Type: Enhancement", "color": "#84b6eb" }, + { "name": "Type: Question", "color": "#cc317c" } +]