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

[20366] For merging auto-stale workflow to default branch #435

Merged
merged 63 commits into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
e709082
[19730] *Update TripGoSharedPreference to make it injectable and not …
MichaelReyes Jan 15, 2024
a6c64b2
[19730] *Add TripGoSharedPreferenceTest.
MichaelReyes Jan 15, 2024
d5d8e07
Merge pull request #407 from skedgo/bugfix/19730-region-selected-focus
MichaelReyes Jan 17, 2024
7ccd3ec
[19947] TripSegmentsViewModel test init
MichaelReyes Jan 23, 2024
b9c2e14
[20391] Handle Lit Route road tag
MichaelReyes Jan 24, 2024
65ea078
Merge pull request #408 from skedgo/bugfix/19947-crowdiness-indicator
MichaelReyes Jan 25, 2024
d33cf63
Merge pull request #409 from skedgo/feautre/20391-handle-lit-route
MichaelReyes Jan 25, 2024
da3acac
[19310] Replaced travis with github action
sg-jsonjuliane Jan 30, 2024
1694200
[19310] Removed travis.yml
sg-jsonjuliane Jan 30, 2024
27d6563
[20464] *Update GeofenceBroadcastReceiver pendingIntent to fix adding…
MichaelReyes Feb 6, 2024
95abb30
Merge pull request #411 from skedgo/bugfix/20464-destination-notifica…
MichaelReyes Feb 7, 2024
2ee8890
[19310] Updated version to 17 to match local properties
sg-jsonjuliane Feb 8, 2024
c75619a
Merge pull request #410 from skedgo/feature/19310-github-action
sg-jsonjuliane Feb 12, 2024
5587731
[20422] Handle availabilityInfo and moneyUSDCost from response and sh…
MichaelReyes Feb 15, 2024
d198235
[19310] Temporarily disabled github action project test
sg-jsonjuliane Feb 15, 2024
f8a1525
Merge pull request #414 from skedgo/feature/19310-github-action
sg-jsonjuliane Feb 15, 2024
7b27bed
Merge branch 'develop' into feature/20422-show-availability-info
MichaelReyes Feb 15, 2024
c8010ce
[PR-REQUEST-FORMAT] Created a format to be followed when creating PR …
sg-jsonjuliane Feb 19, 2024
e106bcc
Merge pull request #413 from skedgo/feature/20422-show-availability-info
MichaelReyes Feb 20, 2024
e702e27
[20495] *Handle warning on payment response if return trip was not bo…
MichaelReyes Feb 8, 2024
c236468
[20495] *DRT handling updates. *staging build type to easily create s…
MichaelReyes Feb 20, 2024
5346a31
[20569] *[TripKitUI] Update ActionButtonHandler to add showTicket tag…
MichaelReyes Feb 28, 2024
2e7574e
[20569] *[TripKitUI] Update ActionButtonHandler to add showTicket tag…
MichaelReyes Feb 28, 2024
2b1ecdd
Merge pull request #412 from skedgo/feature/20495-server-booking-erro…
MichaelReyes Feb 29, 2024
bfc8293
Merge branch 'develop' into feature/20569-qr-code-ticket
MichaelReyes Feb 29, 2024
2252f71
Merge pull request #415 from skedgo/feature/pr-request-format
sg-jsonjuliane Feb 29, 2024
c4c99ff
Merge pull request #416 from skedgo/feature/20569-qr-code-ticket
MichaelReyes Feb 29, 2024
ff252ef
[20604] *[TripGoV5] Handle ActiveBookingItem visibility on user logout.
MichaelReyes Mar 5, 2024
19648ed
Merge pull request #417 from skedgo/bugfix/20604-ticket-retained-on-s…
MichaelReyes Mar 6, 2024
5bc80c1
[20619] *[TripGov5] update DrtFragment and include hasTickets field o…
MichaelReyes Mar 6, 2024
2e01426
Merge pull request #418 from skedgo/bugfix/20619-unable-to-book-drt-w…
MichaelReyes Mar 7, 2024
f6bb6cf
[20424] Guide/Induction screens init
MichaelReyes Mar 11, 2024
336bf61
[20424] - [TripGov5] Fix ActiveBookingItemViewModel visibility and da…
MichaelReyes Mar 12, 2024
5d39271
Merge pull request #419 from skedgo/feautre/20424-user-induction-screens
MichaelReyes Mar 18, 2024
5708d8c
[20877] - [TripKitUI] update CursorToServiceConverter to add bicycleA…
MichaelReyes Mar 26, 2024
2d3bbc4
[20933]
MichaelReyes Apr 2, 2024
8274e5f
Merge pull request #420 from skedgo/feature/20771-bike-accessibility
MichaelReyes Apr 2, 2024
8faebe3
[19972]
MichaelReyes Apr 3, 2024
3337d9a
[20911]
MichaelReyes Apr 5, 2024
8932288
Merge branch 'develop' into bugfix/20933-stripe-payment-flow-fix
MichaelReyes Apr 6, 2024
b68bd5a
Merge pull request #421 from skedgo/bugfix/20933-stripe-payment-flow-fix
MichaelReyes Apr 6, 2024
c233431
[20502] Updated dependencies gradle to add aws amplify cognito
sg-jsonjuliane Apr 10, 2024
c789f4a
[20775]
MichaelReyes Apr 11, 2024
74e2838
Merge pull request #422 from skedgo/feature/20911-facility-marker-han…
MichaelReyes Apr 15, 2024
2c51cce
[20357] Included support for terms and conditions type of mobility
sg-jsonjuliane Apr 15, 2024
b794268
[20606] Created a separate dialog view for terms and conditions
sg-jsonjuliane Apr 16, 2024
6705a5a
Merge pull request #423 from skedgo/feature/20775-handle-school-locat…
MichaelReyes Apr 16, 2024
71e199d
Merge pull request #425 from skedgo/feature/20606-terms-and-conditions
sg-jsonjuliane Apr 17, 2024
ee48098
Merge pull request #424 from skedgo/feature/20502-amplify-cognito
sg-jsonjuliane Apr 22, 2024
642c3e5
[21254]
MichaelReyes Apr 24, 2024
7fa56f3
Merge pull request #426 from skedgo/feature/21254-modeId-merging-for-…
MichaelReyes Apr 26, 2024
19f715c
[19972]
MichaelReyes Apr 26, 2024
6edcefe
[21295]
MichaelReyes Apr 29, 2024
fd836c9
[20606] Revised terms and conditions handling
sg-jsonjuliane Apr 29, 2024
6b454f3
Merge pull request #429 from skedgo/feature/20606-feature-terms-and-c…
MichaelReyes Apr 30, 2024
8b2c284
Merge pull request #427 from skedgo/bugfix/19972-trip-lines-simplify-…
MichaelReyes May 1, 2024
569d5db
[20787]
MichaelReyes May 2, 2024
e69e882
[19921]
MichaelReyes May 7, 2024
4ed8be7
Merge pull request #428 from skedgo/feature/21295-update-scoring-for-…
MichaelReyes May 8, 2024
a49a859
Merge pull request #430 from skedgo/bugfix/20787-fix-schedule-checking
MichaelReyes May 8, 2024
7bc8982
Merge pull request #431 from skedgo/bugfix/19921-lit-routing-issues-fix
MichaelReyes May 13, 2024
38e3008
[20366] Updated Auto Stale PR logic to reflect correct restrictions
sg-jsonjuliane May 13, 2024
b852805
Merge pull request #433 from skedgo/feature/20366-auto-stale-patch
sg-jsonjuliane May 22, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@

