Skip to content
This repository was archived by the owner on Jan 6, 2023. It is now read-only.

Fix: Change reference to the raster used in raster cell sample to fix build error #1036

Merged
merged 1 commit into from
Feb 19, 2021

Conversation

yo1995
Copy link
Collaborator

@yo1995 yo1995 commented Feb 19, 2021

This PR fixes the issue in

by adjusting the on-demand raster used in Identify raster cell (#866) from Create Groups to Create Folder References, since the resource files come as a whole zip archive.

How to review

  • Do a fresh clone of the project from this branch and do a clean build.
  • On the first build, v.next will give an Build input file cannot be found: '$SRCROOT/Portal Data/Archives/SA_EVI_8Day_03May20/SA_EVI_8Day_03May20.tif' error. The following builds won't give error since no additional portal item is added.
  • This branch won't give any error

The error is hard to replicate because it only happens on the very first build of the project, or when the Portal Data folder is deleted or partially changed.

Below attach some details
  1. Initially I thought this problem come when we made changes to the download-portal-item-data.swift script in Update download script for archive with multiple files #865 where we included better zip archive support for the download script.
  2. Later we found out the problem is actually with the build system upgrade that came with Xcode 10. In Xcode 10 we need to explicitly provide the build system a list of file paths, if those files are generated by one of the build phase. Otherwise the build system won't pick them up during the current build, which result in a Build input file cannot be found error.
  3. In Fix: Change download build phase output to avoid error #1024 Ting tried to move the Download Portal Item Data from build phase to a Pre-Action in the build scheme. But Phil indicated that is even worse than having an one-time error.
  4. Ting then tried to use xcfilelist to actually log the file paths downloaded. However, when going down this path, Ting found out the only files that cause this error are the rasters used in Identify raster cell. Adjusting their references and re-tag the on-demand resource tag solve the error.
  5. Therefore, we are not adding additional patches to the project in case the problem is solved.
Copy link
Contributor

@saratchandrakarumuri saratchandrakarumuri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fixes the build issue with download data

Copy link
Contributor

@philium philium left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! Thank you so much for investigating and fixing this bug.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
4 participants