Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parsec GO Client Initial API #5

Merged
merged 34 commits into from
Jan 26, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
897cadb
Add Apache license file
justincormack Oct 8, 2019
9ca58ed
Fix README link
daxmc99 Mar 26, 2020
a6c51b7
Initial basic client api for comment.
jn9e9 Nov 9, 2020
84224b5
add to readme
jn9e9 Jan 21, 2021
69fa5ca
remove intermediate proto files
jn9e9 Jan 21, 2021
073eacb
fix shellcheck errors on ci-build scripts
jn9e9 Jan 21, 2021
853675e
add gitignore for intermediate proto files
jn9e9 Jan 21, 2021
eadbca2
fix ci test running and add github action
jn9e9 Jan 21, 2021
a440321
fix ci test running
jn9e9 Jan 22, 2021
540ce17
fix ci test running and add github action
jn9e9 Jan 21, 2021
6f2d404
fix ci test running
jn9e9 Jan 22, 2021
ff31181
misc tidy up of folder structure and readme
jn9e9 Jan 25, 2021
f7779ef
move parsec-operations submodule to interface folder
jn9e9 Jan 25, 2021
b5578e0
refactor wireinterface folder to interface
jn9e9 Jan 25, 2021
1c28b15
refactor wireinterface folder to interface
jn9e9 Jan 25, 2021
4af6195
refactor algorithm package to live under /parsec
jn9e9 Jan 25, 2021
cea6107
refactor algorithm package to live under /parsec
jn9e9 Jan 25, 2021
11056a0
move basic client to /parsec folder
jn9e9 Jan 25, 2021
0840131
e2e readme
jn9e9 Jan 25, 2021
5f6d4c7
add readme for interface folder
jn9e9 Jan 25, 2021
2a5a25c
adding package/folder documentation
jn9e9 Jan 25, 2021
9ae05ba
fix links in readme
jn9e9 Jan 25, 2021
436f5f5
fix links in readme
jn9e9 Jan 25, 2021
71219a0
change warning note
jn9e9 Jan 25, 2021
e4763d7
updated readme urls for parallaxsecond user on gitlab - broken on jn9e9
jn9e9 Jan 25, 2021
63b891b
move ci.sh to e2etest folder
jn9e9 Jan 25, 2021
9acdee5
add shell invocation of ci test
jn9e9 Jan 25, 2021
7ca6115
refactored e2etest script files to e2etest/scripts
jn9e9 Jan 26, 2021
a378947
fix formatting on licence list
jn9e9 Jan 26, 2021
126c693
Add parsec to api comment
jn9e9 Jan 26, 2021
8fae4e5
Merge branch 'master' of https://github.com/parallaxsecond/parsec-cli…
jn9e9 Jan 26, 2021
84f4814
fix ci-all.sh script path
jn9e9 Jan 26, 2021
9002463
change makefile lint to golangci-lint
jn9e9 Jan 26, 2021
67f82d0
fix lint errors on test code
jn9e9 Jan 26, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 77 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
# Copyright 2021 Contributors to the Parsec project.
# SPDX-License-Identifier: Apache-2.0
name: Build and Test
on:
push:
branches:
- master
pull_request:

jobs:
# lint:
# name: Lint
# runs-on: ubuntu-latest
# steps:
# - name: Set up Go
# uses: actions/setup-go@v1
# with:
# go-version: 1.15

# - name: Check out code
# uses: actions/checkout@v1

# - name: Lint Go Code
# run: |
# export PATH=$PATH:$(go env GOPATH)/bin # temporary fix. See https://github.com/actions/setup-go/issues/14
# go get -u golang.org/x/lint/golint
# make lint
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
version: v1.35.2

test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Set up Go
uses: actions/setup-go@v1
with:
go-version: 1.15

- name: Check out code
uses: actions/checkout@v1
- name: Checkout submodules
uses: textbook/git-checkout-submodule-action@master

- name: Run Unit tests.
run: make test-coverage

