Skip to content

UAT C1256946216-ASDC_DEV2 (CLARREO_SIMTEST_L1A) #884

UAT C1256946216-ASDC_DEV2 (CLARREO_SIMTEST_L1A)

UAT C1256946216-ASDC_DEV2 (CLARREO_SIMTEST_L1A) #884

GitHub Actions / Tested with Harmony failed Sep 24, 2024 in 0s

1 fail in 1m 39s

1 tests  ±0   0 ✅ ±0   1m 39s ⏱️ -10s
1 suites ±0   0 💤 ±0 
1 files   ±0   1 ❌ ±0 

Results for commit 69fa50b. ± Comparison against earlier commit a0e74d2.

Annotations

Check warning on line 0 in tests.verify_collection

See this annotation in the file changed.

@github-actions github-actions / Tested with Harmony

test_concatenate[C1256946216-ASDC_DEV2] (tests.verify_collection) failed

test-results/test_report.xml [took 1m 36s]
Raw output
AssertionError: assert 1 == 2
 +  where 1 = len(<class 'netCDF4._netCDF4.Variable'>\nvlen subset_files(subset_index)\n    long_name: List of subsetted files used to create this merge product.\nvlen data type: <class 'str'>\nunlimited dimensions: \ncurrent shape = (1,))
collection_concept_id = 'C1256946216-ASDC_DEV2'
harmony_env = <Environment.UAT: 3>
bearer_token = 'eyJ0eXAiOiJKV1QiLCJvcmlnaW4iOiJFYXJ0aGRhdGEgTG9naW4iLCJzaWciOiJlZGxqd3RwdWJrZXlfdWF0IiwiYWxnIjoiUlMyNTYifQ.eyJ0eXBlIj...IdabNmCJplKiv8UZ_V3Zm05f1pUhqu2W9dM4eOOh74bzTdWX_4ehyL0BTmA62ucCaqr4SwFVd69MJoSyfH74bYAIJeEGCujbTOXcMreeOQGDwKQODHhxBg'

    @pytest.mark.timeout(600)
    def test_concatenate(collection_concept_id, harmony_env, bearer_token):
    
        max_results = 2
        harmony_client = harmony.Client(env=harmony_env, token=bearer_token)
        collection = harmony.Collection(id=collection_concept_id)
        latest_granule_ids = get_latest_granules(collection_concept_id, max_results, harmony_env, bearer_token)
    
        if latest_granule_ids is None:
            if harmony_env == harmony.config.Environment.UAT:
                pytest.skip(f"No granules found for UAT collection {collection_concept_id}")
            raise Exception('Bad Request', 'Error: No matching granules found.')
    
        request = harmony.Request(
            collection=collection,
            concatenate=True,
            max_results=max_results,
            granule_id=latest_granule_ids,
            skip_preview=True,
            format="application/x-netcdf4",
        )
    
        request.is_valid()
    
        logging.info("Sending harmony request %s", harmony_client.request_as_url(request))
    
        try:
            job1_id = harmony_client.submit(request)
        except Exception as ex:
            if str(ex) == "('Bad Request', 'Error: No matching granules found.')":
                if harmony_env == harmony.config.Environment.UAT:
                    pytest.skip(f"No granules found for UAT collection {collection_concept_id}")
            raise ex
    
        logging.info(f'\n{job1_id}')
    
        logging.info(harmony_client.status(job1_id))
    
        logging.info('\nWaiting for the job to finish')
    
        results = harmony_client.result_json(job1_id)
    
        logging.info('\nDownloading results:')
    
        futures = harmony_client.download_all(job1_id)
        file_names = [f.result() for f in futures]
        logging.info('\nDone downloading.')
    
        filename = file_names[0]
    
        # Handle time dimension and variables dropping
        merge_dataset = netCDF4.Dataset(filename, 'r')
    
        headers = {
            "Authorization": f"Bearer {bearer_token}"
        }
    
        original_files = merge_dataset.variables['subset_files']
        history_json = json.loads(merge_dataset.history_json)
>       assert len(original_files) == max_results
E       AssertionError: assert 1 == 2
E        +  where 1 = len(<class 'netCDF4._netCDF4.Variable'>\nvlen subset_files(subset_index)\n    long_name: List of subsetted files used to create this merge product.\nvlen data type: <class 'str'>\nunlimited dimensions: \ncurrent shape = (1,))

tests/verify_collection.py:289: AssertionError
--------------------------------- Captured Log ---------------------------------
INFO     root:verify_collection.py:254 Sending harmony request https://harmony.uat.earthdata.nasa.gov/C1256946216-ASDC_DEV2/ogc-api-coverages/1.0.0/collections/all/coverage/rangeset?forceAsync=true&granuleId=G1262213008-ASDC_DEV2&granuleId=G1262213002-ASDC_DEV2&format=application%2Fx-netcdf4&maxResults=2&concatenate=true&skipPreview=true
INFO     root:verify_collection.py:264 
34c302ee-a8cf-46c9-9dd2-383dc34074ed
INFO     root:verify_collection.py:266 {'status': 'running', 'message': 'The job is being processed', 'progress': 9, 'created_at': datetime.datetime(2024, 9, 24, 8, 29, 45, 399000, tzinfo=tzlocal()), 'updated_at': datetime.datetime(2024, 9, 24, 8, 29, 46, 118000, tzinfo=tzlocal()), 'created_at_local': '2024-09-24T08:29:45+00:00', 'updated_at_local': '2024-09-24T08:29:46+00:00', 'request': 'https://harmony.uat.earthdata.nasa.gov/C1256946216-ASDC_DEV2/ogc-api-coverages/1.0.0/collections/all/coverage/rangeset?forceAsync=true&granuleId=G1262213008-ASDC_DEV2%2CG1262213002-ASDC_DEV2&format=application%2Fx-netcdf4&maxResults=2&concatenate=true&skipPreview=true', 'num_input_granules': 2, 'data_expiration': datetime.datetime(2024, 10, 24, 8, 29, 45, 399000, tzinfo=tzlocal()), 'data_expiration_local': '2024-10-24T08:29:45+00:00'}
INFO     root:verify_collection.py:268 
Waiting for the job to finish
INFO     root:verify_collection.py:272 
Downloading results:
INFO     root:verify_collection.py:276 
Done downloading.