Skip to content

Commit c0f427e

Browse files
Merge branch 'develop'
2 parents 96c643c + d1a5595 commit c0f427e

File tree

5 files changed

+46
-6
lines changed

5 files changed

+46
-6
lines changed

climada/entity/exposures/litpop/gpw_population.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,8 @@ def get_gpw_file_path(gpw_version, reference_year, data_dir=SYSTEM_DIR, verbatim
153153
+ 'The data can be downloaded from '
154154
+ 'http://sedac.ciesin.columbia.edu/'
155155
+ 'data/collection/gpw-v4/sets/browse, '
156-
+ 'e.g., https://sedac.ciesin.columbia.edu/data/'
157-
+ f'set/gpw-v4-population-count-rev{gpw_version}/'
158-
+ 'data-download'
159-
+ '(Free NASA Earthdata login required). '
156+
+ 'e.g., https://sedac.ciesin.columbia.edu/downloads/data/'
157+
+ f'gpw-v4/gpw-v4-population-count-rev{gpw_version}/'
158+
+ f'gpw-v4-population-count-rev{gpw_version}_2020_30_sec_tif.zip '
159+
+ '(Free NASA Earthdata login required).'
160160
)

climada/test/test_api_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ def test_get_hazard(self):
139139
properties={'country_name': 'Austria',
140140
'year_range': '2010_2030', 'climate_scenario': 'rcp26'},
141141
dump_dir=DATA_DIR)
142-
self.assertEqual(np.shape(hazard.intensity), (1440, 5784))
142+
self.assertEqual(np.shape(hazard.intensity), (480, 5784))
143143
self.assertEqual(np.unique(hazard.centroids.region_id), 40)
144144
self.assertEqual(np.unique(hazard.date).size, 20)
145145
self.assertEqual(hazard.tag.haz_type, 'RF')

doc/guide/Guide_Installation.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
"Download the environment specification file from the git repository and save it locally, then create the conda environment:\n",
7474
"\n",
7575
"```bash\n",
76-
"wget https://github.com/CLIMADA-project/climada_python/raw/main/requirements/env_climada.yml\n",
76+
"curl -o env_climada.yml https://raw.githubusercontent.com/CLIMADA-project/climada_python/main/requirements/env_climada.yml\n",
7777
"conda env create -n climada_env -f env_climada.yml\n",
7878
"conda activate climada_env\n",
7979
"```\n",

Jenkinsfile renamed to script/jenkins/branches/Jenkinsfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ pipeline {
1010
sh '''#!/bin/bash
1111
export PATH=$PATH:$CONDAPATH
1212
source activate climada_env
13+
rm -f pylint.log
1314
pylint -ry climada | tee pylint.log'''
1415

1516
recordIssues tools: [pyLint(pattern: 'pylint.log')]
@@ -21,6 +22,7 @@ pipeline {
2122
sh '''#!/bin/bash
2223
export PATH=$PATH:$CONDAPATH
2324
source activate climada_env
25+
rm -rf tests_xml/
2426
python -m coverage run tests_runner.py unit
2527
python -m coverage xml -o coverage.xml
2628
python -m coverage html -d coverage'''
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
pipeline {
2+
agent any
3+
4+
stages {
5+
stage('lint') {
6+
steps {
7+
sh '''#!/bin/bash
8+
export PATH=$PATH:$CONDAPATH
9+
source activate climada_env
10+
rm -f pylint.log
11+
pylint -ry climada | tee pylint.log'''
12+
13+
recordIssues tools: [pyLint(pattern: 'pylint.log')]
14+
}
15+
}
16+
17+
stage('integ_test') {
18+
steps {
19+
sh '''#!/bin/bash
20+
export PATH=$PATH:$CONDAPATH
21+
source activate climada_env
22+
rm -rf tests_xml/
23+
python -m coverage run --parallel-mode --concurrency=multiprocessing tests_runner.py unit
24+
python -m coverage run --parallel-mode --concurrency=multiprocessing tests_runner.py integ
25+
python -m coverage combine
26+
python -m coverage xml -o coverage.xml
27+
python -m coverage html -d coverage'''
28+
}
29+
}
30+
}
31+
32+
post {
33+
always {
34+
junit 'tests_xml/*.xml'
35+
cobertura coberturaReportFile: 'coverage.xml', enableNewApi: true
36+
}
37+
}
38+
}

0 commit comments

Comments
 (0)