Skip to content

Commit 75474c8

Browse files
author
Stephanie Reeder
authored
Merge pull request #284 from ODM2/Beta_1.2.5
Beta 1.2.5
2 parents 5c53759 + eb28383 commit 75474c8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+1016
-419
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ setup/Output/setup.exe
6363

6464
#folders
6565
Temp
66+
6667
*.app
6768
*.spec
6869

.travis.yml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,16 +41,19 @@ addons:
4141
- wx2.8-headers
4242
- wx2.8-i18n
4343

44+
4445
# mariadb: '10.1'
4546
before_script:
46-
- ./scripts/tests/mysql_setup.sh
47-
- ./scripts/tests/postgres_setup.sh
48-
- ./scripts/tests/freetds.sh
47+
- ./ci-helpers/travis/mysql_setup.sh
48+
- ./ci-helpers/travis/postgres_setup.sh
49+
- ./ci-helpers/travis/freetds.sh
50+
4951

5052
before_install:
5153
# python -m pip makes the install go into the virtualenv
5254
- python -m pip install pandas
5355
- export PYMSSQL_BUILD_WITH_BUNDLED_FREETDS=1;python -m pip install pymssql
56+
5457
# - python -m pip install mysql-python
5558
install: # now just our code
5659
- pip install geoalchemy2
@@ -60,8 +63,17 @@ install: # now just our code
6063
# don't forget to open up the azure mssql server to these addreses
6164
# https://docs.travis-ci.com/user/ip-addresses/
6265

66+
# mariadb: '10.1'
67+
before_script:
68+
- chmod +x ./tests/scripts/mysql_setup.sh
69+
# - chmod +x ./tests/scripts/postgres_setup.sh
70+
- chmod +x ./tests/scripts/freetds.sh
71+
- ./tests/scripts/mysql_setup.sh
72+
# - ./tests/scripts/postgres_setup.sh
73+
- ./tests/scripts/freetds.sh
74+
6375
# command to run tests
6476
script:
65-
77+
# - pythonw -m pytest
6678
- py.test
6779

ODMTools.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
import psycopg2
2424

2525
tool = LoggerTool()
26-
logger = tool.setupLogger(__name__, __name__ + '.log', 'w', logging.DEBUG)
26+
logger = tool.setupLogger('main', 'odmtools.log', 'a', logging.INFO)
2727
wx.Log.SetLogLevel(0)
2828

2929

@@ -67,7 +67,7 @@ def runODM():
6767
app.MainLoop()
6868

6969
if __name__ == '__main__':
70-
logger.debug("Welcome to ODMTools Python. Please wait as system loads")
70+
logger.info("Welcome to ODMTools Python. Please wait as system loads")
7171
# https://docs.python.org/2/library/multiprocessing.html#miscellaneous
7272

7373
# Add support for when a program which uses multiprocessing has been frozen to produce a Windows executable.

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ To make running ODMTools easier we have included installers. Please select the o
1919

