flywheel-sdk 19.2.0__py2.py3-none-any.whl → 19.3.0__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -263,8 +263,9 @@ class SubjectsApi(object):
263
263
  collection_formats=collection_formats)
264
264
 
265
265
  def add_subject_analysis_note(self, container_id, analysis_id, body, **kwargs): # noqa: E501
266
- """Add a note to subject analysis.
266
+ """Add a note to a(n) subject analysis.
267
267
 
268
+ Add a note to a(n) subject analysis.
268
269
  This method makes a synchronous HTTP request by default.
269
270
 
270
271
  :param str container_id: 24-char hex id (required)
@@ -290,8 +291,9 @@ class SubjectsApi(object):
290
291
 
291
292
 
292
293
  def add_subject_analysis_note_with_http_info(self, container_id, analysis_id, body, **kwargs): # noqa: E501
293
- """Add a note to subject analysis.
294
+ """Add a note to a(n) subject analysis.
294
295
 
296
+ Add a note to a(n) subject analysis.
295
297
  This method makes a synchronous HTTP request by default.
296
298
 
297
299
  :param str container_id: 24-char hex id (required)
@@ -384,8 +386,9 @@ class SubjectsApi(object):
384
386
  collection_formats=collection_formats)
385
387
 
386
388
  def add_subject_note(self, container_id, body, **kwargs): # noqa: E501
387
- """Add a note to subject.
389
+ """Add a note to a(n) subject.
388
390
 
391
+ Add a note to a(n) subject.
389
392
  This method makes a synchronous HTTP request by default.
390
393
 
391
394
  :param str container_id: (required)
@@ -410,8 +413,9 @@ class SubjectsApi(object):
410
413
 
411
414
 
412
415
  def add_subject_note_with_http_info(self, container_id, body, **kwargs): # noqa: E501
413
- """Add a note to subject.
416
+ """Add a note to a(n) subject.
414
417
 
418
+ Add a note to a(n) subject.
415
419
  This method makes a synchronous HTTP request by default.
416
420
 
417
421
  :param str container_id: (required)
@@ -497,7 +501,7 @@ class SubjectsApi(object):
497
501
  collection_formats=collection_formats)
498
502
 
499
503
  def add_subject_tag(self, cid, body, **kwargs): # noqa: E501
500
- """Add a tag to subject.
504
+ """Add a tag to a(n) subject.
501
505
 
502
506
  Propagates changes to projects, sessions and acquisitions
503
507
  This method makes a synchronous HTTP request by default.
@@ -524,7 +528,7 @@ class SubjectsApi(object):
524
528
 
525
529
 
526
530
  def add_subject_tag_with_http_info(self, cid, body, **kwargs): # noqa: E501
527
- """Add a tag to subject.
531
+ """Add a tag to a(n) subject.
528
532
 
529
533
  Propagates changes to projects, sessions and acquisitions
530
534
  This method makes a synchronous HTTP request by default.
@@ -612,9 +616,9 @@ class SubjectsApi(object):
612
616
  collection_formats=collection_formats)
613
617
 
614
618
  def add_subject_tags(self, cid, body, **kwargs): # noqa: E501
615
- """Add multiple tags to subject
619
+ """Add multiple tags to a(n) subject
616
620
 
617
- Add multiple tags to subject
621
+ Add multiple tags to a(n) subject
618
622
  This method makes a synchronous HTTP request by default.
619
623
 
620
624
  :param str cid: (required)
@@ -639,9 +643,9 @@ class SubjectsApi(object):
639
643
 
640
644
 
641
645
  def add_subject_tags_with_http_info(self, cid, body, **kwargs): # noqa: E501
642
- """Add multiple tags to subject
646
+ """Add multiple tags to a(n) subject
643
647
 
644
- Add multiple tags to subject
648
+ Add multiple tags to a(n) subject
645
649
  This method makes a synchronous HTTP request by default.
646
650
 
