v1.1.6 (2024-07-10)
Fixed crash trying to get the occupations-taxonomy and jobs-taxonomy reference files:
from ravenpackapi import RPApi
api = RPApi(product="edge")
occupations = api.get_entity_type_reference("occupations-taxonomy")
occupations.write_to_file("occupations-reference.csv")
jobs = api.get_entity_type_reference("jobs-taxonomy")
jobs.write_to_file("jobs-reference.csv")v1.1.5 (2024-06-28)
- Removed the dependency on the library
retry(and the indirect dependency onpy), and replaced it withtenacity. This should be transparent.
v1.1.4 (2024-02-01)
Fixed issue creating an Edge dataset without product attribute specified, but specifying the product in the RPApi object:
from ravenpackapi import RPApi, Dataset
api = RPApi(api_key="YOUR_API_KEY", product="edge")
ds = api.create_dataset(
Dataset(
name="New Dataset",
filters={"entity_relevance": {"$gte": 90}},
)
)Since the product is not specified in Dataset's __init__, the incorrect
product was being passed to the API, resulting in the message.
Field 'product' must be 'edge'
v1.1.3 (2023-12-06)
- Fixed corner case when the entity-mapping doesn't return any entity but also there are no errors
- Default timeout for request increased from 60 seconds to 100 seconds to match the timeout in the API. The default connection timeout is still 10 seconds.
- Added some examples.
v1.1.2 (2023-10-03)
Fixed a bug in setup.py that caused a crash when running
python setup.py egg_info
v1.1.1 (2023-10-02)
- Removed dependency on
future#9
Fixed bug with lazy loading that caused the wrong product (RPA) being sent
sometimes when saving a dataset without modifying it.
To reproduce the issue:
from ravenpackapi import RPApi
api = RPApi(product="edge")
ds = api.get_dataset("SOME_DATASET_ID")
ds.save()Note that this error is not always triggered and is not deterministic.
v1.1.0 (2023-09-21)
- Support for anaconda
- New Github Actions pipeline
v1.0.60 (2023-09-13)
New flag to store the entity mapping data in memory, when using edge. Use
with caution.
eref = api.get_entity_type_reference(entity_type, "full", file_date)
eref.store_in_memory = True
for entity in eref:
print(entity)v1.0.59 (2022-11-25)
- New examples
- Script to check the connection (check_connection.py) also checks edge.
- Edge flatfiles can now be downloaded through the API, just like RPA flatfiles
- Old examples now work with edge as well.
- Bug listing jobs
v1.0.58 (2022-01-12)
EntityTypeReference for Edge reference files won't keep the entire mapping in
memory anymore. This allows to grab the reference files and write them to file
(or iterate through them) but they can't be accessed as rp_entity_id mappings
anymore. For Edge only.
v1.0.57 (2021-11-24)
- Bug in event_symilarity_days serializer
- Bug with UTF-8 encoding in the edge reference-type
v1.0.56 (2021-11-04)
Internal changes to speed up get_status and wait_for_completion file methods
v1.0.55 (2021-10-15)
Added an optional parameter upload_mode to api.upload.file, which can be
"RPXML" or "RPJSON". Internal.
v1.0.54 (2021-10-14)
Fix for Result.str to handle Edge fields
Datafile's content now don't contain empty records
v1.0.53 (2021-08-26)
Product aware instance: allows to access edge just instanciating your api with
api = RPApi(product="edge")v1.0.52 (2021-08-20)
Entity-type-reference: support to retrieve a reference in the past. It also
supports to specify reference_type="delta" to retrieve just a daily
difference of the changes (only for Edge).
v1.0.51 (2021-08-11)
Insider-transactions and Earnings-Dates API support: list the available files and download them to automate your process
v1.0.50 (2021-07-20)
Fix for Python 2.7 compatibility
v1.0.49 (2021-07-16)
Text analytics: support for uploading via source_url
v1.0.48 (2021-07-10)
Text analytics: support for the /text-extraction endpoint
v1.0.47 (2021-04-12)
Text analytics: Handle retry if too early on /metadata endpoint
v1.0.46 (2021-04-05)
Compatibility with RavenPack Edge
- loosen validation for entity-types (in Edge we have various dynamical EDETs)
- loosen validation for RT fields (in Edge we have several new fields)
v1.0.45 (2021-01-30)
- Support for
PRDT(product-type) in the entity_reference endpoint - Retry logic on 425 status code in some text-analytics API calls
v1.0.44 (2020-12-09)
- Retry logic on 404 status code in some text-analytics API calls
- Added entity type to the EntityTypeReference object
- Improved validation of invalid fields when initializing the dataset
v1.0.43 (2020-11-04)
- Entity-mapping - expose the matching score and the candidates
v1.0.42 (2020-10-19)
- Bug in pagination of files endpoint
v1.0.41 (2020-10-08)
get_status on an uploaded file now refreshes all of the metadata, not just
the status.
v1.0.40 -YANKED- (2020-10-07)
- Support for the /jobs endpoint (to list the user past endpoints)
NOTE* This version is not available in PyPI
v1.0.39 (2020-09-22)
- Persistent sessions between API-calls
v1.0.38 (2020-09-04)
- Text-Analytics API additional functions:
get_analyticsandget_annotated
v1.0.37 (2020-06-16)
- Creating and saving folders in Text-Analytics
- New
savemethod onFile
- Renamed filter
filenameparameter tofile_nameinUploadApi.list() - Entity reference is now sorted by
range_start
- Better error catching for realtime feed subscriptions
v1.0.36 (2020-05-14)
- Text-Analytics API endpoint updated: folders & richer metadata
- Extended error handling to support Feed disconnection problems
v1.0.35 (2020-02-22)
Initial support for the Text-Analytics API endpoints
v1.0.34 (2019-11-11)
Retrieve a lazy-loaded dataset when setting one of its paramters.
v1.0.33 (2019-10-17)
- A default timeout of 10" on connection and 60" on silence has been added to all the API calls
- Retrieve or save a flatfile using the new methods
get_flatfileandsave_flatfile. Seeget_historical_flat_list.pyfor a complete example.
v1.0.32 (2019-08-13)
The RPApi instance gets two new methods:
get_document_urlto retrieve the document url from a RP_STORY_IDget_flatfile_listto retrieve the list of the available flatfiles forcompaniesorfull(for all the entities)
v1.0.31 (2019-07-14)
- Ad-hoc
api.json()method now supportsconditionsandcustom_fields
v1.0.30 (2019-06-11)
- New parameter
common_request_paramsadded to the RT stream requests.
v1.0.29 (2019-05-21)
dataset creation explicit parameters
The Dataset parameters are not explictly passed in the constructor instead of being hidden in the kwargs.
This allows also to clearly support custom_fields and conditions.
A few new examples have been added or updated: get historical flat files and create a dataset with custom_fields and conditions.
v1.0.28 (2019-05-15)
New dataset.count method
dataset = api.get_dataset('us30')
data_count = ds.count(
start_date='2018-01-05 18:00:00',
end_date='2018-01-05 18:01:00',
)
# {'count': 11, 'stories': 10, 'entities': 6}v1.0.27 (2019-05-03)
- New
ApiConnectionError request_realtimemethod now supportskeep_alive
v1.0.26 (2019-04-23)
New common_request_params attribute on the RPApi object to send extra
params to the requests library
v1.0.25 (2019-03-12)
request_realtime now doesn't buffer RT requests to avoid waiting for chunks.
v1.0.24 (2018-20-11)
Support for the job cancellation endpoint (while a job is in the ENQUEUED state)
job = ds.request_datafile(...)
job.cancel()Job.wait_for_completion raises an exception if the job goes in ERROR so we
don't wait forever.
v1.0.23 (2018-09-20)
Fixed encoding issues with differences in Python2 and Python3
Jobs are now iterable
v1.0.22 (2018-09-12)
Created EntityTypeReference to query the whole of entity reference
v1.0.21 (2018-07-24)
Requesting Ad-Hoc json() will use the dataset frequency as the default one
v1.0.20 (2018-07-19)
Saving job to file raises an exception when there is an error in the API call
v1.0.19 (2018-05-03)
Added 2 more options (SPLIT_WEEKLY and SPLIT_DAILY) to the method time_intervals, used to download a datafile in chunks:
from ravenpackapi.util import (
SPLIT_YEARLY,
SPLIT_MONTHLY,
SPLIT_WEEKLY,
SPLIT_DAILY,
time_intervals
)
split = SPLIT_DAILY
for range_start, range_end in time_intervals(start_date, end_date, split=split):
job = ds.request_datafile(
start_date=range_start,
end_date=range_end,
compressed=GET_COMPRESSED,
)
...v1.0.18 (2018-04-17)
Now datasets can not only be created but updated as well via the
dataset.save() method.
v1.0.17 (2018-03-29)
Hotfix for missing module in package.
v1.0.16 (2018-03-29)
Hotfix for missing module in package.
v1.0.15 (2018-03-13)
New get_entity_mapping method to retrieve the entity mapping
Fix bug with encoding in Python2
v1.0.14 (2018-03-09)
Timezone support for datafiles
custom_dataset = Dataset(
api=api,
name="Us30 indicators",
filters=us30.filters,
fields=new_fields,
frequency='daily'
)
custom_dataset.save()
print(custom_dataset)
job = custom_dataset.request_datafile(
start_date='2017-01-01 19:30',
end_date='2017-01-02 19:30',
compressed=True,
time_zone='Europe/London',
)v1.0.13 (2018-03-08)
Better error handling requesting datafiles via ds.request_datafile()
v1.0.12 (2018-03-08)
v1.0.11 (2018-03-08)
- Requesting a datafile now raises an
APIExceptionwhen the API returns a400code. - Date params on the datafile request can be now both strings and datetime objects.
Added helper method time_intervals to split the datafile requests in smaller
intervals.
v1.0.10 (2018-03-06)
iterate_results() method now returns rows as a list of strings, rather than a
single string.
v1.0.9 (2018-03-06)
- New
Dataset.save()method to create new datasets. - New
Job.iterate_results()method to iterate over the rows of the results without saving the file.
v1.0.8 (2018-03-06)
Fixed missing dependencies
v1.0.7 (2018-03-05)
New Dataset.request_realtime method to request data in real-time.
New Result object to map analytic fields
v1.0.6 (2018-03-02)
Allow dataset requests to be tagged
v1.0.5 (2018-03-02)
v1.0.4 (2018-03-02)
v1.0.3 (2018-02-20)
New methods in RPEntityMetadata
v1.0.2 (2018-01-30)
Getting entity reference through get_entity_reference.
v1.0.1 (2018-01-30)
- New methods in
RPApiapi.get_dataset()to retrieve an existing dataset from the APIapi.json()to make an ad-hoc request
- New methods in the
DatasetclassDataset.delete()Dataset.json()Dataset.request_datafile()
- New
DatasetListclass to list all the datasets in the account - More attributes and methods on the Job object
get_status()wait_for_completion()save_to_file()
v1.0.0 (2018-01-26)
First non-beta release