Skip to content

Commit

Permalink
Merge branch 'main' into feat/large-log-chunking
Browse files Browse the repository at this point in the history
  • Loading branch information
edusperoni authored Jun 25, 2024
2 parents f6282e6 + 5088f5f commit 3220fe1
Show file tree
Hide file tree
Showing 153 changed files with 28,346 additions and 465 deletions.
60 changes: 39 additions & 21 deletions .github/workflows/npm_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,23 @@ on:
branches:
- main
tags:
- 'v*'
- "v*"

env:
NPM_TAG: "next"
XCODE_VERSION: "^15.0"

jobs:
build:
name: Build
runs-on: macos-12
runs-on: macos-14
outputs:
npm_version: ${{ steps.npm_version_output.outputs.NPM_VERSION }}
npm_tag: ${{ steps.npm_version_output.outputs.NPM_TAG }}
steps:
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: ${{env.XCODE_VERSION}}
- uses: actions/checkout@v3
with:
fetch-depth: 0
Expand All @@ -26,8 +30,8 @@ jobs:
key: ${{ hashFiles('download_llvm.sh') }}
- uses: actions/setup-node@v3
with:
node-version: 18
registry-url: 'https://registry.npmjs.org'
node-version: 20
registry-url: "https://registry.npmjs.org"
- name: Install Python
uses: actions/setup-python@v4
with:
Expand Down Expand Up @@ -55,22 +59,25 @@ jobs:
echo NPM_VERSION=$NPM_VERSION >> $GITHUB_OUTPUT
echo NPM_TAG=$NPM_TAG >> $GITHUB_OUTPUT
- name: Build
run: npm run build
run: npm run build-ios
- name: Upload npm package artifact
uses: actions/upload-artifact@v3
with:
name: npm-package
path: dist/nativescript-ios-${{env.NPM_VERSION}}.tgz
path: dist/nativescript-ios-${{steps.npm_version_output.outputs.NPM_VERSION}}.tgz
- name: Upload dSYMs artifact
uses: actions/upload-artifact@v3
with:
name: NativeScript-dSYMs
path: dist/dSYMs
test:
name: Test
runs-on: macos-12
runs-on: macos-14
needs: build
steps:
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: ${{env.XCODE_VERSION}}
- uses: actions/checkout@v3
- name: LLVM cache
uses: actions/cache@v3
Expand All @@ -79,7 +86,7 @@ jobs:
key: ${{ hashFiles('download_llvm.sh') }}
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
- name: Install Python
uses: actions/setup-python@v4
with:
Expand All @@ -94,37 +101,47 @@ jobs:
npm install -g @edusperoni/junit-cli-report-viewer verify-junit-xml
- name: Prepare
run: npm run setup-ci
- name: Prepare test folder
run: |
mkdir -p dist-test
echo TEST_FOLDER=$(pwd)/dist-test >> $GITHUB_ENV
- name: Xcode Tests
uses: nick-fields/retry@v2
# try to run the tests with xcpretty. If it fails then try again without xcpretty twice for better log output
# the xcode tests are a bit flaky and they should never fail on this step, as this step only collects the JS test results as junit xml
with:
timeout_minutes: 20
max_attempts: 3
command: set -o pipefail && xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $HOME/test_results -destination platform\=iOS\ Simulator,OS\=16.2,name\=iPhone\ 14\ Pro\ Max build test | xcpretty
on_retry_command: rm -rf $HOME/test_results*
new_command_on_retry: xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $HOME/test_results -destination platform\=iOS\ Simulator,OS\=16.2,name\=iPhone\ 14\ Pro\ Max build test
max_attempts: 2
command: set -o pipefail && xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $TEST_FOLDER/test_results -destination platform\=iOS\ Simulator,OS\=17.2,name\=iPhone\ 15\ Pro\ Max build test | xcpretty
on_retry_command: rm -rf $TEST_FOLDER/test_results* && xcrun simctl shutdown all
new_command_on_retry: xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $TEST_FOLDER/test_results -destination platform\=iOS\ Simulator,OS\=17.2,name\=iPhone\ 15\ Pro\ Max build test
- name: Validate Test Results
run: |
xcparse attachments $HOME/test_results.xcresult $HOME/test-out
find $HOME/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx junit-cli-report-viewer
find $HOME/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx verify-junit-xml
xcparse attachments $TEST_FOLDER/test_results.xcresult $TEST_FOLDER/test-out
find $TEST_FOLDER/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx junit-cli-report-viewer
find $TEST_FOLDER/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx verify-junit-xml
- name: Archive Test Result Data
if: always()
uses: actions/upload-artifact@v3
with:
name: test-results
path: ${{env.TEST_FOLDER}}/test_results.xcresult
publish:
runs-on: ubuntu-latest
needs:
- build
- test
permissions:
contents: read
id-token: write
contents: read
id-token: write
env:
NPM_VERSION: ${{needs.build.outputs.npm_version}}
NPM_TAG: ${{needs.build.outputs.npm_tag}}
steps:
- uses: actions/setup-node@v3
with:
node-version: 18
registry-url: 'https://registry.npmjs.org'
node-version: 20
registry-url: "https://registry.npmjs.org"
- uses: actions/download-artifact@v3
with:
name: npm-package
Expand Down Expand Up @@ -152,7 +169,7 @@ jobs:
fetch-depth: 0
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
- name: Setup
run: npm install
- uses: actions/download-artifact@v3
Expand All @@ -162,7 +179,7 @@ jobs:
- uses: actions/download-artifact@v3
with:
name: NativeScript-dSYMs
path: dist
path: dist/dSYMs
- name: Zip dSYMs
working-directory: dist/dSYMs
run: find . -maxdepth 1 -name '*.dSYM' -print | xargs -I@ zip -r @.zip @
Expand All @@ -172,3 +189,4 @@ jobs:
with:
artifacts: "dist/nativescript-ios-*.tgz,dist/dSYMs/*.zip"
bodyFile: "body.md"
prerelease: ${{needs.build.outputs.npm_tag != 'latest'}}
42 changes: 30 additions & 12 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,16 @@ on:

