Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@fedemkr
Copy link
Member

@fedemkr fedemkr commented Aug 1, 2024

🎟️ Tracking

PM-9705

📔 Objective

Add device and CI Build info to what is copied in the about version copy action.

⏰ Reminders before review

  • Contributor guidelines followed
  • All formatters and local linters executed and passed
  • Written new unit and / or integration tests where applicable
  • Protected functional changes with optionality (feature flags)
  • Used internationalization (i18n) for all UI strings
  • CI builds passed
  • Communicated to DevOps any deployment requirements
  • Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team

🦮 Reviewer guidelines

  • 👍 (:+1:) or similar for great changes
  • 📝 (:memo:) or ℹ️ (:information_source:) for notes or general info
  • ❓ (:question:) for questions
  • 🤔 (:thinking:) or 💭 (:thought_balloon:) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion
  • 🎨 (:art:) for suggestions / improvements
  • ❌ (:x:) or ⚠️ (:warning:) for more significant problems or concerns needing attention
  • 🌱 (:seedling:) or ♻️ (:recycle:) for future improvements or indications of technical debt
  • ⛏ (:pick:) for minor or nitpick changes

@fedemkr fedemkr marked this pull request as draft August 1, 2024 19:32
@codecov
Copy link

codecov bot commented Aug 1, 2024

Codecov Report

Attention: Patch coverage is 90.00000% with 2 lines in your changes missing coverage. Please review.

Project coverage is 88.42%. Comparing base (bea521e) to head (1c3d32f).

Files Patch % Lines
...tform/Settings/Settings/About/AboutProcessor.swift 89.47% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #782      +/-   ##
==========================================
- Coverage   88.42%   88.42%   -0.01%     
==========================================
  Files         596      596              
  Lines       30069    30086      +17     
==========================================
+ Hits        26590    26605      +15     
- Misses       3479     3481       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@github-actions
Copy link
Contributor

github-actions bot commented Aug 1, 2024

Logo
Checkmarx One – Scan Summary & Details8ce676fc-80c7-4eea-85a7-b7c0a9007dda

No New Or Fixed Issues Found

Copy link
Contributor

@KatherineInCode KatherineInCode left a comment

Choose a reason for hiding this comment

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

I know this is a draft, and it's looking good so far! Just noticed a few things.

let text = state.copyrightText + "\n\n" + state.version
services.pasteboardService.copy(text)
var infoParts = [
state.copyrightText + "\n",
Copy link
Contributor

Choose a reason for hiding this comment

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

🤔 Would it be better instead of doing string concatenation here, to just list the "\n" as another element in the array, since we're doing a bunch of concatenation later with the .joined? That would help make it more clear when reading what the expected output is vis-à-vis blank lines. Same would apply to all the newlines embedded in strings here.

Copy link
Member Author

Choose a reason for hiding this comment

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

Tried it but the problem is that it adds an additional new line:
copyright\n\n\n instead of copyright\n\n
Because it'd be the \n between copyright and the \n element and then another \n between the \n element and version.

Copy link
Contributor

Choose a reason for hiding this comment

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

🤦🏼‍♀️ Right, that makes sense. Could just do a "" on a separate line, instead? But yeah, that's reasonable either way.

services: services,
state: AboutState()
state: AboutState(),
systemDevice: UIDevice.current
Copy link
Contributor

Choose a reason for hiding this comment

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

🤔 There is a HasSystemDevice already on the Services; would it be possible to pass that in here?

Copy link
Member Author

Choose a reason for hiding this comment

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

oh missed that, it's a really good idea thanks!

@fedemkr fedemkr marked this pull request as ready for review August 8, 2024 21:25
@fedemkr fedemkr requested review from a team and KatherineInCode August 8, 2024 21:25
Comment on lines +36 to +39
"Commit hash": "${commit_hash}",
"CI Run ID": "${ci_run_id}",
"CI Run Number": "${ci_run_number}",
"CI Run Attempt": "${ci_run_attempt}",
Copy link
Contributor

Choose a reason for hiding this comment

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

🎨 We should probably be consistent with casing. I think our standard is just uppercasing the first word, so "CI run ID", "CI run number", and "CI run attempt"?

@fedemkr fedemkr merged commit 6f6c1e0 into main Aug 12, 2024
@fedemkr fedemkr deleted the mobiletf/pm-9705/ci-bulid-info-about branch August 12, 2024 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants