SlideShare a Scribd company logo
Super
charging
project
health
check
go beyond the usual
practices
David
Horvath
Lead iOS Developer
@egyes
Swifters meetup
2021 March
digital
agency
┘ Lot of different projects throughout the years


┘ Project handovers


┘ Code audits
issues
┘ Tons of things to check


┘ Lot of different approaches


┘ Require a lot of time (it’s never enough)


┘ Huge projects - Potentially overlooked problems
goals
┘ Find the most crucial issues in the shortest time


┘ Be more efficient in gaining insights


┘ Efficiently identify the changes to the code which provide the most value
useful
when
┘ You have to do a project audit


┘ You join a new project


┘ You just want to get new insights into your current project


┘ You want to refactor or rewrite


∷ You can show these findings to your client/boss/lead
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats(SourceForge)
git reports
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats


┘ Checking project size
cloc
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats


┘ Checking project size


∷ Cloc


┘ Open the project and build it


∷ High-level overview
high-
level
overview
┘ File structure


┘ Naming conventions


┘ Modularization


┘ Dependencies (spm, pod, carthage)


┘ UI (code / xib / storyboards)


┘ Architecture


┘ Compile time


┘ Xcode memory graph
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats


┘ Checking project size


∷ Cloc


┘ Open the project and build it


∷ Highlevel overview


┘ Visualize class dependencies
dependency visualizer
dependency visualizer
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats


┘ Checking project size


∷ Cloc


┘ Open the project and build it


∷ Highlevel overview


┘ Visualize class dependencies


∷ objc-dependency-visualizer


┘ Static code analysis


∷ Cyclomatic complexity


∷ Code duplication
lizard
lizard
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats


┘ Checking project size


∷ Cloc


┘ Visualize class dependencies


∷ objc-dependency-visualizer


┘ Checking cyclomatic complexity


∷ Lizard


┘ Static code analysis


∷ Cyclomatic complexity


∷ Code duplication


∷ Lizard / CPD


┘ Checking dead code
periphery
process
┘ Checking git reports


∷ Interesting details about the project


∷ Gitlab / Github - GitStats


┘ Checking project size


∷ Cloc


┘ Visualize class dependencies


∷ objc-dependency-visualizer


┘ Checking cyclomatic complexity


∷ Lizard


┘ Static code analysis


∷ Cyclomatic complexity


∷ Code duplication


∷ Lizard / CPD


┘ Checking dead code


∷ Periphery
quick
process
summary
┘ We have a lot of information about the project already


∷ High-level overview


∷ Data about the project size and age


∷ List of complexities


∷ List of duplication


∷ Duplication rate


∷ List of unused codes


∷ Nice visualization of the class dependencies


┘ It only took a few hours
so
what’s
new?
problems
┘ We spend so much time looking at the current state of the code
that we forget its history


┘ Its hard to understand large-scale complex systems by looking
at a snapshot of the code


┘ We miss a lot of information
where can
we find
more info?
version
control
systems
┘ We use it to keep track of the project history


┘ Rarely think about the insights we can get by mining data from it


┘ We can learn about the environment


┘ We can learn about how we work


┘ Predict which parts of the code have the most defects


┘ Find the code that matters most for maintenance


┘ Information is real power
git log
code
maat
┘ Command line tool


┘ To mine and analyze data from version control systems


┘ It supports different version control systems


∷ git, svn, perforce, tfs, mercurial


┘ We can use it to detect hotspots


┘ We can use it to detect architectural problems


┘ And so much more
generate maat readable log
summary
Hotspots
┘ Hotspots are your guide to improvements and
refactorings


┘ Research has shown that frequent changes to complex
code generally indicate declining quality


┘ Over time our development focus shifts so the hotspots
will also shift


┘ Hotspots can predict defects very well


┘ We can find them at the intersection of complexity and
effort
revisions (changes)
cloc --by-file
cloc --by-file
merge them for hotspots
Coupling
┘ We can detect which files are changing together most
of the time


┘ Detect architectural / design issues


┘ Explicit coupling


∷ What tend to change together (screen + vm)


┘ Temporal coupling


∷ This is what we are looking for


∷ Can be false positives (service + test)


∷ Can be serious design problem


