Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.22.0 #314

Merged
merged 55 commits into from
Jun 7, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
7139d14
tests for snakemake project; close #294
vreuter May 6, 2019
aa8f43d
better deprecation localization
vreuter May 6, 2019
fa5a1b1
Merge pull request #303 from vreuter/depr
vreuter May 6, 2019
af5327d
support constant_attributes and favor over constants; close #302
vreuter May 6, 2019
adebe8e
Merge pull request #304 from vreuter/const
vreuter May 6, 2019
7a9f765
start tests for constants
vreuter May 6, 2019
672ee54
finish subproject and constants tests; close #292
vreuter May 6, 2019
0279f46
update changelog
vreuter May 6, 2019
27bc3df
Merge pull request #305 from vreuter/const
vreuter May 6, 2019
338cb37
project repr updates; close #296
vreuter May 7, 2019
aeec50a
Merge pull request #306 from vreuter/reps
vreuter May 7, 2019
121651e
move looper-specific sample methods; move utilities; fix AttMap overr…
vreuter May 8, 2019
9076f6f
organize methods on name
vreuter May 8, 2019
19f0311
bump attmap req
vreuter May 9, 2019
f7c5bb2
dev attmap
vreuter May 9, 2019
490579d
bump req from attmap release
vreuter May 14, 2019
e311c26
starting mutation updates for attmap
vreuter May 15, 2019
e399f1a
use is_url from ubiquerg
vreuter May 16, 2019
07ad285
updated attmap
vreuter May 17, 2019
e461530
fix utils tests
vreuter May 17, 2019
aee05a9
fix regression tests
vreuter May 17, 2019
c04004f
account for attmap changes; improve messaging and type safety
vreuter May 17, 2019
d2eb79a
use new attmap
vreuter May 17, 2019
2986635
stronger assertions and failure messaging
vreuter May 17, 2019
1c3ab4a
fix more tests
vreuter May 18, 2019
cb340d5
fix remaining tests
vreuter May 18, 2019
dd14312
fix tests on 2; better attmap type
vreuter May 18, 2019
c85f089
attmap version
vreuter May 18, 2019
098b0b8
infrastructure for adjusting subdirs; #308
vreuter May 21, 2019
df927ae
add subdir dynamism; close #308
vreuter May 22, 2019
ac5fec5
add subproject path tests; constants
vreuter May 28, 2019
bf86bb7
silence expected deprecation warnings
vreuter May 28, 2019
b647651
relax requirements on equality, to disregard index in consideration
vreuter May 28, 2019
a2533ea
amid test tweaks to accommodate param'd indexing
vreuter May 28, 2019
32502f6
testing derived path preservation upon sp activation
vreuter May 29, 2019
56ae85e
ensure list not str
vreuter May 29, 2019
08fe58d
Merge pull request #316 from vreuter/remerge
vreuter May 29, 2019
a5e0e72
Merge branch 'dev' of github.com:pepkit/peppy into dev
vreuter May 30, 2019
51634ab
version/changelog update for release
nsheff Jun 4, 2019
619ebce
rephrase changelog
nsheff Jun 4, 2019
6df0e2b
use single backticks in changelog
nsheff Jun 4, 2019
e48d540
add changelog message about reverting sample_name deprecation
nsheff Jun 4, 2019
350abf3
update log setup calls
vreuter Jun 4, 2019
cd13455
handle expected deprecation warnings
vreuter Jun 4, 2019
b636102
Merge pull request #317 from vreuter/22rc1
vreuter Jun 4, 2019
578355d
pull in dev changes
vreuter Jun 4, 2019
4aa8341
account for time-/state-dependence of column naming
vreuter Jun 4, 2019
785eedd
make messaging independent of code path walked
vreuter Jun 4, 2019
5a74ef4
test default indexing
vreuter Jun 4, 2019
fbfa0e9
test indexing
vreuter Jun 4, 2019
9fedf7d
index key assurance
vreuter Jun 5, 2019
4dabd9d
typesafe helpers
vreuter Jun 5, 2019
d51617f
temporarily prohibit subproject use on SnakeProject
vreuter Jun 6, 2019
2c284be
update reqs
vreuter Jun 7, 2019
229b74c
changelog
vreuter Jun 7, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
autodoc_build/