647
651
  :param str cid: (required)
@@ -927,7 +931,7 @@ class SubjectsApi(object):
927
931
  collection_formats=collection_formats)
928
932
 
929
933
  def delete_subject_analysis(self, cid, analysis_id, **kwargs): # noqa: E501
930
- """Delete an anaylsis
934
+ """Delete an analysis
931
935
 
932
936
  Delete an analysis for a container.
933
937
  This method makes a synchronous HTTP request by default.
@@ -955,7 +959,7 @@ class SubjectsApi(object):
955
959
 
956
960
 
957
961
  def delete_subject_analysis_with_http_info(self, cid, analysis_id, **kwargs): # noqa: E501
958
- """Delete an anaylsis
962
+ """Delete an analysis
959
963
 
960
964
  Delete an analysis for a container.
961
965
  This method makes a synchronous HTTP request by default.
@@ -1035,9 +1039,9 @@ class SubjectsApi(object):
1035
1039
  collection_formats=collection_formats)
1036
1040
 
1037
1041
  def delete_subject_analysis_note(self, cid, analysis_id, note_id, **kwargs): # noqa: E501
1038
- """Remove a note from subject analysis.
1042
+ """Remove a note from a(n) subject analysis.
1039
1043
 
1040
- Remove a note from subject analysis.
1044
+ Remove a note from a(n) subject analysis.
1041
1045
  This method makes a synchronous HTTP request by default.
1042
1046
 
1043
1047
  :param str cid: 24-char hex id (required)
@@ -1063,9 +1067,9 @@ class SubjectsApi(object):
1063
1067
 
1064
1068
 
1065
1069
  def delete_subject_analysis_note_with_http_info(self, cid, analysis_id, note_id, **kwargs): # noqa: E501
1066
- """Remove a note from subject analysis.
1070
+ """Remove a note from a(n) subject analysis.
1067
1071
 
1068
- Remove a note from subject analysis.
1072
+ Remove a note from a(n) subject analysis.
1069
1073
  This method makes a synchronous HTTP request by default.
1070
1074
 
1071
1075
  :param str cid: 24-char hex id (required)
@@ -1259,9 +1263,9 @@ class SubjectsApi(object):
1259
1263
  collection_formats=collection_formats)
1260
1264
 
1261
1265
  def delete_subject_note(self, cid, note_id, **kwargs): # noqa: E501
1262
- """Remove a note from subject
1266
+ """Remove a note from a(n) subject
1263
1267
 
1264
- Remove a note from subject
1268
+ Remove a note from a(n) subject
1265
1269
  This method makes a synchronous HTTP request by default.
1266
1270
 
1267
1271
  :param str cid: (required)
@@ -1286,9 +1290,9 @@ class SubjectsApi(object):
1286
1290
 
1287
1291
 
1288
1292
  def delete_subject_note_with_http_info(self, cid, note_id, **kwargs): # noqa: E501
1289
- """Remove a note from subject
1293
+ """Remove a note from a(n) subject
1290
1294
 
1291
- Remove a note from subject
1295
+ Remove a note from a(n) subject
1292
1296
  This method makes a synchronous HTTP request by default.
1293
1297
 
1294
1298
  :param str cid: (required)
@@ -1467,9 +1471,9 @@ class SubjectsApi(object):
1467
1471
  collection_formats=collection_formats)
1468
1472
 
1469
1473
  def delete_subject_tags(self, cid, body, **kwargs): # noqa: E501
1470
- """Delete multiple tags from subject
1474
+ """Delete multiple tags from a(n) subject
1471
1475
 
1472
- Delete multiple tags from subject
1476
+ Delete multiple tags from a(n) subject
1473
1477
  This method makes a synchronous HTTP request by default.
1474
1478
 
1475
1479
  :param str cid: (required)
@@ -1494,9 +1498,9 @@ class SubjectsApi(object):
1494
1498
 
1495
1499
 
