Skip to content

Commit

Permalink
Merge pull request #412 from 0xPolygonID/develop
Browse files Browse the repository at this point in the history
SDK Release 2.3.1 PR
  • Loading branch information
Emanuel Muroni authored May 9, 2024
2 parents 5f806b4 + 382656d commit 552de4f
Show file tree
Hide file tree
Showing 156 changed files with 1,871 additions and 1,434 deletions.
7 changes: 7 additions & 0 deletions .gitguardian.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: 2

secret:
ignored_paths:
- 'lib/constants.dart'
- .gitignore
- '**/README.md'
110 changes: 0 additions & 110 deletions .github/workflows/polygonid_flutter_sdk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Clean, dependencies and generate for Example
env:
ENV_POLYGON_MUMBAI: ${{ secrets.ENV_POLYGON_MUMBAI }}
ENV_POLYGON_MAINNET: ${{ secrets.ENV_POLYGON_MUMBAI }}
DEFAULT_ENV: ${{ secrets.DEFAULT_ENV }}
STACKTRACE_ENCRYPTION_KEY: ${{ secrets.STACKTRACE_ENCRYPTION }}
PINATA_GATEWAY: ${{ secrets.PINATA_GATEWAY }}
Expand All @@ -57,114 +55,6 @@ jobs:
with:
token: ${{ secrets.CODECOV_TOKEN }}

# job responsible for running Flutter tests on iOS devices
ios:
# needs: common
# Creates a build matrix for your jobs. You can define different variations of an environment to run each job
strategy:
matrix:
device:
# The available simulators are listed by the "xcrun xctrace list devices" command
- "iPhone 13 Pro Max Simulator (16.2)" # the name of the simulator could be different depending on the macos version you are using
# if one of the jobs in the matrix expansion fails, the rest of the jobs will be cancelled
fail-fast: true
runs-on: macos-latest # or macos-latest if you prefer, but be aware that the available simulators could be different if you run a different version
steps:
- name: checkout
uses: actions/checkout@v3

- name: Setup Flutter SDK
uses: subosito/flutter-action@v2
with:
flutter-version: '3.19.3'
channel: 'stable'
cache: true
# instead of "channel: stable", you could be more precise by specifying the exact version of Flutter you're using:
# flutter-version: '<FLUTTER_VERSION>'

- name: Verify Flutter version
run: flutter --version

- name: Clean, dependencies and generate for SDK
run: flutter clean&&flutter pub get&&dart run build_runner build --delete-conflicting-outputs

- name: Clean, dependencies and generate for Example
env:
ENV_POLYGON_MUMBAI: ${{ secrets.ENV_POLYGON_MUMBAI }}
ENV_POLYGON_MAINNET: ${{ secrets.ENV_POLYGON_MUMBAI }}
run: cd example&&flutter clean&&flutter pub get&&dart run build_runner build --delete-conflicting-outputs

- name: "List all simulators"
run: "xcrun xctrace list devices"
- name: "Start Simulator"
# the command "xcrun simctl boot" expects a device identifier
# the assignment of the UDID variable consists of retrieving the ID of the simulator
# by extracting it from the command "xcrun xctrace list devices"
run: |
UDID=$(xcrun xctrace list devices | grep "^${{ matrix.device }}" | awk '{gsub(/[()]/,""); print $NF}')
echo $UDID
xcrun simctl boot "${UDID:?No Simulator with this name found}"
#- name: Run integration tests
# run: cd example&&flutter test integration_test/libpolygonid_test.dart --verbose

# job responsible for running Flutter tests on Android devices
# android:
# needs: common
# runs-on: macos-latest
# strategy:
# matrix:
# api-level: [ 32 ] #[ 21, 23, 29, 32 ]
# target: [ google_apis ] #[ default, google_apis ]
# if one of the jobs in the matrix expansion fails, the rest of the jobs will be cancelled
# fail-fast: true
# steps:
# - name: Setup Java
# uses: actions/setup-java@v3
# with:
# distribution: 'zulu'
# java-version: "12.x"
# cache: 'gradle'

# - name: Gradle cache
# uses: gradle/gradle-build-action@v2

# - name: AVD cache
# uses: actions/cache@v3
# id: avd-cache
# with:
# path: |
# ~/.android/avd/*
# ~/.android/adb*
# key: avd-${{ matrix.api-level }}

# - name: create AVD and generate snapshot for caching
# if: (github.base_ref == 'develop' || github.base_ref == 'main') && steps.avd-cache.outputs.cache-hit != 'true'
# uses: reactivecircus/android-emulator-runner@v2
# with:
# api-level: ${{ matrix.api-level }}
# target: ${{ matrix.target }}
# force-avd-creation: false
# emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
# disable-animations: false
# arch: x86_64
# profile: Nexus 6
# script: echo "Generated AVD snapshot for caching."

#- name: Run integration tests
# if: github.base_ref == 'develop' || github.base_ref == 'main'
# more info on https://github.com/ReactiveCircus/android-emulator-runner
# uses: reactivecircus/android-emulator-runner@v2
# with:
# api-level: ${{ matrix.api-level }}
# target: ${{ matrix.target }}
# force-avd-creation: false
# emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
# disable-animations: true
# arch: x86_64
# profile: Nexus 6
# script: cd example&&flutter test integration_test/libpolygonid_test.dart --verbose