- name: Upload Coverage report to CodeCov
uses: codecov/codecov-action@v1.0.0
with:
token: ${{secrets.CODECOV_TOKEN}}
file: ./coverage.txt
build:
name: Build
runs-on: ubuntu-latest
needs: [golangci, test]
steps:
- name: Set up Go
uses: actions/setup-go@v1
with:
go-version: 1.15

- name: Check out code
uses: actions/checkout@v1
- name: Checkout submodules
uses: textbook/git-checkout-submodule-action@master

- name: Build
run: make build
12 changes: 12 additions & 0 deletions .github/workflows/ci-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Continuous Integration

on: [push, pull_request]

jobs:
all-providers:
name: Various tests targeting a Parsec image with all providers included
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Run CI Tests
run: ./e2etest/scripts/ci-all.sh
50 changes: 50 additions & 0 deletions .github/workflows/codacy-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Copyright 2021 Contributors to the Parsec project.
# SPDX-License-Identifier: Apache-2.0


# This workflow checks out code, performs a Codacy security scan
# and integrates the results with the
# GitHub Advanced Security code scanning feature. For more information on
# the Codacy security scan action usage and parameters, see
# https://github.com/codacy/codacy-analysis-cli-action.
# For more information on Codacy Analysis CLI in general, see
# https://github.com/codacy/codacy-analysis-cli.

name: Codacy Security Scan

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
codacy-security-scan:
name: Codacy Security Scan
runs-on: ubuntu-latest
steps:
# Checkout the repository to the GitHub Actions runner
- name: Checkout code
uses: actions/checkout@v2

# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis
- name: Run Codacy Analysis CLI
uses: codacy/codacy-analysis-cli-action@1.1.0
with:
# Check https://github.com/codacy/codacy-analysis-cli#project-token to get your project token from your Codacy repository
# You can also omit the token and run the tools that support default configurations
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
verbose: true
output: results.sarif
format: sarif
# Adjust severity of non-security issues
gh-code-scanning-compat: true
# Force 0 exit code to allow SARIF file generation
# This will handover control about PR rejection to the GitHub side
max-allowed-issues: 2147483647

# Upload the SARIF file generated in the previous step
- name: Upload SARIF results file
uses: github/codeql-action/upload-sarif@v1
with:
sarif_file: results.sarif
72 changes: 72 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# Copyright 2021 Contributors to the Parsec project.
# SPDX-License-Identifier: Apache-2.0


# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
# ******** NOTE ********

name: "CodeQL"

on:
push:
branches: [ master ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ master ]
schedule:
- cron: '44 22 * * 6'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
language: [ 'go' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
# Learn more...
# https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection

steps:
- name: Checkout repository
uses: actions/checkout@v2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
39 changes: 39 additions & 0 deletions .github/workflows/shiftleft-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Copyright 2021 Contributors to the Parsec project.
# SPDX-License-Identifier: Apache-2.0

# This workflow integrates Scan with GitHub's code scanning feature
# Scan is a free open-source security tool for modern DevOps teams from ShiftLeft
# Visit https://slscan.io/en/latest/integrations/code-scan for help
name: SL Scan

# This section configures the trigger for the workflow. Feel free to customize depending on your convention
on: push

jobs:
Scan-Build:
# Scan runs on ubuntu, mac and windows
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
# Instructions
# 1. Setup JDK, Node.js, Python etc depending on your project type
# 2. Compile or build the project before invoking scan
# Example: mvn compile, or npm install or pip install goes here
# 3. Invoke Scan with the github token. Leave the workspace empty to use relative url

- name: Perform Scan
uses: ShiftLeftSecurity/scan-action@master
env:
WORKSPACE: ""
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SCAN_AUTO_BUILD: true
with:
output: reports
# Scan auto-detects the languages in your project. To override uncomment the below variable and set the type
# type: credscan,java
# type: python

- name: Upload report
uses: github/codeql-action/upload-sarif@v1
with:
sarif_file: reports
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
.vscode
...
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "interface/parsec-operations"]
path = interface/parsec-operations
url = https://github.com/parallaxsecond/parsec-operations
Loading