Skip to content

Commit

Permalink
Merge branch 'test' into staging
Browse files Browse the repository at this point in the history
  • Loading branch information
placek committed Oct 3, 2024
2 parents 39305f7 + a42dc05 commit 45a52d1
Show file tree
Hide file tree
Showing 58 changed files with 985 additions and 530 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build-and-deploy-test-stack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ jobs:
key: ${{ secrets.TEST_STACK_SSH_KEY }}
command_timeout: 100m ## Haskell container build takes a lot of time.
script: |
set -euo pipefail
REPO_URL="https://github.com/${{ github.repository }}"
DEST_DIR="$HOME/Documents/govtool"
Expand Down Expand Up @@ -59,9 +60,8 @@ jobs:
# Execute the build-and-deploy.sh script
cd $DEST_DIR/tests/test-infrastructure
./build-and-deploy.sh update-images
docker system prune
(docker image ls -q | xargs docker image rm --force ) || echo "Images cleaned-up"
envs: GOVTOOL_TAG, GRAFANA_ADMIN_PASSWORD, GRAFANA_SLACK_RECIPIENT, GRAFANA_SLACK_OAUTH_TOKEN, SENTRY_DSN_BACKEND, GTM_ID, NPMRC_TOKEN, SENTRY_DSN_FRONTEND, PIPELINE_URL, USERSNAP_SPACE_API_KEY, APP_ENV, PDF_API_URL
yes | docker system prune -f || echo "Ignoring system prune eror"
envs: GOVTOOL_TAG, GRAFANA_ADMIN_PASSWORD, GRAFANA_SLACK_RECIPIENT, GRAFANA_SLACK_OAUTH_TOKEN, SENTRY_DSN_BACKEND, GTM_ID, NPMRC_TOKEN, SENTRY_DSN_FRONTEND, PIPELINE_URL, USERSNAP_SPACE_API_KEY, APP_ENV, PDF_API_URL, KUBER_API_KEY
env:
GOVTOOL_TAG: ${{ github.sha }}
GRAFANA_ADMIN_PASSWORD: ${{ secrets.GRAFANA_ADMIN_PASSWORD }}
Expand All @@ -75,4 +75,4 @@ jobs:
USERSNAP_SPACE_API_KEY: ${{ secrets.USERSNAP_SPACE_API_KEY }}
APP_ENV: test
PDF_API_URL: ${{ secrets.PDF_API_URL }}
KUBER_API_KEY: ${{secrets.KUBER_API_KEY}}
KUBER_API_KEY: ${{ secrets.KUBER_API_KEY }}
2 changes: 1 addition & 1 deletion .github/workflows/merge.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,4 +169,4 @@ jobs:
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
message: |-
This PR is in the tag: ${{ env.TAG }} , for ${{ matrix.name }} service
This PR is in the tag: ${{ env.TAG }} , for ${{ matrix.name }} service
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,28 @@ changes.

-

## [v1.0.20](https://github.com/IntersectMBO/govtool/releases/tag/v1.0.20) 2024-10-03

### Added

