Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QA-1212] Fix chromecast #8323

Merged
merged 2 commits into from
May 3, 2024
Merged

[QA-1212] Fix chromecast #8323

merged 2 commits into from
May 3, 2024

Conversation

raymondjacobson
Copy link
Member

Description

3 bugs!

  1. useChromecast was never called anywhere. Probably broken for a while.
  2. iOS cast was broken because of this bug v4.8.0 of Google's SDK breaks iOS cast button react-native-google-cast/react-native-google-cast#510 hence the addition of patch-package changes. I tried a few things and found this to be the most straightforward
  3. We never muted TrackPlayer when chromecast played, which was a very very jarring experience

I also tried to get iOS audio controls to work, including trying a new volume package, but it didn't work. I think the permissions may be different than what we provide and/or we may need a different cast version and it's probably not worth the investment now...!

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide repro instructions & any configuration.

  • Play/pause
  • Next/prev
  • Disconnect
  • Reconnect
  • Switch cast devices
  • Lockscreen controls

Copy link

changeset-bot bot commented May 3, 2024

⚠️ No Changeset found

Latest commit: b76a313

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@audius/sdk@3.0.11-beta.21 Transitive: environment, filesystem, network +59 106 MB audius-project
npm/@babel/runtime@7.24.5 None 0 262 kB nicolo-ribaudo
npm/@cloudflare/workers-types@3.16.0 None 0 65 kB threepointone
npm/@coral-xyz/anchor@0.28.0 environment, filesystem, network 0 1.7 MB acheroncrypto
npm/@coral-xyz/borsh@0.28.0 None 0 22.2 kB acheroncrypto
npm/@noble/curves@1.4.0 None 0 1.39 MB paulmillr
npm/@noble/hashes@1.4.0 None 0 773 kB paulmillr
npm/@npmcli/fs@3.1.0 filesystem 0 26.5 kB lukekarrys
npm/@pkgjs/parseargs@0.11.0 None 0 74.2 kB oss-bot
npm/@solana-mobile/dapp-store-cli@0.8.2 Transitive: environment, eval, filesystem, network, shell, unsafe +497 109 MB ankur2136
npm/@solana/spl-token@0.3.8 None 0 1.32 MB joncinque
npm/@solana/web3.js@1.78.4 environment, eval, network 0 13.7 MB steveluscher
npm/@tanstack/react-query@4.10.3 Transitive: environment +1 3.33 MB tannerlinsley
npm/@types/bn.js@5.1.0 None 0 13.9 kB types
npm/@types/chai@4.3.0 None 0 79.9 kB types
npm/@types/connect@3.4.38 None 0 5.91 kB types
npm/@types/json5@0.0.29 None 0 3 kB types
npm/@types/mocha@9.0.0 None 0 95.3 kB types
npm/@types/node@20.12.8 None 0 2.06 MB types
npm/@ungap/promise-all-settled@1.1.2 None 0 4.88 kB webreflection
npm/abbrev@2.0.0 None 0 4.83 kB lukekarrys
npm/agent-base@7.1.0 network 0 23.5 kB tootallnate
npm/agentkeepalive@4.5.0 network 0 43.7 kB fengmk2
npm/aggregate-error@3.1.0 None 0 6.69 kB sindresorhus
npm/ansi-colors@4.1.1 environment 0 24.4 kB jonschlinkert
npm/arrify@1.0.1 None 0 2.34 kB sindresorhus
npm/assertion-error@1.1.0 None 0 5.64 kB chaijs
npm/bignumber.js@9.1.2 None 0 351 kB mikemcl
npm/browser-stdout@1.3.1 None 0 2.3 kB kumavis
npm/buffer-from@1.1.2 None 0 5.05 kB linusu
npm/buffer-layout@1.2.2 None 0 213 kB pabigot
npm/bufferutil@4.0.8 None 0 414 kB lpinca
npm/cacache@18.0.1 filesystem Transitive: environment +4 1.65 MB npm-cli-ops
npm/chai@4.3.4 None 0 744 kB chai
npm/check-error@1.0.3 None 0 14.4 kB keithamus
npm/chokidar@3.5.2 environment, filesystem 0 89.8 kB paulmillr
npm/chownr@2.0.0 filesystem 0 5.75 kB isaacs
npm/clean-stack@2.2.0 None 0 5.51 kB sindresorhus
npm/cliui@7.0.4 None 0 30.6 kB oss-bot
npm/cross-fetch@3.1.8 network 0 75.1 kB lquixada
npm/cross-spawn@7.0.3 environment, filesystem, shell 0 21.2 kB satazor
npm/crypto-hash@1.3.0 None 0 9.42 kB sindresorhus
npm/debug@4.3.1 environment 0 41.1 kB qix
npm/decamelize@4.0.0 None 0 4 kB sindresorhus
npm/deep-eql@3.0.1 None 0 54 kB chaijs
npm/diff@5.0.0 None 0 369 kB kpdecker
npm/dot-case@3.0.4 None 0 10.5 kB blakeembrey
npm/encoding@0.1.13 None 0 7.12 kB andris
npm/env-paths@2.2.1 None 0 10.2 kB sindresorhus
npm/err-code@2.0.3 None 0 12.3 kB achingbrain
npm/escalade@3.1.2 filesystem 0 11.6 kB lukeed
npm/escape-string-regexp@4.0.0 None 0 3.79 kB sindresorhus
npm/exponential-backoff@3.1.1 None 0 37.3 kB sssayegh
npm/flat@5.0.2 None 0 26.6 kB timoxley
npm/foreground-child@3.1.1 shell 0 60.4 kB isaacs
npm/fs-minipass@3.0.3 filesystem 0 14.4 kB npm-cli-ops
npm/get-caller-file@2.0.5 None 0 4.72 kB stefanpenner
npm/get-func-name@2.0.2 None 0 8.68 kB keithamus
npm/glob@7.1.7 filesystem 0 55.9 kB isaacs
npm/graceful-fs@4.2.11 environment, filesystem 0 32.5 kB isaacs
npm/growl@1.10.5 environment, filesystem, shell 0 59.3 kB deiga
npm/he@1.2.0 None 0 124 kB mathias
npm/http-proxy-agent@7.0.0 network 0 24.3 kB tootallnate
npm/https-proxy-agent@7.0.2 network 0 35.1 kB tootallnate
npm/humanize-ms@1.2.1 None 0 3.66 kB dead_horse
npm/iconv-lite@0.6.3 None 0 349 kB ashtuchkin
npm/indent-string@4.0.0 None 0 4.4 kB sindresorhus
npm/ip@2.0.0 None 0 13.6 kB indutny
npm/is-lambda@1.0.1 None 0 2.94 kB watson
npm/is-plain-obj@2.1.0 None 0 3.69 kB sindresorhus
npm/isexe@2.0.0 environment, filesystem 0 11 kB isaacs
npm/jackspeak@2.3.6 environment 0 253 kB isaacs
npm/jayson@4.1.0 network 0 162 kB tedeh
npm/lower-case@2.0.2 None 0 17.7 kB blakeembrey
npm/make-error@1.3.6 None 0 12.4 kB julien-f
npm/make-fetch-happen@13.0.0 network 0 52.5 kB npm-cli-ops
npm/minimatch@3.0.4 None 0 33.1 kB isaacs
npm/minipass-collect@2.0.1 None 0 4.96 kB isaacs
npm/minipass-fetch@3.0.4 environment, network 0 46.8 kB npm-cli-ops
npm/minipass-flush@1.0.5 None +1 51.9 kB isaacs
npm/minipass-pipeline@1.2.4 None 0 7 kB isaacs
npm/minipass-sized@1.0.3 None 0 124 kB isaacs
npm/minipass@7.0.4 None 0 285 kB isaacs
npm/minizlib@2.1.2 None 0 17.3 kB isaacs
npm/mkdirp@1.0.4 environment, filesystem 0 19.1 kB isaacs
npm/mocha@9.0.3 environment, eval, filesystem 0 3.75 MB juergba
npm/nanoid@3.1.23 None 0 52.7 kB ai
npm/negotiator@0.6.3 None 0 27.4 kB dougwilson
npm/no-case@3.0.4 None 0 25.1 kB blakeembrey
npm/node-gyp-build@4.6.0 environment, filesystem 0 13.1 kB mafintosh
npm/node-gyp@10.0.1 environment, shell Transitive: filesystem +2 1.77 MB lukekarrys
npm/nopt@7.2.0 None 0 26.1 kB npm-cli-ops
npm/p-limit@3.1.0 None 0 7.75 kB sindresorhus
npm/p-map@4.0.0 None 0 8.69 kB sindresorhus
npm/pako@2.1.0 None 0 1.64 MB vitaly
npm/path-exists@4.0.0 filesystem 0 3.92 kB sindresorhus
npm/path-key@3.1.1 None 0 4.55 kB sindresorhus
npm/path-scurry@1.10.2 filesystem 0 533 kB isaacs
npm/pathval@1.1.1 None 0 15.8 kB chai
npm/prettier@2.6.2 environment, filesystem, unsafe 0 17.7 MB sosukesuzuki
npm/proc-log@3.0.0 None 0 5.21 kB lukekarrys
npm/promise-retry@2.0.1 None 0 15.6 kB achingbrain
npm/require-directory@2.1.1 filesystem 0 12.1 kB troygoode
npm/retry@0.12.0 None 0 32.2 kB tim-kos
npm/rpc-websockets@7.10.0 Transitive: environment, network +1 5.58 MB mkozjak
npm/serialize-javascript@6.0.0 None 0 16.8 kB okuryu
npm/shebang-command@2.0.0 None 0 2.56 kB kevva
npm/shebang-regex@3.0.0 None 0 2.83 kB sindresorhus
npm/signal-exit@4.1.0 None 0 77 kB isaacs
npm/snake-case@3.0.4 None 0 10.4 kB blakeembrey
npm/socks-proxy-agent@8.0.2 network 0 24.1 kB tootallnate
npm/source-map-support@0.5.21 filesystem 0 85.2 kB linusu
npm/ssri@10.0.5 None 0 38.7 kB npm-cli-ops
npm/strip-bom@3.0.0 None 0 3 kB sindresorhus
npm/strip-json-comments@3.1.1 None 0 6.96 kB sindresorhus
npm/tar@6.2.1 environment, filesystem +2 250 kB isaacs
npm/toml@3.0.0 None 0 144 kB binarymuse
npm/ts-node@7.0.1 environment, filesystem +2 761 kB blakeembrey
npm/tsconfig-paths@3.14.2 environment, filesystem, unsafe 0 203 kB jonaskello
npm/type-detect@4.0.8 None 0 42.1 kB chaijs
npm/typescript@4.3.5 None 0 60.7 MB typescript-bot
npm/unique-filename@3.0.0 None 0 3.41 kB lukekarrys
npm/unique-slug@4.0.0 None 0 2.58 kB lukekarrys
npm/which@2.0.2 environment 0 9.97 kB isaacs
npm/y18n@5.0.8 filesystem 0 23.4 kB oss-bot
npm/yargs-parser@20.2.4 environment, filesystem 0 120 kB oss-bot
npm/yargs@16.2.0 environment, filesystem 0 286 kB oss-bot
npm/yn@2.0.0 None 0 4.99 kB sindresorhus
npm/yocto-queue@0.1.0 None 0 6.03 kB sindresorhus

🚮 Removed packages: npm/@amplitude/node@1.9.2, npm/@amplitude/react-native@2.17.2, npm/@apollo/client@3.3.7, npm/@babel/cli@7.7.0, npm/@babel/plugin-proposal-class-static-block@7.21.0, npm/@babel/plugin-transform-react-jsx@7.21.0, npm/@babel/plugin-transform-runtime@7.18.2, npm/@babel/preset-env@7.22.15, npm/@babel/preset-typescript@7.22.15, npm/@babel/register@7.7.0, npm/@changesets/cli@2.27.1, npm/@cloudflare/kv-asset-handler@0.3.1, npm/@coinbase/cbpay-js@1.2.0, npm/@coinflowlabs/react-native@2.1.5, npm/@coinflowlabs/react@3.1.5, npm/@coral-xyz/anchor@0.29.0, npm/@elastic/elasticsearch@8.1.0, npm/@emotion/babel-preset-css-prop@11.11.0, npm/@emotion/css@11.11.2, npm/@emotion/eslint-plugin@11.11.0, npm/@emotion/native@11.11.0, npm/@emotion/react@11.11.1, npm/@emotion/server@11.11.0, npm/@emotion/styled@11.11.0, npm/@esbuild-plugins/node-globals-polyfill@0.2.3, npm/@escape.tech/mookme@2.4.1, npm/@fingerprintjs/fingerprintjs-pro@3.5.6, npm/@google/model-viewer@3.3.0, npm/@gorhom/portal@1.0.9, npm/@hcaptcha/react-hcaptcha@0.3.6, npm/nodemon@2.0.19, npm/prom-client@14.0.1, npm/web3@1.7.5