env:
NPM_TAG: "pr"
XCODE_VERSION: "^15.0"

jobs:
build:
name: Build
runs-on: macos-12
runs-on: macos-14
steps:
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: ${{env.XCODE_VERSION}}
- uses: actions/checkout@v3
with:
fetch-depth: 0
Expand All @@ -19,7 +23,7 @@ jobs:
key: ${{ hashFiles('download_llvm.sh') }}
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
- name: Install Python
uses: actions/setup-python@v4
with:
Expand All @@ -39,7 +43,7 @@ jobs:
echo NPM_VERSION=$NPM_VERSION >> $GITHUB_ENV
npm version $NPM_VERSION --no-git-tag-version
- name: Build
run: npm run build
run: npm run build-ios
- name: Upload npm package artifact
uses: actions/upload-artifact@v3
with:
Expand All @@ -52,9 +56,12 @@ jobs:
path: dist/dSYMs
test:
name: Test
runs-on: macos-12
runs-on: macos-14
needs: build
steps:
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: ${{env.XCODE_VERSION}}
- uses: actions/checkout@v3
- name: LLVM cache
uses: actions/cache@v3
Expand All @@ -63,7 +70,7 @@ jobs:
key: ${{ hashFiles('download_llvm.sh') }}
- uses: actions/setup-node@v3
with:
node-version: 18
node-version: 20
- name: Install Python
uses: actions/setup-python@v4
with:
Expand All @@ -76,18 +83,29 @@ jobs:
[ ! -f /usr/local/bin/cmake ] && ln -s /usr/local/bin/cmake $(which cmake) || true
brew install chargepoint/xcparse/xcparse
npm install -g @edusperoni/junit-cli-report-viewer verify-junit-xml
- name: Prepare test folder
id: prepare-test-folder
run: |
mkdir -p dist-test
echo TEST_FOLDER=$(pwd)/dist-test >> $GITHUB_ENV
- name: Xcode Tests
uses: nick-fields/retry@v2
# try to run the tests with xcpretty. If it fails then try again without xcpretty twice for better log output
# the xcode tests are a bit flaky and they should never fail on this step, as this step only collects the JS test results as junit xml
with:
timeout_minutes: 20
max_attempts: 3
command: set -o pipefail && xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $HOME/test_results -destination platform\=iOS\ Simulator,OS\=16.2,name\=iPhone\ 14\ Pro\ Max build test | xcpretty
on_retry_command: rm -rf $HOME/test_results*
new_command_on_retry: xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $HOME/test_results -destination platform\=iOS\ Simulator,OS\=16.2,name\=iPhone\ 14\ Pro\ Max build test
max_attempts: 2
command: set -o pipefail && xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $TEST_FOLDER/test_results -destination platform\=iOS\ Simulator,OS\=17.2,name\=iPhone\ 15\ Pro\ Max build test | xcpretty
on_retry_command: rm -rf $TEST_FOLDER/test_results* && xcrun simctl shutdown all
new_command_on_retry: xcodebuild -project v8ios.xcodeproj -scheme TestRunner -resultBundlePath $TEST_FOLDER/test_results -destination platform\=iOS\ Simulator,OS\=17.2,name\=iPhone\ 15\ Pro\ Max build test
- name: Validate Test Results
run: |
xcparse attachments $HOME/test_results.xcresult $HOME/test-out
find $HOME/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx junit-cli-report-viewer
find $HOME/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx verify-junit-xml
xcparse attachments $TEST_FOLDER/test_results.xcresult $TEST_FOLDER/test-out
find $TEST_FOLDER/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx junit-cli-report-viewer
find $TEST_FOLDER/test-out -name "*junit*.xml" -maxdepth 1 -print0 | xargs -n 1 -0 npx verify-junit-xml
- name: Archive Test Result Data
if: always()
uses: actions/upload-artifact@v3
with:
name: test-results
path: ${{env.TEST_FOLDER}}/test_results.xcresult
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,14 @@ v8
v8_build
.npmrc