- Add useful external links to home page and dashboard [Issue 1995](https://github.com/IntersectMBO/govtool/issues/1995)

### Fixed

- Add missing testIds for submitted votes [Issue 1875](https://github.com/IntersectMBO/govtool/issues/1875)
- Provide workaround for iOS for downloading metadata on iOS [Issue 1989](https://github.com/IntersectMBO/govtool/issues/1989)
- Fix infinite loading in DRep Directory [Issue 2090](https://github.com/IntersectMBO/govtool/issues/2090)

### Changed

- Change constitutional committee vote totals to be constitutional for yes and unconstitutional for no [Issue 2062](https://github.com/IntersectMBO/govtool/issues/2062)
- Bump @intersect.mbo/pdf-ui to v0.4.0
- Include @language property in generated jsonld files [Issue 1856](https://github.com/IntersectMBO/govtool/issues/1856)

### Removed

-

## [v1.0.19](https://github.com/IntersectMBO/govtool/releases/tag/v1.0.19) 2024-09-19

### Added
Expand Down
14 changes: 11 additions & 3 deletions gov-action-loader/frontend/src/views/SpecificLoad.vue
Original file line number Diff line number Diff line change
Expand Up @@ -72,15 +72,17 @@ import config from '../config'
<v-btn color="red-lighten-5" variant="flat" class="mt-2 ml-6"
@click="deleteTreasuryWithdrawal(index)">-</v-btn>
</div>
<div class="d-flex justify-center mb-2">
<v-btn color="blue-lighten-5" variant="flat" @click="addTreasuryWithdrawal">+</v-btn>
</div>

<v-tooltip text="Required" location="top">
<template v-slot:activator="{ props }">
<span class="text-h6 mb-2">Guardrail Script</span>
</template>
</v-tooltip>
<v-text-field label="CBOR Hex" v-model="guardrailScript" variant="outlined"></v-text-field>
<div class="d-flex justify-center">
<v-btn color="blue-lighten-5" variant="flat" @click="addTreasuryWithdrawal">+</v-btn>
</div>

</div>

<!-- Add Committee section -->
Expand Down Expand Up @@ -915,6 +917,12 @@ export default {
...(this.DRepDeposit != null ? { DRepDeposit: parseInt(this.DRepDeposit) } : {}),
...(this.DRepActivity != null ? { DRepActivity: parseInt(this.DRepActivity) } : {}),
}
proposal_data['script'] =
{
type: "PlutusScriptV3",
description: "",
cborHex: this.guardrailScript
}
break
}
Expand Down
2 changes: 1 addition & 1 deletion govtool/backend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ FROM $BASE_IMAGE_REPO:$BASE_IMAGE_TAG
WORKDIR /src
COPY . .
RUN cabal build
RUN cp dist-newstyle/build/x86_64-linux/ghc-9.2.7/vva-be-1.0.19/x/vva-be/build/vva-be/vva-be /usr/local/bin
RUN cp dist-newstyle/build/x86_64-linux/ghc-9.2.7/vva-be-1.0.20/x/vva-be/build/vva-be/vva-be /usr/local/bin
2 changes: 1 addition & 1 deletion govtool/backend/Dockerfile.qovery
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM $BASE_IMAGE_REPO:$BASE_IMAGE_TAG
WORKDIR /src
COPY . .
RUN cabal build
RUN cp dist-newstyle/build/x86_64-linux/ghc-9.2.7/vva-be-1.0.19/x/vva-be/build/vva-be/vva-be /usr/local/bin
RUN cp dist-newstyle/build/x86_64-linux/ghc-9.2.7/vva-be-1.0.20/x/vva-be/build/vva-be/vva-be /usr/local/bin

# Expose the necessary port
EXPOSE 9876
Expand Down
3 changes: 3 additions & 0 deletions govtool/backend/sql/list-dreps.sql
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ SELECT
newestRegister.time AS last_register_time,
COALESCE(latestDeposit.deposit, 0),
non_deregister_voting_anchor.url IS NOT NULL AS has_non_deregister_voting_anchor,
off_chain_vote_fetch_error.fetch_error,
off_chain_vote_drep_data.payment_address,
off_chain_vote_drep_data.given_name,
off_chain_vote_drep_data.objectives,
Expand Down Expand Up @@ -96,6 +97,7 @@ FROM
AND DRepDistr.rn = 1
LEFT JOIN voting_anchor va ON va.id = dr_voting_anchor.voting_anchor_id
LEFT JOIN voting_anchor non_deregister_voting_anchor on non_deregister_voting_anchor.id = dr_non_deregister_voting_anchor.voting_anchor_id
LEFT JOIN off_chain_vote_fetch_error ON off_chain_vote_fetch_error.voting_anchor_id = va.id
LEFT JOIN off_chain_vote_data ON off_chain_vote_data.voting_anchor_id = va.id
LEFT JOIN off_chain_vote_drep_data on off_chain_vote_drep_data.off_chain_vote_data_id = off_chain_vote_data.id
CROSS JOIN DRepActivity
Expand Down Expand Up @@ -138,6 +140,7 @@ GROUP BY
newestRegister.time,
latestDeposit.deposit,
non_deregister_voting_anchor.url,
off_chain_vote_fetch_error.fetch_error,
off_chain_vote_drep_data.payment_address,
off_chain_vote_drep_data.given_name,
off_chain_vote_drep_data.objectives,
Expand Down
1 change: 1 addition & 0 deletions govtool/backend/src/VVA/API.hs
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ drepRegistrationToDrep Types.DRepRegistration {..} =
dRepType = mapDRepType dRepRegistrationType,
dRepLatestTxHash = HexText <$> dRepRegistrationLatestTxHash,
dRepLatestRegistrationDate = dRepRegistrationLatestRegistrationDate,
dRepMetadataError = dRepRegistrationMetadataError,
dRepPaymentAddress = dRepRegistrationPaymentAddress,
dRepGivenName = dRepRegistrationGivenName,
dRepObjectives = dRepRegistrationObjectives,
Expand Down
1 change: 1 addition & 0 deletions govtool/backend/src/VVA/API/Types.hs
Original file line number Diff line number Diff line change
Expand Up @@ -768,6 +768,7 @@ data DRep
, dRepType :: DRepType
, dRepLatestTxHash :: Maybe HexText
, dRepLatestRegistrationDate :: UTCTime
, dRepMetadataError :: Maybe Text
, dRepPaymentAddress :: Maybe Text
, dRepGivenName :: Maybe Text
, dRepObjectives :: Maybe Text
Expand Down
3 changes: 2 additions & 1 deletion govtool/backend/src/VVA/DRep.hs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ listDReps = withPool $ \conn -> do
results <- liftIO $ SQL.query_ conn listDRepsSql
timeZone <- liftIO getCurrentTimeZone
return
[ DRepRegistration drepHash drepView url dataHash (floor @Scientific deposit) votingPower status drepType txHash (localTimeToUTC timeZone date) paymentAddress givenName objectives motivations qualifications imageUrl imageHash
[ DRepRegistration drepHash drepView url dataHash (floor @Scientific deposit) votingPower status drepType txHash (localTimeToUTC timeZone date) metadataError paymentAddress givenName objectives motivations qualifications imageUrl imageHash
| ( drepHash
, drepView
, url
Expand All @@ -73,6 +73,7 @@ listDReps = withPool $ \conn -> do
, date
, latestDeposit
, latestNonDeregisterVotingAnchorWasNotNull
, metadataError
, paymentAddress
, givenName
, objectives
Expand Down
1 change: 1 addition & 0 deletions govtool/backend/src/VVA/Types.hs
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ data DRepRegistration
, dRepRegistrationType :: DRepType
, dRepRegistrationLatestTxHash :: Maybe Text
, dRepRegistrationLatestRegistrationDate :: UTCTime
, dRepRegistrationMetadataError :: Maybe Text
, dRepRegistrationPaymentAddress :: Maybe Text
, dRepRegistrationGivenName :: Maybe Text
, dRepRegistrationObjectives :: Maybe Text
Expand Down
2 changes: 1 addition & 1 deletion govtool/backend/vva-be.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 3.6
name: vva-be
version: 1.0.19
version: 1.0.20

-- A short (one-line) description of the package.
-- synopsis:
Expand Down
Loading

0 comments on commit 45a52d1

Please sign in to comment.