∷ Can be copy-paste
sum of coupling
coupling by files
false positives
true problems
path transformation
transformed coupling info
transformed coupling info
other
features
┘ Complexity trends


∷ Evaluate growth patterns


∷ Analyze complexity trends


┘ Discover organizational metrics


∷ Social problems


∷ Evaluate communication costs


∷ Build knowledge map


∷ Visualize knowledge loss


┘ Code chur


∷ Predict defects


∷ Discover process loss from code
process
summary
┘ High-level overview of the codebase


┘ List of complexities


┘ List of duplications


┘ List of unused codes


┘ List of hotspots


┘ List of problematic dependencies
goals
┘ ✅ Find the most crucial issues in the shortest time


┘ ✅ Be more efficient in gaining insights


┘ ✅ Efficiently identify the changes to the code which provide the most
value
suggesti
ons
┘ Run these analyses every few months


┘ Can be part of CI/CD release process


┘ Talk the findings through with your team


┘ Read Adam Tornhill’s book to learn more:


Your Code as a Crime Scene
sum up
┘ With the right tools you can quickly and efficiently spot
problems


┘ You can use your version control systems to have more
information about your project


┘ By mining data from it, you can get a deeper
understanding of your design / architectural problems


┘ With the right data you can back your refactoring/
rewrite proposals


┘ Focusing on the right things early you can save a lot of
maintenance cost
thank
you
for your
attention
David
Horvath
Lead iOS Developer
@egyes
tools
┘ GitStats


∷ http://gitstats.sourceforge.net


┘ Cloc


∷ https://github.com/AlDanial/cloc


┘ Lizard


∷ https://github.com/terryyin/lizard


┘ Periphery


∷ https://github.com/peripheryapp/periphery


┘ Objc-dependency-visualizer


∷ https://github.com/PaulTaykalo/objc-dependency-visualizer


┘ Swift-dependency-visualizer


∷ https://github.com/PrzemyslawCholewaDev/swift-dependency-
visualizer


┘ Code maat


∷ https://github.com/adamtornhill/code-maat

More Related Content

What's hot

IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...
IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...
IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...
Bartosz Chrabski
 
GlobalLink NEXT 2017 US - TransPort (Chicago)
GlobalLink NEXT 2017 US - TransPort (Chicago)GlobalLink NEXT 2017 US - TransPort (Chicago)
GlobalLink NEXT 2017 US - TransPort (Chicago)
jwcampbe
 
Reproducibility with Checkpoint & RRO
Reproducibility with Checkpoint & RROReproducibility with Checkpoint & RRO
Reproducibility with Checkpoint & RRO
Work-Bench
 
Roslyn on GitHub
Roslyn on GitHubRoslyn on GitHub
Roslyn on GitHub
Immo Landwerth
 
[2020 git lab commit] continuous infrastructure
[2020 git lab commit] continuous infrastructure[2020 git lab commit] continuous infrastructure
[2020 git lab commit] continuous infrastructure
Rodrigo Stefani Domingues
 
Docs or it didn’t happen
Docs or it didn’t happenDocs or it didn’t happen
Docs or it didn’t happen
All Things Open
 
Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...
Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...
Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...
Work-Bench
 
Magento, beginning to end
Magento, beginning to endMagento, beginning to end
Magento, beginning to end
Jacques Bodin-Hullin
 
Git strategies for DevOps
Git strategies for DevOpsGit strategies for DevOps
Git strategies for DevOps
Ahmad Iqbal Ali
 
Analyzing Packages in Docker images hosted On DockerHub
Analyzing Packages in Docker images hosted On DockerHubAnalyzing Packages in Docker images hosted On DockerHub
Analyzing Packages in Docker images hosted On DockerHub
Ahmed Zerouali
 
Preventing Supply Chain Attacks on Open Source Software
Preventing Supply Chain Attacks on Open Source SoftwarePreventing Supply Chain Attacks on Open Source Software
Preventing Supply Chain Attacks on Open Source Software
All Things Open
 
Where refactoring meets big $$$
Where refactoring meets big $$$Where refactoring meets big $$$
Where refactoring meets big $$$
Michał Gruca
 
2017 Q1 Open Source Support Briefing
2017 Q1 Open Source Support Briefing2017 Q1 Open Source Support Briefing
2017 Q1 Open Source Support Briefing
Benito Gonzalez
 