llvm/
/llvm/

# v8 build files...
.gclient*
.cipd/

# project template
/project-template-ios/.build_env_vars.sh
/project-template-ios/__PROJECT_NAME__.xcodeproj/project.xcworkspace/xcshareddata/
/project-template-vision/.build_env_vars.sh
/project-template-vision/__PROJECT_NAME__.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
4 changes: 0 additions & 4 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,3 @@
path = libffi
url = https://github.com/NativeScript/libffi.git
branch = darind/v8-ios
[submodule "llvm"]
path = llvm
url = https://github.com/NativeScript/ios-llvm.git
branch = master
76 changes: 76 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,79 @@
## [8.7.2](https://github.com/NativeScript/ios/compare/v8.7.1...v8.7.2) (2024-05-16)


### Bug Fixes

* **ios:** watchOS embedded apps ([#250](https://github.com/NativeScript/ios/issues/250)) ([1df9ea2](https://github.com/NativeScript/ios/commit/1df9ea20b6bfde5163b0486e444e5471fb8343b2))



## [8.7.1](https://github.com/NativeScript/ios/compare/v8.7.0...v8.7.1) (2024-04-26)


### Bug Fixes

* url href ([#252](https://github.com/NativeScript/ios/issues/252)) ([4a6e9ad](https://github.com/NativeScript/ios/commit/4a6e9adde6950e09ac0c2fd2713e25aa919ad448))
* Xcode 15.3+ not setting TARGET_OS_IOS correctly ([#248](https://github.com/NativeScript/ios/issues/248)) ([74e1444](https://github.com/NativeScript/ios/commit/74e144432bf17cc043d0e64affc9cb1703e80832))



# [8.7.0](https://github.com/NativeScript/ios/compare/v8.6.3...v8.7.0) (2024-04-08)


### Bug Fixes

* only generate metadata for the targeted arch ([#236](https://github.com/NativeScript/ios/issues/236)) ([17a5c5f](https://github.com/NativeScript/ios/commit/17a5c5ff118c2803c0385891224fb30168268ac8))
* Xcode 15.3+ not setting TARGET_OS_IPHONE correctly ([#242](https://github.com/NativeScript/ios/issues/242)) ([0d52056](https://github.com/NativeScript/ios/commit/0d52056fdb102f40887abd47c9bc2af5f3cca94e))


### Features

* upgrade llvm to 15.0.7 ([#238](https://github.com/NativeScript/ios/issues/238)) ([6e9b51e](https://github.com/NativeScript/ios/commit/6e9b51e48c6b8ddf65c6669a035b97e5d935f202))
* **visionos:** support for xros platform ([#235](https://github.com/NativeScript/ios/issues/235)) ([bb364f9](https://github.com/NativeScript/ios/commit/bb364f9558c336c43a9c43d3ded46ef1ad8e8bf3))
* **WinterCG:** URL & URLSearchParams ([#234](https://github.com/NativeScript/ios/issues/234)) ([dc3c76f](https://github.com/NativeScript/ios/commit/dc3c76f1ff74bcd5b800df55210855871bb70563))



## [8.6.3](https://github.com/NativeScript/ios/compare/v8.6.2...v8.6.3) (2023-11-08)


### Bug Fixes

* prevent crashes during isolate disposal ([3d70c11](https://github.com/NativeScript/ios/commit/3d70c110e1429a1d62c9b9e23020cf7044635511))



## [8.6.2](https://github.com/NativeScript/ios/compare/v8.6.1...v8.6.2) (2023-11-01)


### Bug Fixes

* only reset timer persistent if Isolate is valid ([4379583](https://github.com/NativeScript/ios/commit/4379583fc0b2fa3eacde50eb471086f55c1eec18))



## [8.6.0](https://github.com/NativeScript/ios/compare/v8.5.2...v8.6.1) (2023-10-09)


### Bug Fixes

* bridge release adapters ([#224](https://github.com/NativeScript/ios/issues/224)) ([70b1802](https://github.com/NativeScript/ios/commit/70b180202dc0752d01ae5b9249cbaabae65f53cc))
* delay isolate disposal when isolate is in use ([5a6c2ee](https://github.com/NativeScript/ios/commit/5a6c2ee5efa0c557c94ae56da0d3b3a31911d1b8))
* don't suppress timer exceptions ([0c4b819](https://github.com/NativeScript/ios/commit/0c4b819941b0327e572772018298cf9cf181436e))
* fix setInterval not repeating correctly ([022893f](https://github.com/NativeScript/ios/commit/022893f1dcd9a7649db73e9735ff12e9246b3585))
* prevent JS function to native block leak ([#223](https://github.com/NativeScript/ios/issues/223)) ([a6d7332](https://github.com/NativeScript/ios/commit/a6d73323718a1de12c5a9f4865a6abfe06fd6e03))


### Features

* add interop.stringFromCString ([#228](https://github.com/NativeScript/ios/issues/228)) ([185c12d](https://github.com/NativeScript/ios/commit/185c12dc85e86747f266867fb208c71caf5fc6b3))
* add native timers ([#221](https://github.com/NativeScript/ios/issues/221)) ([119470f](https://github.com/NativeScript/ios/commit/119470f249c5aa85c4c2d0b1c9b5b691003c1ec7))
* add timer strong retainer annotation ([efef961](https://github.com/NativeScript/ios/commit/efef961a67519aed881637ac0291894f3325b111))
* log the fullMessage with more details about the error ([#229](https://github.com/NativeScript/ios/issues/229)) ([d67588c](https://github.com/NativeScript/ios/commit/d67588cb3866212ccd86b105edf1207fddde2db9))
* use node logic for globals and modules ([#215](https://github.com/NativeScript/ios/issues/215)) ([a66cc42](https://github.com/NativeScript/ios/commit/a66cc42c768ee7712d1c1f441b8c4e8e88a19eca))



## [8.5.2](https://github.com/NativeScript/ios/compare/v8.5.1...v8.5.2) (2023-05-24)


Expand Down
2 changes: 1 addition & 1 deletion NativeScript/NativeScript-Prefix.pch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#ifndef NativeScript_Prefix_pch
#define NativeScript_Prefix_pch

#define NATIVESCRIPT_VERSION "8.5.2-alpha.3"
#define NATIVESCRIPT_VERSION "8.7.2"

#ifdef DEBUG
#define SIZEOF_OFF_T 8
Expand Down
Loading

0 comments on commit 3220fe1

Please sign in to comment.