1496
1500
  def delete_subject_tags_with_http_info(self, cid, body, **kwargs): # noqa: E501
1497
- """Delete multiple tags from subject
1501
+ """Delete multiple tags from a(n) subject
1498
1502
 
1499
- Delete multiple tags from subject
1503
+ Delete multiple tags from a(n) subject
1500
1504
  This method makes a synchronous HTTP request by default.
1501
1505
 
1502
1506
  :param str cid: (required)
@@ -1574,13 +1578,117 @@ class SubjectsApi(object):
1574
1578
  _request_out=params.get('_request_out'),
1575
1579
  collection_formats=collection_formats)
1576
1580
 
1581
+ def delete_subjects_by_ids(self, body, **kwargs): # noqa: E501
1582
+ """Delete multiple subjects by ID list
1583
+
1584
+ Delete multiple subjects by ID list
1585
+ This method makes a synchronous HTTP request by default.
1586
+
1587
+ :param list[str] body: List of IDs to delete (required)
1588
+ :param ContainerDeleteReason delete_reason:
1589
+ :param bool async_: Perform the request asynchronously
1590
+ :return: DeletedResult
1591
+ """
1592
+ ignore_simplified_return_value = kwargs.pop('_ignore_simplified_return_value', False)
1593
+ kwargs['_return_http_data_only'] = True
1594
+
1595
+ if kwargs.get('async_'):
1596
+ return self.delete_subjects_by_ids_with_http_info(body, **kwargs) # noqa: E501
1597
+ else:
1598
+ (data) = self.delete_subjects_by_ids_with_http_info(body, **kwargs) # noqa: E501
1599
+ if (
1600
+ data
1601
+ and hasattr(data, 'return_value')
1602
+ and not ignore_simplified_return_value
1603
+ ):
1604
+ return data.return_value()
1605
+ return data
1606
+
1607
+
1608
+ def delete_subjects_by_ids_with_http_info(self, body, **kwargs): # noqa: E501
1609
+ """Delete multiple subjects by ID list
1610
+
1611
+ Delete multiple subjects by ID list
1612
+ This method makes a synchronous HTTP request by default.
1613
+
1614
+ :param list[str] body: List of IDs to delete (required)
1615
+ :param ContainerDeleteReason delete_reason:
1616
+ :param bool async_: Perform the request asynchronously
1617
+ :return: DeletedResult
1618
+ """
1619
+
1620
+ all_params = ['body','delete_reason',] # noqa: E501
1621
+ all_params.append('async_')
1622
+ all_params.append('_return_http_data_only')
1623
+ all_params.append('_preload_content')
1624
+ all_params.append('_request_timeout')
1625
+ all_params.append('_request_out')
1626
+
1627
+ params = locals()
1628
+ for key, val in six.iteritems(params['kwargs']):
1629
+ if key not in all_params:
1630
+ raise TypeError(
1631
+ "Got an unexpected keyword argument '%s'"
1632
+ " to method delete_subjects_by_ids" % key
1633
+ )
1634
+ params[key] = val
1635
+ del params['kwargs']
1636
+ # verify the required parameter 'body' is set
1637
+ if ('body' not in params or
1638
+ params['body'] is None):
1639
+ raise ValueError("Missing the required parameter `body` when calling `delete_subjects_by_ids`") # noqa: E501
1640
+
1641
+ collection_formats = {}
1642
+
1643
+ path_params = {}
1644
+
1645
+ query_params = []
1646
+ if 'delete_reason' in params:
1647
+ query_params.append(('delete_reason', params['delete_reason'])) # noqa: E501
1648
+
1649
+ header_params = {}
1650
+
1651
+ form_params = []
1652
+ local_var_files = {}
1653
+
1654
+ body_params = None
1655
+ if 'body' in params:
1656
+ body_params = params['body']
1657
+ # HTTP header `Accept`
1658
+ header_params['Accept'] = self.api_client.select_header_accept(
1659
+ ['application/json']) # noqa: E501
1660
+
1661
+ # HTTP header `Content-Type`
1662
+ header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
1663
+ ['application/json']) # noqa: E501
1664
+
1665
+ # Authentication setting
1666
+ auth_settings = ['ApiKey'] # noqa: E501
1667
+
1668
+ return self.api_client.call_api(
1669
+ '/subjects', 'DELETE',
1670
+ path_params,
1671
+ query_params,
1672
+ header_params,
1673
+ body=body_params,
1674
+ post_params=form_params,
1675
+ files=local_var_files,
1676
+ response_type='DeletedResult', # noqa: E501
1677
+ auth_settings=auth_settings,
1678
+ async_=params.get('async_'),
1679
+ _return_http_data_only=params.get('_return_http_data_only'),
1680
+ _preload_content=params.get('_preload_content', True),
1681
+ _request_timeout=params.get('_request_timeout'),
1682
+ _request_out=params.get('_request_out'),
1683
+ collection_formats=collection_formats)
1684
+
1577
1685
  def download_file_from_subject(self, subject_id, file_name, dest_file, **kwargs): # noqa: E501