[India Merge World Tour] Coverity
[India Merge World Tour] Coverity[India Merge World Tour] Coverity
[India Merge World Tour] Coverity
Perforce
 

What's hot (14)

IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...
IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...
IBM Agile Engineering Summit 18: How to Integrate IBM Rational® Team Concert ...
 
GlobalLink NEXT 2017 US - TransPort (Chicago)
GlobalLink NEXT 2017 US - TransPort (Chicago)GlobalLink NEXT 2017 US - TransPort (Chicago)
GlobalLink NEXT 2017 US - TransPort (Chicago)
 
Reproducibility with Checkpoint & RRO
Reproducibility with Checkpoint & RROReproducibility with Checkpoint & RRO
Reproducibility with Checkpoint & RRO
 
Roslyn on GitHub
Roslyn on GitHubRoslyn on GitHub
Roslyn on GitHub
 
[2020 git lab commit] continuous infrastructure
[2020 git lab commit] continuous infrastructure[2020 git lab commit] continuous infrastructure
[2020 git lab commit] continuous infrastructure
 
Docs or it didn’t happen
Docs or it didn’t happenDocs or it didn’t happen
Docs or it didn’t happen
 
Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...
Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...
Nobody Knows What It’s Like To Be the Bad Man: The Development Process for th...
 
Magento, beginning to end
Magento, beginning to endMagento, beginning to end
Magento, beginning to end
 
Git strategies for DevOps
Git strategies for DevOpsGit strategies for DevOps
Git strategies for DevOps
 
Analyzing Packages in Docker images hosted On DockerHub
Analyzing Packages in Docker images hosted On DockerHubAnalyzing Packages in Docker images hosted On DockerHub
Analyzing Packages in Docker images hosted On DockerHub
 
Preventing Supply Chain Attacks on Open Source Software
Preventing Supply Chain Attacks on Open Source SoftwarePreventing Supply Chain Attacks on Open Source Software
Preventing Supply Chain Attacks on Open Source Software
 
Where refactoring meets big $$$
Where refactoring meets big $$$Where refactoring meets big $$$
Where refactoring meets big $$$
 
2017 Q1 Open Source Support Briefing
2017 Q1 Open Source Support Briefing2017 Q1 Open Source Support Briefing
2017 Q1 Open Source Support Briefing
 
[India Merge World Tour] Coverity
[India Merge World Tour] Coverity[India Merge World Tour] Coverity
[India Merge World Tour] Coverity
 

Similar to Supercharging project health check

Git for Data Analyst - Speaker Presentation.pdf
Git for Data Analyst  - Speaker Presentation.pdfGit for Data Analyst  - Speaker Presentation.pdf
Git for Data Analyst - Speaker Presentation.pdf
RicardoCalleja
 
Gerrit Analytics applied to Android source code
Gerrit Analytics applied to Android source codeGerrit Analytics applied to Android source code
Gerrit Analytics applied to Android source code
Luca Milanesio
 
Building a custom cms with django
Building a custom cms with djangoBuilding a custom cms with django
Building a custom cms with django
Yann Malet
 
Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?
Bruno Capuano
 
Lambda Architectures in Practice
Lambda Architectures in PracticeLambda Architectures in Practice
Lambda Architectures in Practice
C4Media
 
Ship code like a keptn
Ship code like a keptnShip code like a keptn
Ship code like a keptn
Rob Jahn
 
Working With People Adl Uni
Working With People Adl UniWorking With People Adl Uni
Working With People Adl Uni
Matthew Landauer
 
Data Engineer's Lunch #68: DevOps Fundamentals
Data Engineer's Lunch #68: DevOps FundamentalsData Engineer's Lunch #68: DevOps Fundamentals
Data Engineer's Lunch #68: DevOps Fundamentals
Anant Corporation
 
Introduction to Go
Introduction to GoIntroduction to Go
Introduction to Go
Simon Hewitt
 
apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...
apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...
apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...
apidays
 
Fifteen Years of DevOps -- LISA 2012 keynote
Fifteen Years of DevOps -- LISA 2012 keynoteFifteen Years of DevOps -- LISA 2012 keynote
Fifteen Years of DevOps -- LISA 2012 keynote
Geoff Halprin
 