# Pull Request (PR) Checklist

Thank you for your contribution! Please confirm that you've checked all the boxes below before submitting your PR. Use `[x]` to check a box, e.g., `[x]`, and make sure there's no space around the brackets.

## PR Context

- **Type**: (Bug Fix / Feature / Refactor / Regression Fix) _Choose one and delete the rest._
- **Issue Link**: [Redmine Issue](https://redmine.buzzhives.com/issues/[XXXXX])
- **Risk Factor**: (Low / Medium / High) - _Provide a brief explanation of the risk._

## Changes

_Describe your changes in detail, highlighting the problem it solves or the feature it adds._

-
-
-

## Checklist for Reviewers

### Documentation and Code Quality
- [ ] **KDocs Documentation**: Are all changes, new functionalities, and classes documented with KDocs?
- [ ] **Architectural Patterns**: Is there consistent and proper use of architectural patterns (e.g., MVVM, MVP)?

### Testing and Reliability
- [ ] **Unit Testing**: Are there unit tests for all new functionalities and classes?
- [ ] **Emulator and Real Device Testing**: Has the application been tested on both emulators and real devices to ensure compatibility?

### Error Handling and Logging
- [ ] **Error Handling**: Are errors and exceptions caught and handled gracefully, ensuring the app remains stable?
- [ ] **Logging**: Is there proper logging in place for critical errors and information, aiding in debugging and monitoring?


## Testing Procedure

_If applicable, provide steps or commands for testing your changes. This can help reviewers and testers._

-
-
-

## Work-in-Progress (WIP)

_List any remaining work or areas that need additional focus. This section can be updated as the work progresses._

- [ ]
- [ ]

_Remember to keep this template updated based on the feedback and evolving project standards._
37 changes: 37 additions & 0 deletions .github/workflows/android_ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Android CI

on:
push:
branches: [ disable-temporarily ]
pull_request:
branches: [ disable-temporarily ]

jobs:
build:
name: Build and Test
runs-on: ubuntu-20.04
steps:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '17'

- name: Grant execute permission for Gradle wrapper
run: chmod +x gradlew

- name: Cache Gradle dependencies
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
~/.android/build-cache
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Run tests
run: ./gradlew test
14 changes: 14 additions & 0 deletions .github/workflows/auto_stale_pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: 'Close stale issues and PRs'
on:
schedule:
- cron: '30 1 * * *'

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
stale-issue-message: 'This issue is stale because it has been open 5 days with no activity. Remove stale label or comment or this will be closed in 2 days.'
days-before-stale: 5
days-before-close: 2
32 changes: 0 additions & 32 deletions .travis.yml

This file was deleted.

4 changes: 4 additions & 0 deletions CommonCoreLegacy/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ android {
release {
consumerProguardFile 'proguard-rules.pro'
}
staging {
debuggable true
}
}

lintOptions {
Expand Down Expand Up @@ -71,6 +74,7 @@ dependencies {
implementation 'com.github.skedgo:commons-collections:v1.0'

debugImplementation project(':TripKitDomain')
stagingImplementation project(':TripKitDomain')
releaseImplementation project(':TripKitDomain')

implementation libs.kotlin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ public class Location implements Parcelable {
*/
public static final int TYPE_W3W = 9;

public static final int TYPE_SCHOOL = 11;

public static final int NO_BEARING = Integer.MAX_VALUE;
public static final double ZERO_LAT = 0.0;
public static final double ZERO_LON = 0.0;
Expand Down Expand Up @@ -114,6 +116,10 @@ public Location createFromParcel(Parcel in) {
List<RouteDetails> routes = new ArrayList<>();
in.readTypedList(routes, RouteDetails.CREATOR);

List<String> modeIdentifiers = new ArrayList<>();
in.readList(modeIdentifiers, String.class.getClassLoader());
location.modeIdentifiers = modeIdentifiers;

return location;
}

Expand Down Expand Up @@ -176,6 +182,8 @@ public Location[] newArray(int size) {
private List<Operator> operators;
private List<RouteDetails> routes;

private List<String> modeIdentifiers;

public Location() {
lat = ZERO_LAT;
lon = ZERO_LON;
Expand Down Expand Up @@ -483,6 +491,14 @@ public void setOperators( List<Operator> operators) {
this.operators = operators;
}

public List<String> getModeIdentifiers() {
return modeIdentifiers;
}

public void setModeIdentifiers(List<String> modeIdentifiers) {
this.modeIdentifiers = modeIdentifiers;
}

/**
* Get the distance between this and another point
* <p/>
Expand Down Expand Up @@ -568,6 +584,7 @@ public void writeToParcel(Parcel out, int flags) {
out.writeString(region);
out.writeTypedList(operators);
out.writeTypedList(routes);
out.writeList(modeIdentifiers);
}

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package com.skedgo.tripkit.common.model

const val LOCATION_CLASS_SCHOOL = "SchoolLocation"
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public ScheduledStop createFromParcel(Parcel in) {
stop.mType = StopType.from(in.readString());
stop.modeInfo = in.readParcelable(ModeInfo.class.getClassLoader());
stop.wheelchairAccessible = (Boolean) in.readValue(Boolean.class.getClassLoader());
stop.bicycleAccessible = (Boolean) in.readValue(Boolean.class.getClassLoader());
stop.alertHashCodes = in.readArrayList(Long.class.getClassLoader());
return stop;
}
Expand Down Expand Up @@ -63,6 +64,9 @@ public ScheduledStop[] newArray(int size) {
@SerializedName("wheelchairAccessible")
private @Nullable
Boolean wheelchairAccessible;
@SerializedName("bicycleAccessible")
private @Nullable
Boolean bicycleAccessible;
@SerializedName("alertHashCodes")
private @Nullable
ArrayList<Long> alertHashCodes;
Expand Down Expand Up @@ -146,6 +150,7 @@ public void fillFrom(Location location) {
mParentId = other.mParentId;
mCurrentFilter = other.mCurrentFilter;
wheelchairAccessible = other.wheelchairAccessible;
bicycleAccessible = other.bicycleAccessible;
alertHashCodes = other.alertHashCodes;
}
}
Expand Down Expand Up @@ -266,6 +271,15 @@ public void setWheelchairAccessible(@Nullable Boolean wheelchairAccessible) {
this.wheelchairAccessible = wheelchairAccessible;
}

@Nullable
public Boolean getBicycleAccessible() {
return bicycleAccessible;
}

public void setBicycleAccessible(@Nullable Boolean bicycleAccessible) {
this.bicycleAccessible = bicycleAccessible;
}

public String getEndStopCode() {
return mEndStopCode;
}
Expand Down Expand Up @@ -323,6 +337,7 @@ public void writeToParcel(Parcel out, int flags) {
out.writeString(mType == null ? null : mType.toString());
out.writeParcelable(modeInfo, 0);
out.writeValue(wheelchairAccessible);
out.writeValue(bicycleAccessible);
out.writeList(alertHashCodes);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* Represents a future stop of a service in a trip.
*/
public class ServiceStop extends Location implements WheelchairAccessible {
public class ServiceStop extends Location implements WheelchairAccessible, BicycleAccessible {
public static final Creator<ServiceStop> CREATOR = new Creator<ServiceStop>() {
public ServiceStop createFromParcel(Parcel in) {
Location location = Location.CREATOR.createFromParcel(in);
Expand All @@ -23,6 +23,7 @@ public ServiceStop createFromParcel(Parcel in) {
stop.code = in.readString();
stop.shortName = in.readString();
stop.wheelchairAccessible = (Boolean) in.readValue(Boolean.class.getClassLoader());
stop.bicycleAccessible = (Boolean) in.readValue(Boolean.class.getClassLoader());
stop.type = StopType.from(in.readString());

return stop;
Expand All @@ -46,6 +47,7 @@ public ServiceStop[] newArray(int size) {
@SerializedName("code") private String code;
@SerializedName("shortName") private @Nullable String shortName;
@SerializedName("wheelchairAccessible") private @Nullable Boolean wheelchairAccessible;
@SerializedName("bicycleAccessible") private @Nullable Boolean bicycleAccessible;

public ServiceStop() {}

Expand Down Expand Up @@ -101,6 +103,14 @@ public void setWheelchairAccessible(@Nullable Boolean wheelchairAccessible) {
this.wheelchairAccessible = wheelchairAccessible;
}

@Nullable public Boolean getBicycleAccessible() {
return bicycleAccessible;
}

public void setBicycleAccessibleAccessible(@Nullable Boolean bicycleAccessible) {
this.bicycleAccessible = bicycleAccessible;
}

public StopType getType() {
return type;
}
Expand Down Expand Up @@ -148,6 +158,7 @@ public void writeToParcel(Parcel out, int flags) {
out.writeString(code);
out.writeString(shortName);
out.writeValue(wheelchairAccessible);
out.writeValue(bicycleAccessible);
out.writeString(type == null ? null : type.toString());
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public class TransportMode {
public static final String ID_SHUFFLE = "ps_shu";
public static final String ID_TNC = "ps_tnc";
public static final String ID_BICYCLE = "cy_bic";
public static final String ID_SCHOOL_BUS = "pt_sch";
public static final String ID_SCHOOL_BUS = "pt_ltd_SCHOOLBUS";
public static final String ID_PUBLIC_TRANSPORT = "pt_pub";
public static final String ID_MOTORBIKE = "me_mot";
public static final String ID_CAR = "me_car";
Expand Down Expand Up @@ -62,7 +62,7 @@ public static int getLocalIconResId(@Nullable String identifier) {
return R.drawable.ic_public_transport;
} else if (ID_TAXI.equals(identifier)) {
return R.drawable.ic_taxi;
} else if (ID_SHUTTLE_BUS.equals(identifier)) {
} else if (ID_SHUTTLE_BUS.equals(identifier) || ID_SCHOOL_BUS.equals(identifier)) {
return R.drawable.ic_shuttlebus;
} else if (ID_MOTORBIKE.equals(identifier)) {
return R.drawable.ic_motorbike;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,8 @@ package com.skedgo.tripkit.common.model

interface WheelchairAccessible {
val wheelchairAccessible: Boolean?
}

interface BicycleAccessible {
val bicycleAccessible: Boolean?
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@

import android.util.DisplayMetrics;

import com.skedgo.tripkit.configuration.Server;
import com.skedgo.tripkit.configuration.ServerManager;
import com.skedgo.tripkit.routing.ModeInfo;
import com.skedgo.tripkit.common.model.TransportMode;

public final class TransportModeUtils {
public static final String ICON_URL_TEMPLATE = Server.ApiTripGo.getValue() + "modeicons/android/%s/ic_transport_%s.png";
public static final String ICON_URL_TEMPLATE = ServerManager.INSTANCE.getConfiguration().getApiTripGoUrl() + "modeicons/android/%s/ic_transport_%s.png";

private TransportModeUtils() {
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ data class Geofence(
) {
var timeline: Long = -1L

fun computeAndSetTimeline(tripEndDateTimeInMillis: Long): Long {
fun computeAndSetTimeline(tripEndDateTimeInMillis: Long) {
val currentTimeInMillis = System.currentTimeMillis()
return tripEndDateTimeInMillis - currentTimeInMillis
timeline = tripEndDateTimeInMillis - currentTimeInMillis
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package com.skedgo.tripkit.routing

import androidx.annotation.StringDef

@Retention(AnnotationRetention.RUNTIME)
@StringDef(
RemoteIcon.NEURON,
RemoteIcon.LIME,
)
annotation class RemoteIcon {
companion object {
const val NEURON = "neuron"
const val LIME = "lime"
}
}
Loading