View full report↗︎

Copy link

🚨 Potential security issues detected. Learn more about Socket for GitHub ↗︎

To accept the risk, merge this PR and you will not be notified again.

Alert Package NoteSource
Install scripts npm/bigint-buffer@1.1.5
  • Install script: install
  • Source: npm run rebuild || echo "Couldn't build bindings. Non-native version used."
Critical CVE npm/crypto-js@3.3.0
Critical CVE npm/@babel/traverse@7.22.20
  • orphan: npm/@babel/traverse@7.22.20
Git dependency npm/arbundles@0.6.22

View full report↗︎

Next steps

What is an install script?

Install scripts are run when the package is installed. The majority of malware in npm is hidden in install scripts.

Packages should not be running non-essential scripts during install and there are often solutions to problems people solve with install scripts that can be run at publish time instead.

What is a critical CVE?

Contains a Critical Common Vulnerability and Exposure (CVE).

Remove or replace dependencies that include known critical CVEs. Consumers can use dependency overrides or npm audit fix --force to remove vulnerable dependencies.

What are git dependencies?

Contains a dependency which resolves to a remote git URL. Dependencies fetched from git URLs are not immutable can be used to inject untrusted code or reduce the likelihood of a reproducible install.

Publish the git dependency to npm or a private package repository and consume it from there.

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of ecosystem/package-name@version specifiers. e.g. @SocketSecurity ignore npm/foo@1.0.0 or ignore all packages with @SocketSecurity ignore-all

  • @SocketSecurity ignore npm/bigint-buffer@1.1.5
  • @SocketSecurity ignore npm/crypto-js@3.3.0
  • @SocketSecurity ignore npm/@babel/traverse@7.22.20
  • @SocketSecurity ignore npm/arbundles@0.6.22

