Skip to content
This repository has been archived by the owner on Sep 9, 2020. It is now read-only.

Commit

Permalink
windows compatibility
Browse files Browse the repository at this point in the history
Fixes Windows tests
modified:   datarobot_batch_scoring/batch_scoring.py
    stop Manager with contextlib
modified:   datarobot_batch_scoring/utils.py
    pickle triggers a new instance to be init. Managable by a context manager

remove redundent UI, use a tempfile for subproc

use absolute imports, add freeze_support for Windows

log more from shovel

skip functional and regression on Windows Py3
  • Loading branch information
mckaymatt committed Jul 7, 2016
1 parent 250e814 commit c9e89ea
Show file tree
Hide file tree
Showing 15 changed files with 649 additions and 396 deletions.
6 changes: 6 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
1.8.3 (2016 July 6)
==================
* This release is compatible with Windows

* logs are now sent to two files within the directory where the script is run

1.8.2 (2016 June 16)
==================
* added --auto_sample option to find the n_samples automatically.
Expand Down
9 changes: 7 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,9 @@ Example::

Using configuration file
------------------------
The `batch_scoring` command check for the existence of a .batch_scoring.ini file at the location `$HOME/.batch_scoring.ini` (your home directory) and directory where you running the script (working directory). If this file exists, the command uses the same arguments that described above.
The `batch_scoring` command check for the existence of a batch_scoring.ini file at the location `$HOME/batch_scoring.ini` (your home directory) and directory where you running the script (working directory). If this file exists, the command uses the same arguments that described above.

The format of a `.batch_scoring.ini` file is as follows::
The format of a `batch_scoring.ini` file is as follows::

[batch_scoring]
host=file_host
Expand All @@ -117,3 +117,8 @@ Usage Notes
------------
* If the script detects that a previous script was interrupted in mid-execution, it will prompt whether to resume that execution.
* If no interrupted script was detected or if you indicate not to resume the previous execution, the script checks to see if the specified output file exists. If yes, the script prompts to confirm before overwriting this file.
* The logs from each batch_scoring run are stored in the current working. All users will see a `datarobot_batch_scoring_main.log` log file, and Windows users will see an additional log file, `datarobot_batch_scoring_batcher.log`.

Notes for Windows Users
------------
The batch_scoring script is tested on Windows, but for now it is recommended to use the script with Python 2.7. Python 3.4+ should work, but we have had some issues which prevent us from running all or our tests against Python 3+.
6 changes: 3 additions & 3 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ environment:
PYPI_PASSWD:
secure: u+K6dKi7+CXXVFEUG4V7zUyV3w7Ntg0Ork/RGVV0eSQ=
matrix:
- PYTHON: "C:\\Python27"
- PYTHON: "C:\\Python27-x64"
- PYTHON: "C:\\Python35"
- PYTHON: "C:\\Python35-x64"
- PYTHON: "C:\\Python27"
- PYTHON: "C:\\Python27-x64"

install:
- "build.cmd %PYTHON%\\python.exe -m pip install -U pip"
Expand All @@ -18,7 +18,7 @@ install:
build: false

test_script:
- "build.cmd %PYTHON%\\python.exe -m pytest"
- "build.cmd %PYTHON%\\python.exe -m pytest -vvv"

after_test:
- "build.cmd %PYTHON%\\python.exe setup.py bdist_wheel"
Expand Down
2 changes: 1 addition & 1 deletion datarobot_batch_scoring/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '1.8.2'
__version__ = '1.8.3'
Loading

0 comments on commit c9e89ea

Please sign in to comment.