# job responsible for publishing the package to pub.dev
# enable it once published for the first time on pub.dev otherwise it will fail
#publish:
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## 2.3.1
- Added support for LinkedMultiQuery Circuit
- Problem report message object
- Fix for $exists operator
- Fix for linked proofs
- Fix for refresh credential while creating a proof with an expired credential (refresh service is needed)

## 2.3.0
- New operators for circuit V3 beta 1
- On-chain credential fetch
Expand Down
1 change: 0 additions & 1 deletion LICENSE-APACHE
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
Copyright (C) 2023 ZKID Labs AG
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@

# Polygon ID Flutter SDK

[![pub package](https://img.shields.io/badge/pub-2.3.0-blueviolet)](https://pub.dev/packages/polygonid_flutter_sdk)
[![pub package](https://img.shields.io/badge/pub-2.3.1-blueviolet)](https://pub.dev/packages/polygonid_flutter_sdk)
[![build](https://github.com/iden3/polygonid-flutter-sdk/workflows/polygonid_flutter_sdk/badge.svg)](https://github.com/iden3/polygonid-flutter-sdk/actions?query=workflow%3Apolygonid_flutter_sdk)
[![codecov](https://codecov.io/gh/iden3/polygonid-flutter-sdk/branch/develop/graph/badge.svg?token=0SI0XWGXKL)](https://codecov.io/gh/iden3/polygonid-flutter-sdk)
[![license](https://img.shields.io/badge/license-Apache--2.0-blue.svg)](https://github.com/iden3/polygonid-flutter-sdk/blob/master/LICENSE-APACHE)
[![license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/iden3/polygonid-flutter-sdk/blob/master/LICENSE-MIT)

# Breaking change
The content of the QR code provided by the Issuer or Verifier will change with the actual release of the [Issuer node](https://github.com/0xPolygonID/issuer-node/releases/tag/v2.3.0).
The content of the QR code provided by the Issuer or Verifier will change with the actual release of the [Issuer node](https://github.com/0xPolygonID/issuer-node/releases/tag/v2.3.1).
Please check the [IDEN3MESSAGE_PARSER.md](IDEN3MESSAGE_PARSER.md) file for more information on how to parse the new QR code content.

## Description
Expand Down Expand Up @@ -57,7 +57,7 @@ import 'package:polygonid_flutter_sdk/sdk/polygon_id_sdk.dart';
Future<void> main() async {
await PolygonIdSdk.init(
env: EnvEntity.v1(
env: EnvEntity(
pushUrl: 'https://push-staging.polygonid.com/api/v1',
ipfsUrl:
"https://[YOUR-IPFS-API-KEY]:[YOUR-IPFS-API-KEY-SECRET]@ipfs.infura.io:5001",
Expand Down
2 changes: 1 addition & 1 deletion android/sdk.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
ext {
sdkVersion = '2.3.0'
sdkVersion = '2.3.1'
}
5 changes: 5 additions & 0 deletions android/src/main/jniLibs/arm64-v8a/libpolygonid.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,11 @@ extern GoUint8 PLGNAtomicQueryV3Inputs(char** jsonResponse, char* in, char* cfg,
// credentialAtomicQueryV3OnChain circuit with optional selective disclosure.
//
extern GoUint8 PLGNAtomicQueryV3OnChainInputs(char** jsonResponse, char* in, char* cfg, PLGNStatus** status);

// PLGNALinkedMultiQueryInputs returns the inputs for the
// linkedMultiQuery10-beta.1 circuit.
//
extern GoUint8 PLGNALinkedMultiQueryInputs(char** jsonResponse, char* in, char* cfg, PLGNStatus** status);
extern void PLGNFreeStatus(PLGNStatus* status);
extern GoUint8 PLGNCleanCache(PLGNStatus** status);
extern GoUint8 PLGNCacheCredentials(char* in, char* cfg, PLGNStatus** status);
Expand Down
Binary file modified android/src/main/jniLibs/arm64-v8a/libpolygonid.so
Binary file not shown.
Binary file not shown.
5 changes: 5 additions & 0 deletions android/src/main/jniLibs/armeabi-v7a/libpolygonid.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,11 @@ extern GoUint8 PLGNAtomicQueryV3Inputs(char** jsonResponse, char* in, char* cfg,
// credentialAtomicQueryV3OnChain circuit with optional selective disclosure.
//
extern GoUint8 PLGNAtomicQueryV3OnChainInputs(char** jsonResponse, char* in, char* cfg, PLGNStatus** status);

// PLGNALinkedMultiQueryInputs returns the inputs for the
// linkedMultiQuery10-beta.1 circuit.
//
extern GoUint8 PLGNALinkedMultiQueryInputs(char** jsonResponse, char* in, char* cfg, PLGNStatus** status);
extern void PLGNFreeStatus(PLGNStatus* status);
extern GoUint8 PLGNCleanCache(PLGNStatus** status);
extern GoUint8 PLGNCacheCredentials(char* in, char* cfg, PLGNStatus** status);
Expand Down
Loading

0 comments on commit 552de4f

Please sign in to comment.