Skip to content
This repository has been archived by the owner on Apr 17, 2023. It is now read-only.

Commit

Permalink
Merge branch 'release/0.36.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
yknl committed Mar 25, 2019
2 parents 6805a07 + ed2864a commit 1f94a31
Show file tree
Hide file tree
Showing 81 changed files with 11,362 additions and 16,842 deletions.
46 changes: 45 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: 2
jobs:
build:
docker:
- image: circleci/node:8.12.0
- image: circleci/node:10.15.1
working_directory: ~/repo
steps:
- checkout
Expand All @@ -13,3 +13,47 @@ jobs:
- run: npm run test
# build
- run: npm run prod-webapp
test-e2e-login:
docker:
- image: circleci/node:10.15.1
environment:
TEST_E2E_GREP: login-to-hello-blockstack-app
working_directory: ~/repo
steps:
- checkout
- run: npm install
- run: npm run test-e2e:browserstack
- store_artifacts:
path: /tmp/test-errors
test-e2e-account-creation:
docker:
- image: circleci/node:10.15.1
environment:
TEST_E2E_GREP: account-creation
working_directory: ~/repo
steps:
- checkout
- run: npm install
- run: npm run test-e2e:browserstack
- store_artifacts:
path: /tmp/test-errors
test-e2e-account-recovery:
docker:
- image: circleci/node:10.15.1
environment:
TEST_E2E_GREP: account-recovery
working_directory: ~/repo
steps:
- checkout
- run: npm install
- run: npm run test-e2e:browserstack
- store_artifacts:
path: /tmp/test-errors
workflows:
version: 2
build_and_test-e2e:
jobs:
- build
- test-e2e-login
- test-e2e-account-creation
- test-e2e-account-recovery
9 changes: 9 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# top-most EditorConfig file
root = true

[*.{js,ts,json}]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
indent_size = 2
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,6 @@ test/store/*
test/utils/a*
test/utils/e*
test/utils/n*
test-e2e/*

app/js/profiles/components/VerificationInfo*
1 change: 1 addition & 0 deletions .flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
.*/node_modules/.*
.*/build/.*
.*/dist/.*
.*/test-e2e/*

[include]

Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,5 @@ native/windows/BlockstackSetup/bin/
native/macos/Blockstack/Blockstack/server/corsproxy.js
native/macos/Blockstack/Blockstack/server/blockstackProxy.js
native/macos/Blockstack/Blockstack/server/node
screenshot-failed*
screenshot.png
56 changes: 56 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Mocha e2e local",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/node_modules/mocha/bin/_mocha",
"env": {
"E2E_BROWSER_HOST": "./build"
},
"args": [
"--opts",
"test-e2e/mocha.opts",
"test-e2e"
],
"console": "internalConsole",
"internalConsoleOptions": "openOnSessionStart"
},
{
"type": "node",
"request": "launch",
"name": "Mocha e2e browserstack",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/node_modules/mocha/bin/_mocha",
"env": {
"USE_BROWSERSTACK": "true",
"E2E_BROWSER_HOST": "./build"
},
"args": [
"--opts",
"test-e2e/mocha.opts",
"test-e2e"
],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
},
{
"type": "node",
"request": "launch",
"name": "Mocha e2e run parallel",
"cwd": "${workspaceFolder}",
"program": "${workspaceFolder}/test-e2e/run-parallel.js",
"env": {
"USE_BROWSERSTACK": "true",
"E2E_BROWSER_HOST": "./build"
},
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
}
]
}
Binary file added app/images/app-icon-springrole-256x256.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/images/app-icon-springrole-512x512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 18 additions & 9 deletions app/js/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ import {
import { SanityActions } from './store/sanity'
import { CURRENT_VERSION } from './store/reducers'
import { isCoreEndpointDisabled } from './utils/window-utils'
import { openInNewTab } from './utils'
import Modal from 'react-modal'
import NotificationsSystem from 'reapop'
import NotificationsTheme from 'reapop-theme-wybo'
import { hot } from 'react-hot-loader'
import { selectLastUpdatedApps } from './store/apps/selectors'

import log4js from 'log4js'

Expand All @@ -38,17 +38,19 @@ function mapStateToProps(state) {
coreApiPasswordValid: state.sanity.coreApiPasswordValid,
walletPaymentAddressUrl: state.settings.api.walletPaymentAddressUrl,
coreAPIPassword: state.settings.api.coreAPIPassword,
instanceIdentifier: state.apps.instanceIdentifier
instanceIdentifier: state.apps.instanceIdentifier,
lastUpdatedApps: selectLastUpdatedApps(state)
}
}

function mapDispatchToProps(dispatch) {
const mapDispatchToProps = dispatch => {
return bindActionCreators(
{
updateApi: SettingsActions.updateApi,
isCoreRunning: SanityActions.isCoreRunning,
isCoreApiPasswordValid: SanityActions.isCoreApiPasswordValid,
generateInstanceIdentifier: AppsActions.generateInstanceIdentifier
generateInstanceIdentifier: AppsActions.generateInstanceIdentifier,
doFetchApps: AppsActions.doFetchApps
},
dispatch
)
Expand All @@ -71,12 +73,14 @@ class AppContainer extends Component {
isCoreRunning: PropTypes.func.isRequired,
isCoreApiPasswordValid: PropTypes.func.isRequired,
generateInstanceIdentifier: PropTypes.func.isRequired,
doFetchApps: PropTypes.func.isRequired,
walletPaymentAddressUrl: PropTypes.string.isRequired,
coreAPIPassword: PropTypes.string,
stateVersion: PropTypes.number,
router: PropTypes.object.isRequired,
location: PropTypes.object.isRequired,
instanceIdentifier: PropTypes.string
instanceIdentifier: PropTypes.string,
lastUpdatedApps: PropTypes.number
}

constructor(props) {
Expand Down Expand Up @@ -160,6 +164,14 @@ class AppContainer extends Component {
search: this.props.location.search
})
}

if (
!this.props.lastUpdatedApps ||
Date.now() - this.props.lastUpdatedApps > 900000 // 15 min
) {
// Fetch those apps if data is state
this.props.doFetchApps()
}
}

componentWillReceiveProps(nextProps) {
Expand All @@ -171,6 +183,7 @@ class AppContainer extends Component {

if (!this.props.coreApiRunning) {
// TODO connect to future notification system here
// TODO is this even used anymore?
logger.error('Sanity check: Error! Core API is NOT running!')
}

Expand All @@ -192,10 +205,6 @@ class AppContainer extends Component {
}
}

onSupportClick = () => {
openInNewTab('https://forum.blockstack.org/t/frequently-ask-questions/2123')
}

closeModal() {
this.setState({ modalIsOpen: false })
}
Expand Down
Loading

0 comments on commit 1f94a31

Please sign in to comment.