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

BHBC-2145, 2087: Occurrence messaging refactoring; Submission message type for mismatched focal species #913

Merged
merged 32 commits into from
Jan 26, 2023

Conversation

curtisupshall
Copy link
Contributor

@curtisupshall curtisupshall commented Jan 13, 2023

Overview

Amends observation submission messaging.

Links to Jira tickets

Description of relevant changes

  • Refactors the way that submission messages are rendered by the SurveyOccurrences component
  • Clean-up around SurveyOccurrences component logic + API queries
  • Fixes a bug that persists a "Failed to get file from S3" submission message
  • Amends messaging related to template species not matching the focal species of a survey

PR Checklist

A list of items that are good to consider when making any changes.

Note: this list is not exhaustive, and not all items are always applicable.

Code

  • New files/classes/functions have appropriately descriptive names and comment blocks to describe their use/behaviour
  • I have avoided duplicating code when possible, moving re-usable pieces into functions
  • I have avoided hard-coding values where possible and moved any re-usable constants to a constants file
  • My code is as flat as possible (avoids deeply nested if/else blocks, promise chains, etc)
  • My code changes account for null/undefined values and handle errors appropriately
  • My code uses types/interfaces to help describe values/parameters/etc, help ensure type safety, and improve readability

Style

  • My code follows the established style conventions
  • My code uses native material-ui components/icons/conventions when possible

Documentation

  • I have commented my code sufficiently, such that an unfamiliar developer could understand my code
  • I have added/updated README's and related documentation, as needed

Tests

  • I have added/updated unit tests for any code I've added/updated
  • I have added/updated the Postman requests/tests to account for any API endpoints I've added/updated

Linting/Formatting

  • I have run the linter and fixed any issues, as needed
    See the lint commands in package.json
  • I have run the formatter and fixed any issues, as needed
    See the format commands in package.json

SonarCloud

  • I have addressed all SonarCloud Bugs, Vulnerabilities, Security Hotspots, and Code Smells

@curtisupshall curtisupshall changed the title BHBC-2145: Occurrences refactoring BHBC-2145: Observations refactoring Jan 16, 2023
@curtisupshall curtisupshall marked this pull request as ready for review January 23, 2023 17:32
@codecov
Copy link

codecov bot commented Jan 23, 2023

Codecov Report

Merging #913 (0009d8e) into dev (03b793f) will increase coverage by 0.02%.
The diff coverage is 65.77%.

@@            Coverage Diff             @@
##              dev     #913      +/-   ##
==========================================
+ Coverage   65.64%   65.67%   +0.02%     
==========================================
  Files         353      351       -2     
  Lines       11304    11287      -17     
  Branches     1966     1952      -14     
==========================================
- Hits         7421     7413       -8     
+ Misses       3488     3479       -9     
  Partials      395      395              
Impacted Files Coverage Δ
api/src/queries/queries.ts 100.00% <ø> (ø)
...p/src/features/surveys/view/SurveyObservations.tsx 35.16% <30.00%> (-2.34%) ⬇️
api/src/repositories/validation-repository.ts 71.42% <38.46%> (-12.79%) ⬇️
api/src/paths/xlsx/process.ts 94.59% <83.33%> (-2.38%) ⬇️
app/src/hooks/useInterval.ts 86.95% <84.21%> (+1.24%) ⬆️
...d}/survey/{surveyId}/observation/submission/get.ts 82.75% <88.88%> (+2.27%) ⬆️
api/src/repositories/survey-repository.ts 94.94% <92.00%> (-0.49%) ⬇️
api/src/constants/status.ts 100.00% <100.00%> (ø)
...survey/{surveyId}/observation/submission/upload.ts 98.24% <100.00%> (-0.12%) ⬇️
api/src/services/survey-service.ts 82.08% <100.00%> (+2.25%) ⬆️
... and 1 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@curtisupshall curtisupshall changed the title BHBC-2145: Observations refactoring BHBC-2145, 2087: Occurrence messaging refactoring; Submission message type for mismatched focal species Jan 23, 2023
@curtisupshall curtisupshall added the Do Not Merge PR should not be merged label Jan 23, 2023
@curtisupshall curtisupshall removed the Do Not Merge PR should not be merged label Jan 25, 2023
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.2% 0.2% Duplication

Copy link
Contributor

@KjartanE KjartanE left a comment

Choose a reason for hiding this comment

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

👍

@curtisupshall curtisupshall merged commit c2ddb87 into dev Jan 26, 2023
@curtisupshall curtisupshall deleted the BHBC-2145 branch January 26, 2023 19:25
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