2020
####Windows
2121
Recommended Release:
22-
+ [Window v1.2.2-beta](https://github.com/ODM2/ODMToolsPython/releases/download/v1.2.2-beta/ODMTools_1.2.2_Beta_Win_Installer.exe)
22+
+ [Window v1.2.5-beta](https://github.com/ODM2/ODMToolsPython/releases/download/v1.2.5-beta/ODMTools_1.2.5_Beta_Win_Installer.exe)
2323

2424
####Mac
25-
+ [Mac v1.2.2-beta](https://github.com/ODM2/ODMToolsPython/releases/download/v1.2.2-beta/ODMTools_v1.2.2-beta_Mac_installer.pkg.zip)
25+
+ [Mac v1.2.5-beta](https://github.com/ODM2/ODMToolsPython/releases/download/v1.2.5-beta/ODMTools_v1.2.5-beta_Mac_installer.pkg.zip)
2626

2727
####Linux
2828
+ *Please run from source*

appveyor.yml

Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
environment:
2+
# patterned after: https://github.com/ogrisel/python-appveyor-demo/blob/master/appveyor.yml
3+
global:
4+
# SDK v7.0 MSVC Express 2008's SetEnv.cmd script will fail if the
5+
# /E:ON and /V:ON options are not enabled in the batch script intepreter
6+
# See: http://stackoverflow.com/a/13751649/163740
7+
PYTHON: "C:\\conda"
8+
MINICONDA_VERSION: "latest"
9+
# CMD_IN_ENV: "cmd /E:ON /V:ON /C .\\appveyor\\run_with_env.cmd"
10+
CMD_IN_ENV: "cmd /E:ON /V:ON /C .\\ci-helpers/appveyor/windows_sdk.cmd"
11+
CONDA_DEPENDENCIES: "numpy matplotlib pandas pymysql scipy sqlite sqlalchemy wxpython pip"
12+
PIP_DEPENDENCIES: "geoalchemy pyodbc pytest psycopg2"
13+
14+
15+
16+
# postgres
17+
POSTGRES_PORT: tcp://localhost:5432
18+
POSTGRES_ENV_POSTGRES_USER: postgres
19+
POSTGRES_ENV_POSTGRES_PASSWORD: Password12!
20+
POSTGRES_ENV_POSTGRES_DB: odm
21+
POSTGRES_PATH: C:\Program Files\PostgreSQL\9.4\bin
22+
PGUSER: postgres
23+
PGPASSWORD: Password12!
24+
# mysql
25+
MYSQL_PORT: tcp://localhost:3306
26+
MYSQL_ENV_MYSQL_USER: root
27+
MYSQL_ENV_MYSQL_PASSWORD: Password12!
28+
MYSQL_ENV_MYSQL_DATABASE: odm
29+
MYSQL_PATH: C:\Program Files\MySql\MySQL Server 5.6\bin
30+
MYSQL_PWD: Password12!
31+
# sql server
32+
SQLSERVER_ENV_SQLSERVER_HOST: localhost
33+
SQLSERVER_ENV_SQLSERVER_PORT: 1433
34+
SQLSERVER_ENV_SQLSERVER_USER: sa
35+
SQLSERVER_ENV_SQLSERVER_PASSWORD: Password12!
36+
SQLSERVER_ENV_SQLSERVER_DATABASE: odm
37+
38+
39+
40+
# Pre-installed Python versions, which Appveyor may upgrade to
41+
# a later point release.
42+
# See: http://www.appveyor.com/docs/installed-software#python
43+
44+
matrix:
45+
- PYTHON: "C:\\Python27-conda32"
46+
PYTHON_VERSION: "2.7"
47+
PYTHON_ARCH: "32"
48+
# CONDA_PY: "27"
49+
# CONDA_NPY: "18"
50+
NUMPY_VERSION: "stable"
51+
52+
- PYTHON: "C:\\Python27-conda64"
53+
PYTHON_VERSION: "2.7"
54+
PYTHON_ARCH: "64"
55+
NUMPY_VERSION: "stable"
56+
# CONDA_PY: "27"
57+
# CONDA_NPY: "18"
58+
59+
60+
# - PYTHON: "C:\\Python34-conda64"
61+
# PYTHON_VERSION: "3.4"
62+
# PYTHON_ARCH: "64"
63+
64+
services:
65+
- mssql2008r2sp2
66+
- mysql
67+
- postgresql
68+
69+
install:
70+
# If there is a newer build queued for the same PR, cancel this one.
71+
# The AppVeyor 'rollout builds' option is supposed to serve the same
72+
# purpose but it is problematic because it tends to cancel builds pushed
73+
# directly to master instead of just PR builds (or the converse).
74+
# credits: JuliaLang developers.
75+
- ps: if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod `
76+
https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | `
77+
Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { `
78+
throw "There are newer queued builds for this pull request, failing early." }
79+
- ECHO "Filesystem root:"
80+
- ps: "ls \"C:/\""
81+
82+
- ECHO "Installed SDKs:"
83+
- ps: "ls \"C:/Program Files/Microsoft SDKs/Windows\""
84+
85+
# Install Python (from the official .msi of http://python.org) and pip when
86+
# not already installed.
87+
# - ps: if (-not(Test-Path($env:PYTHON))) { & appveyor\install.ps1 }
88+
- ps: ci-helpers/appveyor/install-miniconda.ps1
89+
90+
91+
# Prepend newly installed Python to the PATH of this build (this cannot be
92+
# done from inside the powershell script as it would require to restart
93+
# the parent CMD process).
94+
- "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
95+
# add databases
96+
- "SET PATH=%POSTGRES_PATH%\bin;%MYSQL_PATH%\bin;%PATH%"
97+
- "activate test"
98+
99+
# Check that we have the expected version and architecture for Python
100+
- "python --version"
101+
- "python -c \"import struct; print(struct.calcsize('P') * 8)\""
102+
103+
104+
105+
build_script:
106+
##https://github.com/sqlectron/sqlectron-core/blob/master/appveyor.yml
107+
108+
# sqlserver
109+
- ps: ci-helpers\appveyor\sqlserver.ps1 SQL2008R2SP2
110+
- sqlcmd -S localhost,1433 -U sa -P Password12! -Q "CREATE DATABASE odm" -d "master"
111+
- sqlcmd -S localhost,1433 -U sa -P Password12! -i tests\data\sampledb\odm_mssql.sql -d "odm"
112+
- sqlcmd -S localhost,1433 -U sa -P Password12! -Q "select table_name from information_schema.tables" -d "odm"
113+
# # postgres
114+
# - psql createdb odm
115+
# - psql -d odm -a -f tests\data\sampledb\odm_postgres.sql
116+
# # mysql
117+
# - mysql -e "drop database test; create database odm;" --user=root
118+
# - mysql odm < tests\data\sampledb\odm_mysql.sql --user=root
119+
120+
test_script:
121+
# Run the project tests
122+
- "py.test"
123+
124+
125+
126+

0 commit comments

Comments
 (0)