Code Management Workshop
Code Management WorkshopCode Management Workshop
Code Management Workshop
Sameh El-Ashry
 
Continuous Delivery: The New Normal. London Event.
Continuous Delivery: The New Normal. London Event. Continuous Delivery: The New Normal. London Event.
Continuous Delivery: The New Normal. London Event.
Perforce
 
Continuous Delivery Pipelines: Metrics, Myths, and Milestones
Continuous Delivery Pipelines:  Metrics, Myths, and MilestonesContinuous Delivery Pipelines:  Metrics, Myths, and Milestones
Continuous Delivery Pipelines: Metrics, Myths, and Milestones
DevOps.com
 
Introduction to Git for developers
Introduction to Git for developersIntroduction to Git for developers
Introduction to Git for developers
Dmitry Guyvoronsky
 
Code Refactoring or Rewrite: How to Properly Dispose of Legacy Code
Code Refactoring or Rewrite: How to Properly Dispose of Legacy CodeCode Refactoring or Rewrite: How to Properly Dispose of Legacy Code
Code Refactoring or Rewrite: How to Properly Dispose of Legacy Code
Roman Labunsky
 
Api gitlab: configurazione dei progetti as a service
Api gitlab: configurazione dei progetti as a serviceApi gitlab: configurazione dei progetti as a service
Api gitlab: configurazione dei progetti as a service
Emerasoft, solutions to collaborate
 
Big feature - small sprint
Big feature - small sprint Big feature - small sprint
Big feature - small sprint
Igor Goldshmidt
 
How to Manage the Risk of your Polyglot Environments
How to Manage the Risk of your Polyglot EnvironmentsHow to Manage the Risk of your Polyglot Environments
How to Manage the Risk of your Polyglot Environments
DevOps.com
 
Source code version control and git
Source code version control and git Source code version control and git
Source code version control and git
Naseer Khan Noor
 

Similar to Supercharging project health check (20)

Git for Data Analyst - Speaker Presentation.pdf
Git for Data Analyst  - Speaker Presentation.pdfGit for Data Analyst  - Speaker Presentation.pdf
Git for Data Analyst - Speaker Presentation.pdf
 
Gerrit Analytics applied to Android source code
Gerrit Analytics applied to Android source codeGerrit Analytics applied to Android source code
Gerrit Analytics applied to Android source code
 
Building a custom cms with django
Building a custom cms with djangoBuilding a custom cms with django
Building a custom cms with django
 
Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?Que nos espera a los ALM Dudes para el 2013?
Que nos espera a los ALM Dudes para el 2013?
 
Lambda Architectures in Practice
Lambda Architectures in PracticeLambda Architectures in Practice
Lambda Architectures in Practice
 
Ship code like a keptn
Ship code like a keptnShip code like a keptn
Ship code like a keptn
 
Working With People Adl Uni
Working With People Adl UniWorking With People Adl Uni
Working With People Adl Uni
 
Data Engineer's Lunch #68: DevOps Fundamentals
Data Engineer's Lunch #68: DevOps FundamentalsData Engineer's Lunch #68: DevOps Fundamentals
Data Engineer's Lunch #68: DevOps Fundamentals
 
Introduction to Go
Introduction to GoIntroduction to Go
Introduction to Go
 
apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...
apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...
apidays LIVE New York - Navigating the Sea of Javascript Tools to Discover Sc...
 
Fifteen Years of DevOps -- LISA 2012 keynote
Fifteen Years of DevOps -- LISA 2012 keynoteFifteen Years of DevOps -- LISA 2012 keynote
Fifteen Years of DevOps -- LISA 2012 keynote
 
Code Management Workshop
Code Management WorkshopCode Management Workshop
Code Management Workshop
 
Continuous Delivery: The New Normal. London Event.
Continuous Delivery: The New Normal. London Event. Continuous Delivery: The New Normal. London Event.
Continuous Delivery: The New Normal. London Event.
 
Continuous Delivery Pipelines: Metrics, Myths, and Milestones
Continuous Delivery Pipelines:  Metrics, Myths, and MilestonesContinuous Delivery Pipelines:  Metrics, Myths, and Milestones
Continuous Delivery Pipelines: Metrics, Myths, and Milestones
 
Introduction to Git for developers
Introduction to Git for developersIntroduction to Git for developers
Introduction to Git for developers
 