1578
1686
  """Download a file.
1579
1687
 
1580
1688
  Files can be downloaded directly from this endpoint with a valid \"Authorization\" header or via a ticket id. To generate a ticket: - Make a request with an empty \"ticket\" parameter and a valid \"Authorization\" header. The server will respond with a generated ticket id. - Make another request with the received ticket id in the \"ticket\" parameter. A valid \"Authorization\" header is no longer required. When \"view\" is true, [RFC7233](https://tools.ietf.org/html/rfc7233) range request headers are supported. When virus_scan feature is enabled the quarantined files only can be downloaded using signed urls otherwise it will return with a HTTP 400 response.
1581
1689
  This method makes a synchronous HTTP request by default.
1582
1690
 
1583
- :param str subject_id: 24-char hex id (required)
1691
+ :param str subject_id: 24-character hex ID (required)
1584
1692
  :param str file_name: output file name (required)
1585
1693
  :param bool info: If the file is a zipfile, return a json response of zipfile member information
1586
1694
  :param str member: The filename of a zipfile member to download rather than the entire file
@@ -1614,7 +1722,7 @@ class SubjectsApi(object):
1614
1722
  Files can be downloaded directly from this endpoint with a valid \"Authorization\" header or via a ticket id. To generate a ticket: - Make a request with an empty \"ticket\" parameter and a valid \"Authorization\" header. The server will respond with a generated ticket id. - Make another request with the received ticket id in the \"ticket\" parameter. A valid \"Authorization\" header is no longer required. When \"view\" is true, [RFC7233](https://tools.ietf.org/html/rfc7233) range request headers are supported. When virus_scan feature is enabled the quarantined files only can be downloaded using signed urls otherwise it will return with a HTTP 400 response.
1615
1723
  This method makes a synchronous HTTP request by default.
1616
1724
 
1617
- :param str subject_id: 24-char hex id (required)
1725
+ :param str subject_id: 24-character hex ID (required)
1618
1726
  :param str file_name: output file name (required)
1619
1727
  :param bool info: If the file is a zipfile, return a json response of zipfile member information
1620
1728
  :param str member: The filename of a zipfile member to download rather than the entire file
@@ -1713,7 +1821,7 @@ class SubjectsApi(object):
1713
1821
  Files can be downloaded directly from this endpoint with a valid \"Authorization\" header or via a ticket id. To generate a ticket: - Make a request with an empty \"ticket\" parameter and a valid \"Authorization\" header. The server will respond with a generated ticket id. - Make another request with the received ticket id in the \"ticket\" parameter. A valid \"Authorization\" header is no longer required. When \"view\" is true, [RFC7233](https://tools.ietf.org/html/rfc7233) range request headers are supported. When virus_scan feature is enabled the quarantined files only can be downloaded using signed urls otherwise it will return with a HTTP 400 response.
1714
1822
  This method makes a synchronous HTTP request by default.
1715
1823
 
1716
- :param str subject_id: 24-char hex id (required)
1824
+ :param str subject_id: 24-character hex ID (required)
1717
1825
  :param str file_name: output file name (required)
1718
1826
  :param str ticket: The generated ticket id for the download, or present but empty to generate a ticket id
1719
1827
  :param bool info: If the file is a zipfile, return a json response of zipfile member information
@@ -1748,7 +1856,7 @@ class SubjectsApi(object):
1748
1856
  Files can be downloaded directly from this endpoint with a valid \"Authorization\" header or via a ticket id. To generate a ticket: - Make a request with an empty \"ticket\" parameter and a valid \"Authorization\" header. The server will respond with a generated ticket id. - Make another request with the received ticket id in the \"ticket\" parameter. A valid \"Authorization\" header is no longer required. When \"view\" is true, [RFC7233](https://tools.ietf.org/html/rfc7233) range request headers are supported. When virus_scan feature is enabled the quarantined files only can be downloaded using signed urls otherwise it will return with a HTTP 400 response.
1749
1857
  This method makes a synchronous HTTP request by default.
1750
1858
 
1751
- :param str subject_id: 24-char hex id (required)
1859
+ :param str subject_id: 24-character hex ID (required)
1752
1860
  :param str file_name: output file name (required)
1753
1861
  :param str ticket: The generated ticket id for the download, or present but empty to generate a ticket id
1754
1862
  :param bool info: If the file is a zipfile, return a json response of zipfile member information
@@ -1852,7 +1960,7 @@ class SubjectsApi(object):
1852
1960
  Files can be downloaded directly from this endpoint with a valid \"Authorization\" header or via a ticket id. To generate a ticket: - Make a request with an empty \"ticket\" parameter and a valid \"Authorization\" header. The server will respond with a generated ticket id. - Make another request with the received ticket id in the \"ticket\" parameter. A valid \"Authorization\" header is no longer required. When \"view\" is true, [RFC7233](https://tools.ietf.org/html/rfc7233) range request headers are supported. When virus_scan feature is enabled the quarantined files only can be downloaded using signed urls otherwise it will return with a HTTP 400 response.
1853
1961
  This method makes a synchronous HTTP request by default.
1854
1962
 
1855
- :param str subject_id: 24-char hex id (required)
1963
+ :param str subject_id: 24-character hex ID (required)
1856
1964
  :param str file_name: output file name (required)
1857
1965
  :param str ticket: The generated ticket id for the download, or present but empty to generate a ticket id
1858
1966
  :param bool info: If the file is a zipfile, return a json response of zipfile member information
@@ -1887,7 +1995,7 @@ class SubjectsApi(object):
1887
1995
  Files can be downloaded directly from this endpoint with a valid \"Authorization\" header or via a ticket id. To generate a ticket: - Make a request with an empty \"ticket\" parameter and a valid \"Authorization\" header. The server will respond with a generated ticket id. - Make another request with the received ticket id in the \"ticket\" parameter. A valid \"Authorization\" header is no longer required. When \"view\" is true, [RFC7233](https://tools.ietf.org/html/rfc7233) range request headers are supported. When virus_scan feature is enabled the quarantined files only can be downloaded using signed urls otherwise it will return with a HTTP 400 response.
1888
1996
  This method makes a synchronous HTTP request by default.
1889
1997
 
1890
- :param str subject_id: 24-char hex id (required)
1998
+ :param str subject_id: 24-character hex ID (required)
1891
1999
  :param str file_name: output file name (required)
1892
2000
  :param str ticket: The generated ticket id for the download, or present but empty to generate a ticket id
1893
2001
  :param bool info: If the file is a zipfile, return a json response of zipfile member information
@@ -3040,7 +3148,7 @@ class SubjectsApi(object):
3040
3148
  collection_formats=collection_formats)
3041
3149
 
3042
3150
  def get_subject_analyses(self, cid, **kwargs): # noqa: E501
3043
- """Get analyses for subject.
3151
+ """Get analyses for a(n) subject.
3044
3152
 
3045
3153
  Returns analyses that directly belong to this resource.
3046
3154
  This method makes a synchronous HTTP request by default.
@@ -3076,7 +3184,7 @@ class SubjectsApi(object):
3076
3184
 
3077
3185
 
3078
3186
  def get_subject_analyses_with_http_info(self, cid, **kwargs): # noqa: E501
3079
- """Get analyses for subject.
3187
+ """Get analyses for a(n) subject.
3080
3188
 
3081
3189
  Returns analyses that directly belong to this resource.
3082
3190
  This method makes a synchronous HTTP request by default.
@@ -3298,7 +3406,7 @@ class SubjectsApi(object):
3298
3406
  Get info for a particular file.
3299
3407
  This method makes a synchronous HTTP request by default.
3300
3408
 
3301
- :param str cid: (required)
3409
+ :param str cid: Container Id (required)
3302
3410
  :param str filename: (required)
3303
3411
  :param bool async_: Perform the request asynchronously
3304
3412
  :return: FileOutput
@@ -3325,7 +3433,7 @@ class SubjectsApi(object):
3325
3433
  Get info for a particular file.
3326
3434
  This method makes a synchronous HTTP request by default.
3327
3435
 
3328
- :param str cid: (required)
3436
+ :param str cid: Container Id (required)
3329
3437
  :param str filename: (required)
3330
3438
  :param bool async_: Perform the request asynchronously
3331
3439
  :return: FileOutput
@@ -3397,9 +3505,9 @@ class SubjectsApi(object):
3397
3505
  collection_formats=collection_formats)
3398
3506
 
3399
3507
  def get_subject_note(self, cid, note_id, **kwargs): # noqa: E501
3400
- """Get a note on subject.
3508
+ """Get a note of a(n) subject.
3401
3509
 
3402
- Get a note on subject
3510
+ Get a note of a(n) subject
3403
3511
  This method makes a synchronous HTTP request by default.
3404
3512
 
3405
3513
  :param str cid: (required)
@@ -3424,9 +3532,9 @@ class SubjectsApi(object):
3424
3532
 
3425
3533
 
3426
3534
  def get_subject_note_with_http_info(self, cid, note_id, **kwargs): # noqa: E501
3427
- """Get a note on subject.
3535
+ """Get a note of a(n) subject.
3428
3536
 
3429
- Get a note on subject
3537
+ Get a note of a(n) subject
3430
3538
  This method makes a synchronous HTTP request by default.
3431
3539
 
3432
3540
  :param str cid: (required)
@@ -4341,9 +4449,9 @@ class SubjectsApi(object):
4341
4449
  collection_formats=collection_formats)
4342
4450
 
4343
4451
  def modify_subject_info(self, cid, body, **kwargs): # noqa: E501
4344
- """Update or replace info for a subject.
4452
+ """Update or replace info for a(n) subject.
4345
4453
 
4346
- Update or replace info for a subject.
4454
+ Update or replace info for a(n) subject.
4347
4455
  This method makes a synchronous HTTP request by default.
4348
4456
 
4349
4457
  :param str cid: (required)
@@ -4368,9 +4476,9 @@ class SubjectsApi(object):
4368
4476
 
4369
4477
 
4370
4478
  def modify_subject_info_with_http_info(self, cid, body, **kwargs): # noqa: E501
4371
- """Update or replace info for a subject.
4479
+ """Update or replace info for a(n) subject.
4372
4480
 
4373
- Update or replace info for a subject.
4481
+ Update or replace info for a(n) subject.
4374
4482
  This method makes a synchronous HTTP request by default.
4375
4483
 
4376
4484
  :param str cid: (required)
@@ -4456,9 +4564,9 @@ class SubjectsApi(object):
4456
4564
  collection_formats=collection_formats)
4457
4565
 
4458
4566
  def modify_subject_note(self, cid, note_id, body, **kwargs): # noqa: E501
4459
- """Update a note on subject.
4567
+ """Update a note of a(n) subject.
4460
4568
 
4461
- Update a note on subject
4569
+ Update a note of a(n) subject
4462
4570
  This method makes a synchronous HTTP request by default.
4463
4571
 
4464
4572
  :param str cid: (required)
@@ -4484,9 +4592,9 @@ class SubjectsApi(object):
4484
4592
 
4485
4593
 
4486
4594
  def modify_subject_note_with_http_info(self, cid, note_id, body, **kwargs): # noqa: E501
4487
- """Update a note on subject.
4595
+ """Update a note of a(n) subject.
4488
4596
 
4489
- Update a note on subject
4597
+ Update a note of a(n) subject
4490
4598
  This method makes a synchronous HTTP request by default.
4491
4599
 
4492
4600
  :param str cid: (required)
@@ -4702,8 +4810,9 @@ class SubjectsApi(object):
4702
4810
  collection_formats=collection_formats)
4703
4811
 
4704
4812
  def upload_file_to_subject(self, container_id, file, **kwargs): # noqa: E501
4705
- """Upload a file to subject.
4813
+ """Upload a file to a(n) subject.
4706
4814
 
4815
+ Upload a file to a(n) subject.
4707
4816
  This method makes a synchronous HTTP request by default.
4708
4817
 
4709
4818
  :param str container_id: (required)
@@ -4736,8 +4845,9 @@ class SubjectsApi(object):
4736
4845
 
4737
4846
 
4738
4847
  def upload_file_to_subject_with_http_info(self, container_id, file, **kwargs): # noqa: E501
4739
- """Upload a file to subject.
4848
+ """Upload a file to a(n) subject.
4740
4849
 
4850
+ Upload a file to a(n) subject.
4741
4851
  This method makes a synchronous HTTP request by default.
4742
4852
 
4743
4853
  :param str container_id: (required)
@@ -4841,9 +4951,9 @@ class SubjectsApi(object):
4841
4951
  collection_formats=collection_formats)
4842
4952
 
4843
4953
  def upload_output_to_subject_analysis(self, cid, analysis_id, file, **kwargs): # noqa: E501
4844
- """Upload an output file to analysis.
4954
+ """Upload an output file to an analysis.
4845
4955
 
4846
- Upload an output file to analysis
4956
+ Upload an output file to an analysis
4847
4957
  This method makes a synchronous HTTP request by default.
4848
4958
 
4849
4959
  :param str cid: (required)
@@ -4874,9 +4984,9 @@ class SubjectsApi(object):
4874
4984
 
4875
4985
 
4876
4986
  def upload_output_to_subject_analysis_with_http_info(self, cid, analysis_id, file, **kwargs): # noqa: E501
4877
- """Upload an output file to analysis.
4987
+ """Upload an output file to an analysis.
4878
4988
 
4879
- Upload an output file to analysis
4989
+ Upload an output file to an analysis
4880
4990
  This method makes a synchronous HTTP request by default.
4881
4991
 
4882
4992
  :param str cid: (required)
flywheel/api_client.py CHANGED
@@ -19,6 +19,7 @@ import os
19
19
  import re
20
20
  import tempfile
21
21
  import enum
22
+ import logging
22
23
 
23
24
  # python 2 and python 3 compatibility library
24
25
  import six
@@ -28,6 +29,8 @@ from flywheel.configuration import Configuration
28
29
  import flywheel.models
29
30
  from flywheel import rest, file_spec
30
31
 
32
+ log = logging.getLogger('Flywheel.ApiClient')
33
+
31
34
  # NOTE: This file is auto generated by the swagger code generator program.
32
35
  # Do not edit the class manually.
33
36
 
@@ -81,7 +84,7 @@ class ApiClient(object):
81
84
  self.default_query_params = []
82
85
  self.cookie = cookie
83
86
  # Set default User-Agent.
84
- self.user_agent = 'Swagger-Codegen/19.2.0/python'
87
+ self.user_agent = 'Swagger-Codegen/19.3.0/python'
85
88
  self.last_response = None
86
89
  self._version_check_fn = None
87
90
  self._context = context
@@ -329,24 +332,30 @@ class ApiClient(object):
329
332
  return self.__deserialize(data, skls)
330
333
  else:
331
334
  for skls in sub_kls:
332
- # TODO we need to find out what kind of try-except should be applied
333
- # here
334
335
  try:
335
336
  return self.__deserialize(data, skls)
336
- except NotImplementedError:
337
- continue
337
+ except ValueError as exc:
338
+ if (f"is not a valid {skls}" in str(exc) or
339
+ "Page response is not supported yet" in str(exc) or
340
+ "Unable to deserialize data as " in str(exc)):
341
+ continue
342
+ else:
343
+ raise
338
344
  raise TypeError(
339
345
  f"No class for container_type '{cont_type}' in {klass}"
340
346
  )
341
347
  # ---
342
348
 
343
349
  for skls in sub_kls:
344
- # TODO we need to find out what kind of try-except should be applied
345
- # here
346
350
  try:
347
351
  return self.__deserialize(data, skls)
348
- except NotImplementedError:
349
- continue
352
+ except ValueError as exc:
353
+ if (f"is not a valid {skls}" in str(exc) or
354
+ "Page response is not supported yet" in str(exc) or
355
+ "Unable to deserialize data as " in str(exc)):
356
+ continue
357
+ else:
358
+ raise
350
359
 
351
360
  # convert str to class
352
361
  klass_lower = klass.lower()
@@ -354,7 +363,7 @@ class ApiClient(object):
354
363
  klass = self.NATIVE_TYPES_MAPPING[klass_lower]
355
364
  else:
356
365
  if klass == 'Page':
357
- raise NotImplementedError('Page response is not supported yet')
366
+ raise ValueError('Page response is not supported yet')
358
367
  klass = getattr(flywheel.models, klass)
359
368
 
360
369
  if klass in self.PRIMITIVE_TYPES:
@@ -369,7 +378,7 @@ class ApiClient(object):
369
378
  return self.__deserialize_datatime(data)
370
379
  elif isinstance(data, dict):
371
380
  return self.__deserialize_model(data, klass)
372
- raise NotImplementedError(f"Unable to deserialize data as {klass}")
381
+ raise ValueError(f"Unable to deserialize data as {klass}")
373
382
 
374
383
  def call_api(self, resource_path, method,
375
384
  path_params=None, query_params=None, header_params=None,
@@ -649,7 +658,12 @@ class ApiClient(object):
649
658
 
650
659
  :return: Enum member.
651
660
  """
652
- return klass(data)
661
+ try:
662
+ return klass(data)
663
+ except ValueError:
664
+ # Per FLYW-24505, tolerate unrecognized enum values with a warning
665
+ log.warning(f"Unrecognized value {data!r} for enum {klass}")
666
+ return data
653
667
 
654
668
  def __deserialize_object(self, value):
655
669
  """Return a original value.
flywheel/configuration.py CHANGED
@@ -252,6 +252,6 @@ class Configuration(six.with_metaclass(TypeWithDefault, object)):
252
252
  return "Python SDK Debug Report:\n"\
253
253
  "OS: {env}\n"\
254
254
  "Python Version: {pyversion}\n"\
255
- "Version of the API: 19.2.0\n"\
256
- "SDK Package Version: 19.2.0".\
255
+ "Version of the API: 19.3.0\n"\
256
+ "SDK Package Version: 19.3.0".\
257
257
  format(env=sys.platform, pyversion=sys.version)