59 changes: 35 additions & 24 deletions docs/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# Changelog

## [0.22.0] -- (2019-06-06)
### Changed
- Deprecate `Project` `constants` in favor of `constant_attributes.`
- Improved `Project` text representation for interactive/terminal display (`__repr__`): [Issue 296](https://github.com/pepkit/peppy/issues/296)

### Fixed
- Properly use `constant_attributes` if present from subproject. [Issue 292](https://github.com/pepkit/peppy/issues/292)
- Fixed a bug with subproject activation paths
- Revert deprecation of `sample_name` to `name`; so `sample_name` is again approved.


## [0.21.0] -- (2019-05-02)

### Added
Expand All @@ -12,7 +23,7 @@
- Improved messaging: ["Unmatched regex-like"](https://github.com/pepkit/peppy/issues/223), ["Missing and/or empty attribute(s)"](https://github.com/pepkit/peppy/issues/282)
- On `Project`, `sheet` is deprecated in favor of `sample_table`.
- On `Project`, `sample_subannotation` is deprecated in favor of `subsample_table`.
- On `Sample`, reference to `sample_name` is deprecated in favor of simly `name`.
- On `Sample`, reference to `sample_name` is deprecated in favor of simply `name`.

## [0.20.0] -- (2019-04-17)
### Added
Expand All @@ -26,11 +37,11 @@ Additionally, the attribute value matching is more strict now -- requires perfec

## [0.19.0] -- (2019-01-16)
### New
- Added ``activate_subproject`` method to ``Project``.
- Added `activate_subproject` method to `Project`.
### Changed
- ``Project`` construction no longer requires sample annotations sheet.
- Specification of assembly/ies in project config outside of ``implied_attributes`` is deprecated.
- ``implied_columns`` and ``derived_columns`` are deprecated in favor of ``implied_attributes`` and ``derived_attributes``.
- `Project` construction no longer requires sample annotations sheet.
- Specification of assembly/ies in project config outside of `implied_attributes` is deprecated.
- `implied_columns` and `derived_columns` are deprecated in favor of `implied_attributes` and `derived_attributes`.

## [0.18.2] -- (2018-07-23)
### Fixed
Expand All @@ -39,12 +50,12 @@ Additionally, the attribute value matching is more strict now -- requires perfec
## [0.18.1] -- (2018-06-29)
### Fixed
- Fixed a bug that would cause sample attributes to lose order.
- Fixed a bug that caused an install error with newer ``numexpr`` versions.
- Fixed a bug that caused an install error with newer `numexpr` versions.
### New
- Project names are now inferred with the ``infer_name`` function, which uses a priority lookup to infer the project name: First, the ``name`` attribute in the ``yaml`` file; otherwise, the containing folder unless it is ``metadata``, in which case, it's the parent of that folder.
- Add ``get_sample`` and ``get_samples`` functions to ``Project`` objects.
- Add ``get_subsamples``and ``get_subsample`` functions to both ``Project`` and ``Sample`` objects.
- Subsamples are now objects that can be retrieved individually by name, with the ``subsample_name`` as the index column header.
- Project names are now inferred with the `infer_name` function, which uses a priority lookup to infer the project name: First, the `name` attribute in the `yaml` file; otherwise, the containing folder unless it is `metadata`, in which case, it's the parent of that folder.
- Add `get_sample` and `get_samples` functions to `Project` objects.
- Add `get_subsamples`and `get_subsample` functions to both `Project` and `Sample` objects.
- Subsamples are now objects that can be retrieved individually by name, with the `subsample_name` as the index column header.

## [0.17.2] -- (2018-04-03)
## Fixed
Expand All @@ -57,10 +68,10 @@ Additionally, the attribute value matching is more strict now -- requires perfec

## [0.9.0] -- (2017-12-21)
### New
- Separation completed, ``peppy`` package is now standalone
- ``looper`` can now rely on ``peppy``
- Separation completed, `peppy` package is now standalone
- `looper` can now rely on `peppy`
### Changed
- ``merge_table`` renamed to ``sample_subannotation``
- `merge_table` renamed to `sample_subannotation`
- setup changed for compatibility with PyPI

## [0.8.1] -- (2017-11-16)
Expand All @@ -74,11 +85,11 @@ Additionally, the attribute value matching is more strict now -- requires perfec
## [0.7.1] -- (2017-11-15)
### Fixed
- No longer falsely display that there's a submission failure.
- Allow non-string values to be unquoted in the ``pipeline_args`` section.
- Allow non-string values to be unquoted in the `pipeline_args` section.

## [0.7.0] -- (2017-11-15)
### New
- Add ``--lump`` and ``--lumpn`` options
- Add `--lump` and `--lumpn` options
- Catch submission errors from cluster resource managers
- Implied columns can now be derived
- Now protocols can be specified on the command-line `--include-protocols`
Expand All @@ -95,18 +106,18 @@ Additionally, the attribute value matching is more strict now -- requires perfec
### New
- Add support for implied_column section of the project config file
- Add support for Python 3
- Merges pipeline interface and protocol mappings. This means we now allow direct pointers to ``pipeline_interface.yaml`` files, increasing flexibility, so this relaxes the specified folder structure that was previously used for ``pipelines_dir`` (with ``config`` subfolder).
- Merges pipeline interface and protocol mappings. This means we now allow direct pointers to `pipeline_interface.yaml` files, increasing flexibility, so this relaxes the specified folder structure that was previously used for `pipelines_dir` (with `config` subfolder).
- Allow URLs as paths to sample sheets.
- Allow tsv format for sample sheets.
- Checks that the path to a pipeline actually exists before writing the submission script.
### Changed
- Changed LOOPERENV environment variable to PEPENV, generalizing it to generic models
- Changed name of ``pipelines_dir`` to ``pipeline_interfaces`` (but maintained backwards compatibility for now).
- Changed name of ``run`` column to ``toggle``, since ``run`` can also refer to a sequencing run.
- Changed name of `pipelines_dir` to `pipeline_interfaces` (but maintained backwards compatibility for now).
- Changed name of `run` column to `toggle`, since `run` can also refer to a sequencing run.
- Relaxes many constraints (like resources sections, pipelines_dir columns), making project configuration files useful outside looper. This moves us closer to dividing models from looper, and improves flexibility.
- Various small bug fixes and dev improvements.
- Require `setuptools` for installation, and `pandas 0.20.2`. If `numexpr` is installed, version `2.6.2` is required.
- Allows tilde in ``pipeline_interfaces``
- Allows tilde in `pipeline_interfaces`

## [0.5.0] -- (2017-03-01)
### New
Expand All @@ -124,12 +135,12 @@ Additionally, the attribute value matching is more strict now -- requires perfec
## [0.4.0] -- (2017-01-12)
### New
- New command-line interface (CLI) based on sub-commands
- New subcommand (``looper summarize``) replacing the ``summarizePipelineStats.R`` script
- New subcommand (``looper check``) replacing the ``flagCheck.sh`` script
- New command (``looper destroy``) to remove all output of a project
- New command (``looper clean``) to remove intermediate files of a project flagged for deletion
- New subcommand (`looper summarize`) replacing the `summarizePipelineStats.R` script
- New subcommand (`looper check`) replacing the `flagCheck.sh` script
- New command (`looper destroy`) to remove all output of a project
- New command (`looper clean`) to remove intermediate files of a project flagged for deletion
- Support for portable and pipeline-independent allocation of computing resources with Looperenv.
### Changed
- Removed requirement to have ``pipelines`` repository installed in order to extend base Sample objects
- Removed requirement to have `pipelines` repository installed in order to extend base Sample objects
- Maintenance of sample attributes as provided by user by means of reading them in as strings (to be improved further
- Improved serialization of Sample objects
6 changes: 3 additions & 3 deletions peppy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@

from ._version import __version__
from .const import *
from .exceptions import PeppyError
from .exceptions import *
from .project import Project, ProjectContext
from .sample import Sample, Subsample
from .snake_project import *
from .utils import fetch_samples, grab_project_data, CommandChecker
#from logmuse import setup_logger
#from logmuse import init_logger

_EXPORT_FROM_UTILS = [fetch_samples.__name__, grab_project_data.__name__,
CommandChecker.__name__]
Expand All @@ -31,4 +31,4 @@
#_LOGGER = logging.getLogger(__name__)
#if not logging.getLogger().handlers:
# _LOGGER.addHandler(logging.NullHandler())
#_LOGGER = setup_logger(name="peppy", level=LOGGING_LEVEL)
#_LOGGER = init_logger(name="peppy", level=LOGGING_LEVEL)
3 changes: 1 addition & 2 deletions peppy/_version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
__version__ = "0.21.0"

__version__ = "0.22.0"
11 changes: 8 additions & 3 deletions peppy/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,24 @@

# Project-related
NAME_TABLE_ATTR = "sample_table"
CONSTANTS_DECLARATION = "constant_attributes"
DATA_SOURCES_SECTION = "data_sources"
DERIVATIONS_DECLARATION = "derived_attributes"
IMPLICATIONS_DECLARATION = "implied_attributes"
METADATA_KEY = "metadata"
OUTDIR_KEY = "output_dir"
SAMPLE_INDEPENDENT_PROJECT_SECTIONS = \
[METADATA_KEY, DERIVATIONS_DECLARATION, IMPLICATIONS_DECLARATION, "trackhubs"]
[METADATA_KEY, DERIVATIONS_DECLARATION, IMPLICATIONS_DECLARATION,
"trackhubs"]
SUBPROJECTS_SECTION = "subprojects"
PIPE_ARGS_SECTION = "pipeline_args"
SUBMISSION_FOLDER_KEY = "submission_subdir"
RESULTS_FOLDER_KEY = "results_subdir"
PROJECT_CONSTANTS = [
"DATA_SOURCES_SECTION", "DERIVATIONS_DECLARATION",
"CONSTANTS_DECLARATION", "DATA_SOURCES_SECTION", "DERIVATIONS_DECLARATION",
"IMPLICATIONS_DECLARATION", "METADATA_KEY", "NAME_TABLE_ATTR", "OUTDIR_KEY",
"PIPE_ARGS_SECTION", "SAMPLE_INDEPENDENT_PROJECT_SECTIONS",
"PIPE_ARGS_SECTION", "RESULTS_FOLDER_KEY",
"SAMPLE_INDEPENDENT_PROJECT_SECTIONS", "SUBMISSION_FOLDER_KEY",
"SUBPROJECTS_SECTION"]
SNAKEMAKE_SAMPLE_COL = "sample"

Expand Down
10 changes: 10 additions & 0 deletions peppy/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

from abc import ABCMeta

__author__ = "Vince Reuter"
__email__ = "[email protected]"

__all__ = ["IllegalStateException", "PeppyError"]


class PeppyError(Exception):
""" Base error type for peppy custom errors. """
Expand All @@ -10,3 +15,8 @@ class PeppyError(Exception):

def __init__(self, msg):
super(PeppyError, self).__init__(msg)


class IllegalStateException(PeppyError):
""" Occurrence of some illogical/prohibited state within an object. """
pass
Loading