-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
1,270 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,37 @@ | ||
import warnings | ||
|
||
from clldutils.misc import deprecated | ||
|
||
from cldfzenodo.record import * | ||
from cldfzenodo.api import * | ||
from cldfzenodo import oai | ||
from cldfzenodo import search | ||
|
||
__version__ = '1.1.1.dev0' | ||
# flake8: noqa | ||
|
||
# ------------------------------------------------------------------------------------------------- | ||
# legacy API: | ||
# ------------------------------------------------------------------------------------------------- | ||
def search_wordlists(q=None, **kw): | ||
deprecated('Use `API.iter_records` instead.') | ||
if kw: | ||
warnings.warn('Zenodo search API changed, custom parameters passed as kw are ignored.') | ||
return API.iter_records(keyword='cldf:Wordlist', allversions=True, _q=q) | ||
|
||
|
||
def search_structuredatasets(q=None, **kw): | ||
deprecated('Use `API.iter_records` instead.') | ||
if kw: | ||
warnings.warn('Zenodo search API changed, custom parameters passed as kw are ignored.') | ||
return API.iter_records(keyword='cldf:StructureDataset', allversions=True, _q=q) | ||
|
||
|
||
def oai_lexibank(): | ||
deprecated('Use `API.iter_records` instead.') | ||
return API.iter_records(community='lexibank', allversions=True) | ||
|
||
|
||
def oai_cldf_datasets(): | ||
deprecated('Use `API.iter_records` instead.') | ||
return API.iter_records(community='cldf-datasets', allversions=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
from clldutils.misc import deprecated | ||
|
||
from cldfzenodo.api import API | ||
|
||
|
||
def iter_records(community): | ||
deprecated('Use `API.iter_records` instead.') | ||
return API.iter_records(community=community, allversions=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
from clldutils.misc import deprecated | ||
|
||
from cldfzenodo.api import API | ||
|
||
|
||
def iter_records(keyword, q=None, **kw): | ||
deprecated('Use `API.iter_records` instead.') | ||
return API.iter_records(keyword=keyword, allversions=True, _q=q) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.