Code Refactoring or Rewrite: How to Properly Dispose of Legacy Code
Code Refactoring or Rewrite: How to Properly Dispose of Legacy CodeCode Refactoring or Rewrite: How to Properly Dispose of Legacy Code
Code Refactoring or Rewrite: How to Properly Dispose of Legacy Code
 
Api gitlab: configurazione dei progetti as a service
Api gitlab: configurazione dei progetti as a serviceApi gitlab: configurazione dei progetti as a service
Api gitlab: configurazione dei progetti as a service
 
Big feature - small sprint
Big feature - small sprint Big feature - small sprint
Big feature - small sprint
 
How to Manage the Risk of your Polyglot Environments
How to Manage the Risk of your Polyglot EnvironmentsHow to Manage the Risk of your Polyglot Environments
How to Manage the Risk of your Polyglot Environments
 
Source code version control and git
Source code version control and git Source code version control and git
Source code version control and git
 

Recently uploaded

Public CyberSecurity Awareness Presentation 2024.pptx
Public CyberSecurity Awareness Presentation 2024.pptxPublic CyberSecurity Awareness Presentation 2024.pptx
Public CyberSecurity Awareness Presentation 2024.pptx
marufrahmanstratejm
 
Apps Break Data
Apps Break DataApps Break Data
Apps Break Data
Ivo Velitchkov
 
Introduction of Cybersecurity with OSS at Code Europe 2024
Introduction of Cybersecurity with OSS  at Code Europe 2024Introduction of Cybersecurity with OSS  at Code Europe 2024
Introduction of Cybersecurity with OSS at Code Europe 2024
Hiroshi SHIBATA
 
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
Alex Pruden
 
Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
Zilliz
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
Zilliz
 
5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides
DanBrown980551
 
Y-Combinator seed pitch deck template PP
Y-Combinator seed pitch deck template PPY-Combinator seed pitch deck template PP
Y-Combinator seed pitch deck template PP
c5vrf27qcz
 
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
Edge AI and Vision Alliance
 