@audius-infra
Copy link
Collaborator

It looks like there may be some changes to native mobile code, which requires triggering a full app release. Please follow the instructions here: https://www.notion.so/audiusproject/When-to-bump-app-version-2644a8f772364a4d91f44abcba44ce0b?pvs=4. cc @nicoback2 @sliptype

Comment on lines +145 to +147
TrackPlayer.setVolume(0)
} else {
TrackPlayer.setVolume(1)
Copy link
Contributor

Choose a reason for hiding this comment

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

do the volume controls control the device you're casting to?

Copy link
Member Author

Choose a reason for hiding this comment

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

they do on android, but don't on iOS (see PR description).
this setVolume controls the phone though, and the way chromecast works, both the phone and the cast device are playing the track at the same time. it doesn't have to be that way, but would mean we have to rewrite a lot of the player control logic

Copy link
Contributor

@DejayJD DejayJD left a comment

Choose a reason for hiding this comment

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

Nice! LGTM. Agreed on the waiting for iPhone volume casting, seems fairly minor

@raymondjacobson raymondjacobson enabled auto-merge (squash) May 3, 2024 02:06
@raymondjacobson raymondjacobson merged commit 146b2e0 into main May 3, 2024
17 of 20 checks passed
@raymondjacobson raymondjacobson deleted the rj-qa-1212 branch May 3, 2024 02:21
audius-infra pushed a commit that referenced this pull request May 4, 2024
[9f44712] Reapply "Convert swagger.json to OAS 3.0 before generating SDK types (#8274)" (#8324) (#8344) Marcus Pasell
[2ea74f3] Fix issues with text-link variant (#8343) Dylan Jeffers
[f005b25] [PAY-2860] SDK Services Config - Configure SDK using environment (#8329) Marcus Pasell
[11a0813] Disable add to playlist for prem tracks if not purchased (#8336) Reed
[33b1916] [C-4335] Migrate all user and collection cards (#8338) Dylan Jeffers
[dafaa21] [QA-1241] Fix hidden track add to playlist allowing non hidden items (#8340) JD Francis
[4c95031] [QA-956] Add deleted tile for tracks/albums/playlists (#8333) JD Francis
[b8f5990] Add error message to upload flow (#8334) JD Francis
[22894e8] [QA-957] Fix android overflowing text on access & sale modal (#8313) JD Francis
[86f6447] [PAY-2812] Change spend to earn challenge copy (#8332) Reed
[d4c4264] Close modal on done (#8331) Saliou Diallo
[ded4933] [PAY-2861] CollectionCard fixes (#8330) Dylan Jeffers
[36277cd] Revert "Convert swagger.json to OAS 3.0 before generating SDK types (#8274)" (#8324) Marcus Pasell
[146b2e0] [QA-1212] Fix chromecast (#8323) Raymond Jacobson
[0b33e68] [PAY-2738] Public album with prem track always shows buy button (#8321) Reed
[d897a98] [C-4333] Migrate follow-users to new sign-up flow (#8312) Dylan Jeffers
[3129a3a] [PAY-2799] Show preview button for collections (#8271) Reed
[8c58601] Modify /etc/hosts on CI machines before api test (#8319) Danny
[3586f41] [PAY-2859] Fix bugs in edit app flow (#8320) Raymond Jacobson
[1bf3e97] [PAY-2801] Purchased selectable filter in library albums (#8318) Reed
[6db35c6] [C-4285] Add claim all rewards button functionality (#8292) Saliou Diallo
[a20d85a] [PAY-2728] Implement edit app flow (#8256) Raymond Jacobson
[714a3d1] [C-4288] Migrate to new cards in profile, search, and library (#8300) Dylan Jeffers
[4dceb61] Upgrade dapp-store to 0.8.1 (#8311) Dylan Jeffers
[4d37233] [PAY-2794] Use UserLink for purchases/sales tables (#8306) Reed
[fc2aef3] [PAY-2772] Fix collection description text size (#8309) Reed
[c35bfe1] [PAY-2822] Convert LockedContentDetailsTile to Harmony (#8308) Reed
[f7a921e] [PAY-2781] Poll for track access on album purchase (#8296) Reed
[621c3ee] Convert swagger.json to OAS 3.0 before generating SDK types (#8274) Marcus Pasell
[09789c1] Retrigger logic for android notification permissions post-manifest fix (#8305) JD Francis
[b9c042a] [PAY-2815] Show unlocked icon if dm content is purchased (#8303) Andrew Mendelsohn
[722e933] [PAY-2779] Fix validation for albumTrackPrice (#8302) Andrew Mendelsohn
[963bec4] Fix EditCollection playwright test (#8304) Andrew Mendelsohn
[7e0aa7e] [PAY-2823] Edit Album access control fixes (#8298) Andrew Mendelsohn
[b42b6fd] [QA-971] Fix smart collections (#8299) Raymond Jacobson
[eceb876] [PAY-2791] Show only own albums in artist dashboard (#8297) Reed
[87ce027] [Web] [Harmony] Add accounts managing you modal [C-4295] [C-4292] (#8258) nicoback2
[7a3567c] [C-4238, C-4318] Add ssr small bundle flow for mobile track page (#8293) Kyle Shanks
[c7c3752] [PAY-2800] Fix mobile navigate to album on purchase success (#8295) Reed
[f113a91] [PAY-2802] Auto-favorite tracks in purchased album (#8294) Reed
[d32934f] [C-4284] Fix rewards in mobile web (#8291) Saliou Diallo
[45c4bc6] [PAY-2775] Remove suggested tracks for albums (#8288) Andrew Mendelsohn
[22280c6] [C-4080] Mobile cooldown and claim all (#8263) Isaac Solo
[80cca19] Jail broken test (#8289) Raymond Jacobson
[d7c8e34] [PAY-2766] Analytics events for premium albums (#8262) JD Francis
[c3ee4a8] [PAY-2817] Web collections show reposts, remove artist column (#8272) Reed
[6f8bab6] Fix lint items (#8285) Raymond Jacobson
[e8debc0] [PAY-2703] Redesign mobile collection and track screen tiles (#8255) Andrew Mendelsohn
[a3964a8] Bump android build number for release-client-v1.5.78 (#8286) Raymond Jacobson
[8481f8d] [C-4327] Fix track ordering within playlist/album (#8284) Raymond Jacobson
[5165172] Bump android version for manifest changes (#8283) JD Francis
[4e60f97] [C-4312] Add UserCard (#8276) Dylan Jeffers
[35ed4ec] [ONC-82] Fix android notif permissions (#8279) JD Francis
[82e1c67] [C-4323] Improve Avatar (#8273) Dylan Jeffers
[909db7c] [C-4316, C-4317] SSR work to render webplayer and track page for web (#8268) Kyle Shanks
[7417a40] Generate sdk after ursm code removal (#8275) Raymond Jacobson
[62b5a08] Update Add Funds copy and loading state (#8266) Saliou Diallo
[4503cc7] PROTO-1328: always default to discovery relay (#8247) alecsavvy
[f42c6cd] Fix text-input spacing (#8270) Dylan Jeffers
[75fd847] [C-4270] Fix text-link transition (#8260) Dylan Jeffers
[df0349a] [PAY-2761] Add managed users endpoints (#8238) Randy Schott
[5b4c998] [ONC-84] Add try/catch (#8264) Raymond Jacobson
[2b5f89c] Fix clipped text in TracksTable name column (#8265) Reed
[c3256fa] [C-4275] Add google-inspectiontool to crawler regex (#8261) Sebastian Klingler
[5750045] [C-4033] Prevent useTabs from redirecting on page load (#8259) Sebastian Klingler
[b17ff70] [PAY-2758] Allow gated tracks to be added to playlists (#8227) Reed
@raymondjacobson raymondjacobson mentioned this pull request May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants