Git Product home page Git Product logo

eu-dcc-validation's Introduction

EU DCC Validation process

Issues License Discussions Live Demo

The purpose of this initiative is the automation of the EU DCC validation process.

Introduction

Validation Cycle

During the “Validation Cycle” the member states are using their Verifier App and scan the DCCs in the Quality Assurance repository.

  • The scanning process will still take place manually. The suggested, in this place, tools would aim to make it easier and will automate the collections, distribution, and analysis of the results.

Validation Portal

The creation of a Validation Portal is suggested which will:

  • Allow easy navigation to all reference QR codes.
  • Capture the results from the countries in a comfortable way.
  • Export the results in a standard JSON format.

Wire 01

Wire 02

Validation Flow

  1. The interface pulls the QR codes from GitHub and displays them one by one.
  2. The user can navigate between the QR codes by using the Previous/Next buttons. The QR codes are also available in a list grouped by Country
  3. The user uses the Verifier app and scans the QR Code in the display.
  4. If the Scan gives no errors the user presses the Green (Passed) button.
  5. If the Scan gives errors or warning the user fills in a copy describing the situation and pressed the amber or red button respectively.

Automation

  1. The user registers once the MS who uses the Verifier app for.
  2. The application keeps track of all the submitted data and relates them with the QR Codes.
  3. The application exports the captured results in JSON.
  4. The application would provide the option for the user to take a photo of the verifier app showing the error message. The application will store these images and will relate them to the results.

Result format

Test results are provided one json file per platform.

{
	metadata: {
		country: "XX",
		date-completed: "20220120T102611Z",
		commit-tested: "4699f4b13a1010d10d9c4f80eac59beec5cbb613",
		platform-tested: "IOS|ANDROID"
	},
	results: [{
		"file": "NL/1.3.0/REC.png",		
		"result": "Valid|Invalid|Error",
		"comment": "Free text"
	},{
		"file": "NL/1.3.0/REC.png",		
		"result": "Valid|Invalid|Error",
		"comment": "Free text"	
	}]
}
  • metadata: contains various metadata.

  • ``: country code, iso-two-letter code

  • ``: date the test was completed, in ISO8601 UTC

  • ``: git hash of the commit tested

  • ``: platform the tests were done on

  • results: contains an array of results, one per file

  • file: the relative path to the test file from the root of the QA repository. this path is returned by the github API if you use that.

  • result: the test result, Valid for valid, Invalid if the DCC was scanned but deemed invalid, Error if the DCC did not scan.

  • comment: optional free text explaining the result if it isn't Valid

The file name contains the country code, the test date and the platform:

YYYYDDMM-XX-PLATFORM.json

So for NL tests conducted on 2022-01-17 you have these two files (for both platforms):

20220117-NL-ANDROID.json
20220117-NL-IOS.json

Schema

The results.json should satisfy the results.schema.json

Client / Server architecture

Client / Server

Planning and Roadmap

Visit the EU DCC Validation Planning project

Development instructions

This project was generated with Angular CLI version 13.1.3.

Development server

Run ng serve for a dev server. Navigate to http://localhost:4200/. The app will automatically reload if you change any of the source files.

Code scaffolding

Run ng generate component component-name to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module.

Build

Run ng build to build the project. The build artifacts will be stored in the dist/ directory.

Running unit tests

Run ng test to execute the unit tests via Karma.

Running end-to-end tests

Run ng e2e to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.

Further help

To get more help on the Angular CLI use ng help or go check out the Angular CLI Overview and Command Reference page.

CI/CD

The application is automatically deployed on Firebase:

Discussion

Have an idea, a question or a comment to share?

Contributors

Made with contrib.rocks.

Licensing

Copyright (c) 2022 Stavros Kounis (Directorate-General CONNECT), Ryan Barrett (Dutch Ministry of Health, Science, and Sports), Sofia Atsalou and all other contributors

Licensed under the EUROPEAN UNION PUBLIC LICENCE v. 1.2 (the "License"); you may not use this file except in compliance with the License.

You may obtain a copy of the License at https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the LICENSE for the specific language governing permissions and limitations under the License.

eu-dcc-validation's People

Contributors

bernhard-baeuerle-tsi avatar ryanbnl avatar satsalou avatar skounis avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

eu-dcc-validation's Issues

Prepare a copy for the upload instructions

Describe the bug, issue or concern

When the user finishes with the tests a dialog gives access to the results.json file and provides further details.

We need to prepare the final copy for this dialog with detailed and accurate instructions

image

Reduce the minimum real estate required

Make the application need less real estate and reduce the need for scrolling

  1. Use less space. Take out the noise.
  2. Use Grid layout and keep the panel in the same place, if possible.

Scaffold data access layer and state management

Mock JSON data:

[
  {
    "country": "EL",
    "title": "Vaccination",
    "qrcode": "https://raw.githubusercontent.com/eu-digital-green-certificates/dcc-quality-assurance/main/EL/1.3.0/VAC.png"
  },
  {
    "country": "EL",
    "title": "Recovery",
    "qrcode": "https://raw.githubusercontent.com/eu-digital-green-certificates/dcc-quality-assurance/main/EL/1.3.0/VAC.png"
  },
  {
    "country": "EL",
    "title": "Test",
    "qrcode": "https://raw.githubusercontent.com/eu-digital-green-certificates/dcc-quality-assurance/main/EL/1.3.0/VAC.png"
  }
]

Request initial input on start up

When the application start should request from the user mandatory details as

  1. Platform
  2. Country
  3. Advanced
    • GitHub API auth credentials

Upload screen

Provide a screen where users can upload completed test results + submit them to the backend over the API, together with their authentication token.

Review by Herbert

A couple of comments more

  1. The script should force the user to select the platform (iOS, Android, other) before starting the test and fix it
    Alternatively: Does it make sense to include for each entry the platform since a user may want to change in between (intentionally or accidentally)? - #66
  2. A user shall be forced to enter a comment in case of an error or in case of invalidity - #72
  3. In case the browser is closed accidentally results are not stored(?) so a user needs to start from scratch. Any chance to automatically store the current status and allow users to continue when the browser has been closed? - #73

Capture the Platform and the Country

The user should be able to provide/set the country and the platform for which the test results are captured.

The details should make it to the generated results.json

Restore the state when the application restarts

In case the browser is closed accidentally results are not stored(?) so a user needs to start from scratch. Any chance to automatically store the current status and allow users to continue when the browser has been closed?

Decorate the QR Codes - Communication validation status

While users are browsing and validating QR codes, the application should communicate the status of each and the overall progress:

  1. Number of validations pending
  2. Number of validations submitted
  3. QR outcome submitted.

Tasks

  1. Scaffold the UX
  2. Implement and apply a decorator to the QR Codes displayed
  3. Provide summary and progress details.

Align Interface and Schema

As per #2 (comment)

  • ITestResultMetadata has completedOn field while schema has dateCompleted field.
  • Corresponding dateCompleted field doesn't have a format in the schema.
  • Corresponding platform field has an enum type in TS, but not in the schema.
  • result field (corresponding to ITestResultEntry) has an enum type in TS, but not in the schema.

Load the QRCodes from GitHub

Describe the bug, issue or concern

We need to query the dcc-quality-assurance repository and get all the DCC uploaded for QA

Snippet:

import { Injectable } from '@angular/core';
import { HttpClient } from '@angular/common/http';
​
export interface MyTree {
  path: string;
  mode: string;
  type: string;
  size: number;
  url: string;
}
​
@Injectable({
  providedIn: 'root'
})
export class GithubService {githubApiUrl = "https://api.github.com/repos/eu-digital-green-certificates/dcc-quality-assurance/git/trees/main?recursive=1";constructor(private http: HttpClient) { }
  
  getTree() {
    return this.http.get<MyTree>(this.githubApiUrl, {
      headers: {
        "Accept": "application/vnd.github.v3+json"
      }
    });
  }getImage() {
    // https://api.github.com/repos/eu-digital-green-certificates/dcc-quality-assurance/git/blobs/07984193650c3aa1a3f4ad16208cf7829f833b0c
  }
}

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.