[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...
[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...
[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...
Jason Yip
 
The Microsoft 365 Migration Tutorial For Beginner.pptx
The Microsoft 365 Migration Tutorial For Beginner.pptxThe Microsoft 365 Migration Tutorial For Beginner.pptx
The Microsoft 365 Migration Tutorial For Beginner.pptx
operationspcvita
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
innovationoecd
 
Digital Banking in the Cloud: How Citizens Bank Unlocked Their Mainframe
Digital Banking in the Cloud: How Citizens Bank Unlocked Their MainframeDigital Banking in the Cloud: How Citizens Bank Unlocked Their Mainframe
Digital Banking in the Cloud: How Citizens Bank Unlocked Their Mainframe
Precisely
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
MichaelKnudsen27
 
“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...
“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...
“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...
Edge AI and Vision Alliance
 
Your One-Stop Shop for Python Success: Top 10 US Python Development Providers
Your One-Stop Shop for Python Success: Top 10 US Python Development ProvidersYour One-Stop Shop for Python Success: Top 10 US Python Development Providers
Your One-Stop Shop for Python Success: Top 10 US Python Development Providers
akankshawande
 
Biomedical Knowledge Graphs for Data Scientists and Bioinformaticians
Biomedical Knowledge Graphs for Data Scientists and BioinformaticiansBiomedical Knowledge Graphs for Data Scientists and Bioinformaticians
Biomedical Knowledge Graphs for Data Scientists and Bioinformaticians
Neo4j
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
Jakub Marek
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Alpen-Adria-Universität
 
What is an RPA CoE? Session 1 – CoE Vision
What is an RPA CoE?  Session 1 – CoE VisionWhat is an RPA CoE?  Session 1 – CoE Vision
What is an RPA CoE? Session 1 – CoE Vision
DianaGray10
 

Recently uploaded (20)

Public CyberSecurity Awareness Presentation 2024.pptx
Public CyberSecurity Awareness Presentation 2024.pptxPublic CyberSecurity Awareness Presentation 2024.pptx
Public CyberSecurity Awareness Presentation 2024.pptx
 
Apps Break Data
Apps Break DataApps Break Data
Apps Break Data
 
Introduction of Cybersecurity with OSS at Code Europe 2024
Introduction of Cybersecurity with OSS  at Code Europe 2024Introduction of Cybersecurity with OSS  at Code Europe 2024
Introduction of Cybersecurity with OSS at Code Europe 2024
 
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
zkStudyClub - LatticeFold: A Lattice-based Folding Scheme and its Application...
 
Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
 
5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides5th LF Energy Power Grid Model Meet-up Slides
5th LF Energy Power Grid Model Meet-up Slides
 
Y-Combinator seed pitch deck template PP
Y-Combinator seed pitch deck template PPY-Combinator seed pitch deck template PP
Y-Combinator seed pitch deck template PP
 
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
“Temporal Event Neural Networks: A More Efficient Alternative to the Transfor...
 
[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...
[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...
[OReilly Superstream] Occupy the Space: A grassroots guide to engineering (an...
 
The Microsoft 365 Migration Tutorial For Beginner.pptx
The Microsoft 365 Migration Tutorial For Beginner.pptxThe Microsoft 365 Migration Tutorial For Beginner.pptx
The Microsoft 365 Migration Tutorial For Beginner.pptx
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
 
Digital Banking in the Cloud: How Citizens Bank Unlocked Their Mainframe
Digital Banking in the Cloud: How Citizens Bank Unlocked Their MainframeDigital Banking in the Cloud: How Citizens Bank Unlocked Their Mainframe
Digital Banking in the Cloud: How Citizens Bank Unlocked Their Mainframe
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
 
“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...
“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...
“How Axelera AI Uses Digital Compute-in-memory to Deliver Fast and Energy-eff...
 
Your One-Stop Shop for Python Success: Top 10 US Python Development Providers
Your One-Stop Shop for Python Success: Top 10 US Python Development ProvidersYour One-Stop Shop for Python Success: Top 10 US Python Development Providers
Your One-Stop Shop for Python Success: Top 10 US Python Development Providers
 
Biomedical Knowledge Graphs for Data Scientists and Bioinformaticians
Biomedical Knowledge Graphs for Data Scientists and BioinformaticiansBiomedical Knowledge Graphs for Data Scientists and Bioinformaticians
Biomedical Knowledge Graphs for Data Scientists and Bioinformaticians
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
 
What is an RPA CoE? Session 1 – CoE Vision
What is an RPA CoE?  Session 1 – CoE VisionWhat is an RPA CoE?  Session 1 – CoE Vision
What is an RPA CoE? Session 1 – CoE Vision
 

Supercharging project health check

  • 1. Super charging project health check go beyond the usual practices David Horvath Lead iOS Developer @egyes Swifters meetup 2021 March
  • 2. digital agency ┘ Lot of different projects throughout the years ┘ Project handovers ┘ Code audits
  • 3. issues ┘ Tons of things to check ┘ Lot of different approaches ┘ Require a lot of time (it’s never enough) ┘ Huge projects - Potentially overlooked problems
  • 4. goals ┘ Find the most crucial issues in the shortest time ┘ Be more efficient in gaining insights ┘ Efficiently identify the changes to the code which provide the most value
  • 5. useful when ┘ You have to do a project audit ┘ You join a new project ┘ You just want to get new insights into your current project ┘ You want to refactor or rewrite ∷ You can show these findings to your client/boss/lead
  • 6. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats(SourceForge)
  • 8. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats ┘ Checking project size
  • 10. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats ┘ Checking project size ∷ Cloc ┘ Open the project and build it ∷ High-level overview
  • 11. high- level overview ┘ File structure ┘ Naming conventions ┘ Modularization ┘ Dependencies (spm, pod, carthage) ┘ UI (code / xib / storyboards) ┘ Architecture ┘ Compile time ┘ Xcode memory graph
  • 12. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats ┘ Checking project size ∷ Cloc ┘ Open the project and build it ∷ Highlevel overview ┘ Visualize class dependencies
  • 15. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats ┘ Checking project size ∷ Cloc ┘ Open the project and build it ∷ Highlevel overview ┘ Visualize class dependencies ∷ objc-dependency-visualizer ┘ Static code analysis ∷ Cyclomatic complexity ∷ Code duplication
  • 18. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats ┘ Checking project size ∷ Cloc ┘ Visualize class dependencies ∷ objc-dependency-visualizer ┘ Checking cyclomatic complexity ∷ Lizard ┘ Static code analysis ∷ Cyclomatic complexity ∷ Code duplication ∷ Lizard / CPD ┘ Checking dead code
  • 20. process ┘ Checking git reports ∷ Interesting details about the project ∷ Gitlab / Github - GitStats ┘ Checking project size ∷ Cloc ┘ Visualize class dependencies ∷ objc-dependency-visualizer ┘ Checking cyclomatic complexity ∷ Lizard ┘ Static code analysis ∷ Cyclomatic complexity ∷ Code duplication ∷ Lizard / CPD ┘ Checking dead code ∷ Periphery
  • 21. quick process summary ┘ We have a lot of information about the project already ∷ High-level overview ∷ Data about the project size and age ∷ List of complexities ∷ List of duplication ∷ Duplication rate ∷ List of unused codes ∷ Nice visualization of the class dependencies ┘ It only took a few hours
  • 23. problems ┘ We spend so much time looking at the current state of the code that we forget its history ┘ Its hard to understand large-scale complex systems by looking at a snapshot of the code ┘ We miss a lot of information
  • 25. version control systems ┘ We use it to keep track of the project history ┘ Rarely think about the insights we can get by mining data from it ┘ We can learn about the environment ┘ We can learn about how we work ┘ Predict which parts of the code have the most defects ┘ Find the code that matters most for maintenance ┘ Information is real power
  • 27. code maat ┘ Command line tool ┘ To mine and analyze data from version control systems ┘ It supports different version control systems ∷ git, svn, perforce, tfs, mercurial ┘ We can use it to detect hotspots ┘ We can use it to detect architectural problems ┘ And so much more
  • 30. Hotspots ┘ Hotspots are your guide to improvements and refactorings ┘ Research has shown that frequent changes to complex code generally indicate declining quality ┘ Over time our development focus shifts so the hotspots will also shift ┘ Hotspots can predict defects very well ┘ We can find them at the intersection of complexity and effort
  • 34. merge them for hotspots
  • 35.
  • 36.
  • 37. Coupling ┘ We can detect which files are changing together most of the time ┘ Detect architectural / design issues ┘ Explicit coupling ∷ What tend to change together (screen + vm) ┘ Temporal coupling ∷ This is what we are looking for ∷ Can be false positives (service + test) ∷ Can be serious design problem ∷ Can be copy-paste
  • 45. other features ┘ Complexity trends ∷ Evaluate growth patterns ∷ Analyze complexity trends ┘ Discover organizational metrics ∷ Social problems ∷ Evaluate communication costs ∷ Build knowledge map ∷ Visualize knowledge loss ┘ Code chur ∷ Predict defects ∷ Discover process loss from code
  • 46. process summary ┘ High-level overview of the codebase ┘ List of complexities ┘ List of duplications ┘ List of unused codes ┘ List of hotspots ┘ List of problematic dependencies
  • 47. goals ┘ ✅ Find the most crucial issues in the shortest time ┘ ✅ Be more efficient in gaining insights ┘ ✅ Efficiently identify the changes to the code which provide the most value
  • 48. suggesti ons ┘ Run these analyses every few months ┘ Can be part of CI/CD release process ┘ Talk the findings through with your team ┘ Read Adam Tornhill’s book to learn more: Your Code as a Crime Scene
  • 49. sum up ┘ With the right tools you can quickly and efficiently spot problems ┘ You can use your version control systems to have more information about your project ┘ By mining data from it, you can get a deeper understanding of your design / architectural problems ┘ With the right data you can back your refactoring/ rewrite proposals ┘ Focusing on the right things early you can save a lot of maintenance cost
  • 51. tools ┘ GitStats ∷ http://gitstats.sourceforge.net ┘ Cloc ∷ https://github.com/AlDanial/cloc ┘ Lizard ∷ https://github.com/terryyin/lizard ┘ Periphery ∷ https://github.com/peripheryapp/periphery ┘ Objc-dependency-visualizer ∷ https://github.com/PaulTaykalo/objc-dependency-visualizer ┘ Swift-dependency-visualizer ∷ https://github.com/PrzemyslawCholewaDev/swift-dependency- visualizer ┘ Code maat ∷ https://github.com/adamtornhill/code-maat