Skip to content

Commit 046f488

Browse files
v8: Major improvements & 'flutter_map' v4 support (JaffaKetchup#114)
* Updated versioning throughout Reorganised internal errors Supported v8 of sharing module Improved stability * Added support for custom HTTP clients (JaffaKetchup#112) * Fix example application building * Fix example application building * Built Example Applications * Fixed bugs * Built Example Applications * Fixed bugs (JaffaKetchup#68 & JaffaKetchup#90) * Built Example Applications * Performance improvements Internal refactoring * Updated versioning Updated changelog * Built Example Applications * Updated issue templates Updated contributing guidelines * Fixed bugs within initialisation safety system * Built Example Applications * Updated Windows building configuration * Built Example Applications * Added eviction of failed tiles from `ImageCache` (JaffaKetchup#115) Refactored `bulkDownloader` in preparation for future works Added Android app signing to example Updated GitHub Actions workflow to improve stability * Removed Android app signing from example app * Fixed GitHub Actions workflow * Built Example Applications * Reimplemented bulk download system Fixed high memory usage when bulk downloading (JaffaKetchup#86) Improved bulk downloading performance Minor refactoring and bug fixes * Ignored false-positive lint * Built Example Applications * Fixed bulk downloading cancelling/ending system in non-buffered mode * Built Example Applications * Fixed bugs * Built Example Applications * Added status code check to bulk downloader Updated version, changelog, and readme * Built Example Applications * Improved stability of some synchronous methods * Minor improvements * Built Example Applications * Improved stability of `initialisation` method Improved efficiency of `TilesGenerator` isolates Fixed major bug Updated example application * Built Example Applications * Updated CHANGELOG and versioning Removed Ko-Fi sponsoring option due to GitHub Sponsors being preferable Removed deprecated methods and options from previous versions Minor improvements to `RootManagement.reset` method * Built Example Applications * Added support for 'flutter_map' v4 Updated CHANGELOG and version * Built Example Applications * Minor documentation improvements * Built Example Applications * Added support for Isar 3.1.0 Bug fixes * Built Example Applications * Updated dependencies Added more appropriate attribution * Built Example Applications * Increased memory efficiency during bulk downloading Bug fixes & performance improvements Minor refactoring * Built Example Applications * Prepare for v8 release Complete upgrade to flutter_map v4 * Bumped to v8.0.0 --------- Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 3d723ed commit 046f488

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+1669
-1253
lines changed

.github/FUNDING.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
github: JaffaKetchup
2-
ko_fi: JaffaKetchup
1+
github: JaffaKetchup

.github/ISSUE_TEMPLATE/bug-report.yaml

Lines changed: 37 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -8,59 +8,61 @@ body:
88
value: "
99
# Bug Report
1010
11-
Thanks for taking the time to fill out this bug report! It helps us to improve the experience for you and other developers that may be facing a similar problem. We aim to respond to bug reports as soon as possible, but it may take longer to resolve this issue depending on its complexity and severity. To help us verify the issue quicker, please include as much information as you can.
11+
Thanks for taking the time to fill out this bug report! To help us verify the issue quicker, please include as much information as you can.
12+
13+
14+
---
15+
16+
17+
FMTC is a large, platform-dependent package, and there's only one person running manual tests on it before releases, so your support is appreciated.
18+
19+
> If you are using FMTC in a proprietary project, please read and understand [this important legal notice](https://fmtc.jaffaketchup.dev/#proprietary-licensing) on the topic of licensing. Please get in touch if you would like more information!
20+
21+
22+
---
23+
24+
25+
Before reporting a bug, please:
26+
27+
* Check if there is already an open or closed issue that is similar to yours
28+
29+
* Ensure that your Flutter environment is correctly installed & set-up
30+
31+
* Ensure that this package, 'flutter_map', and any modules are correctly installed & set-up
32+
33+
34+
---
1235
"
13-
- type: markdown
14-
attributes:
15-
value: ---
1636
- type: textarea
17-
id: description
37+
id: details
1838
attributes:
1939
label: What is the bug?
20-
description: What were you implementing when you found this issue? What happens when the bug triggers?
21-
validations:
22-
required: true
23-
- type: textarea
24-
id: expected-behaviour
25-
attributes:
26-
label: What is the expected behaviour?
27-
description: What do you think should have happened?
40+
description: What were you implementing when you found this issue? What happens when the bug triggers? What do you think should have happened instead? Please include as much detail as possible, including screenshots and screen-recordings if you can.
2841
validations:
2942
required: true
3043
- type: textarea
3144
id: reproduce
3245
attributes:
33-
label: How can we reproduce this issue?
46+
label: How can we reproduce it?
3447
description: |
35-
Please include a [minimal reproducible example](https://en.wikipedia.org/wiki/Minimal_reproducible_example) (preferable), otherwise detail the exact steps to reproduce this issue.
36-
If you do not include any information here, it will take longer for us to verify your issue.
48+
Please include a fully formatted [minimal reproducible example](https://en.wikipedia.org/wiki/Minimal_reproducible_example) wrapped in a [Dart code block](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/creating-and-highlighting-code-blocks#syntax-highlighting), otherwise, detail the exact steps to reproduce this issue.
49+
If you do not include any information here, it will take longer for us to verify your issue.
50+
validations:
51+
required: true
3752
- type: textarea
3853
id: solution
3954
attributes:
4055
label: Do you have a potential solution?
41-
description: "If so, please detail it: it will make it quicker for us to fix the issue"
42-
- type: textarea
43-
id: additional-info
44-
attributes:
45-
label: Can you provide any other information?
46-
description: |
47-
Please attach any other logs, screenshots, or screen recordings.
48-
Is there anything else you'd like to say?
56+
description: "If so, please detail it: it will make it quicker for us to fix the issue."
4957
- type: markdown
5058
attributes:
5159
value: ---
52-
- type: dropdown
60+
- type: input
5361
id: platform
5462
attributes:
55-
label: Platforms Affected
56-
description: What platforms does this issue affect?
57-
multiple: true
58-
options:
59-
- Android
60-
- iOS
61-
- Windows
62-
- MacOS
63-
- Linux
63+
label: Platforms
64+
description: Please detail the devices and operating systems you can reproduce this bug on, separated by commas.
65+
placeholder: eg. Android 13 (Samsung Galaxy S99), Windows 11 (x64)
6466
validations:
6567
required: true
6668
- type: dropdown
@@ -74,33 +76,4 @@ body:
7476
- "Erroneous: Prevents normal functioning and causes errors in the console"
7577
- "Fatal: Causes the application to crash"
7678
validations:
77-
required: true
78-
- type: dropdown
79-
id: frequency
80-
attributes:
81-
label: Frequency
82-
description: How often does this issue occur?
83-
options:
84-
- "Once: Occurred on a single occasion"
85-
- "Rarely: Occurs every so often"
86-
- "Often: Occurs more often than when it doesn't"
87-
- "Consistently: Always occurs at the same time and location"
88-
validations:
89-
required: true
90-
- type: markdown
91-
attributes:
92-
value: ---
93-
- type: checkboxes
94-
id: terms
95-
attributes:
96-
label: Requirements
97-
description: These are in place to prevent spam and unnecessary reports. Please read and understand them fully before posting.
98-
options:
99-
- label: I agree to follow this project's [Code of Conduct](https://github.com/jaffaketchup/flutter_map_tile_caching/blob/main/CODE_OF_CONDUCT.md)
100-
required: true
101-
- label: I have checked for known issues in the GitHub tracker and [on the docs site](https://fmtc.jaffaketchup.dev/known-issues-and-reporting#known-issues)
102-
required: true
103-
- label: I have completed the pre-report checks listed [on the docs site](https://fmtc.jaffaketchup.dev/known-issues-and-reporting#reporting-a-bug)
104-
required: true
105-
- label: If I am using FMTC in a proprietary project, I have read and understood [this important legal notice](https://fmtc.jaffaketchup.dev/#proprietary-licensing)
106-
required: true
79+
required: true

.github/ISSUE_TEMPLATE/feature-request.yaml

Lines changed: 23 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,26 @@ body:
88
value: "
99
# Feature Request
1010
11-
Thanks for taking the time to let us know what you want to see! It helps us to improve the experience for you and other developers that may be facing a similar problem. Unfortunately, response times for feature requests are longer than bug reports, as they are lower priority. If you want this functionality implemented quickly, please make a Pull Request to go alongside this feature request.
11+
Thanks for taking the time to let us know what you want to see!
12+
Unfortunately, response times for feature requests are longer than bug reports, as they are lower priority. If you want this functionality implemented quickly, please make a Pull Request to go alongside this feature request.
13+
14+
> If you are using FMTC in a proprietary project, please read and understand [this important legal notice](https://fmtc.jaffaketchup.dev/#proprietary-licensing) on the topic of licensing. Please get in touch if you would like more information!
15+
16+
17+
---
18+
19+
20+
Before requesting a feature, please:
21+
22+
* Check if there is already an open or closed issue that is similar to yours
23+
24+
* Ensure that you're using the latest version of FMTC and any modules
25+
26+
* Ensure that you've read the documentation thoroughly
27+
28+
29+
---
1230
"
13-
- type: markdown
14-
attributes:
15-
value: ---
1631
- type: textarea
1732
id: description
1833
attributes:
@@ -25,30 +40,14 @@ body:
2540
attributes:
2641
label: What other alternatives are available?
2742
description: Have you used any workarounds, for example?
28-
- type: textarea
29-
id: additional-info
30-
attributes:
31-
label: Can you provide any other information?
32-
description: |
33-
Please attach any other logs, screenshots, or screen recordings.
34-
Is there anything else you'd like to say?
3543
- type: markdown
3644
attributes:
3745
value: ---
38-
- type: dropdown
39-
id: platform
46+
- type: textarea
47+
id: additional-info
4048
attributes:
41-
label: Platforms Affected
42-
description: What platforms does this issue affect?
43-
multiple: true
44-
options:
45-
- Android
46-
- iOS
47-
- Windows
48-
- MacOS
49-
- Linux
50-
validations:
51-
required: true
49+
label: Can you provide any other information?
50+
description: Is there anything else you'd like to say?
5251
- type: dropdown
5352
id: severity
5453
attributes:
@@ -60,20 +59,3 @@ body:
6059
- "Obtrusive: No workarounds are available, and this is essential to me"
6160
validations:
6261
required: true
63-
- type: markdown
64-
attributes:
65-
value: ---
66-
- type: checkboxes
67-
id: terms
68-
attributes:
69-
label: Requirements
70-
description: These are in place to prevent spam. Please read and understand them fully before posting.
71-
options:
72-
- label: I agree to follow this project's [Code of Conduct](https://github.com/jaffaketchup/flutter_map_tile_caching/blob/main/CODE_OF_CONDUCT.md)
73-
required: true
74-
- label: I have checked for similar feature requests which may be duplicates
75-
required: true
76-
- label: I am using the [latest stable version](https://pub.dev/packages/flutter_map_tile_caching) of this package
77-
required: true
78-
- label: If I am using FMTC in a proprietary project, I have read and understood [this important legal notice](https://fmtc.jaffaketchup.dev/#proprietary-licensing)
79-
required: true

.github/workflows/main.yml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,6 @@ jobs:
3636
uses: subosito/flutter-action@v2
3737
with:
3838
channel: "stable"
39-
- name: Ensure Correct Flutter Installation
40-
run: flutter --version
4139
- name: Get All Dependencies
4240
run: flutter pub get
4341
- name: Check Formatting
@@ -65,20 +63,18 @@ jobs:
6563
uses: subosito/flutter-action@v2
6664
with:
6765
channel: "stable"
68-
- name: Ensure Correct Flutter Installation
69-
run: flutter --version
70-
- name: Ensure Clean Flutter Environment
71-
run: flutter clean
7266
- name: Remove Existing Prebuilt Applications
7367
run: Remove-Item "prebuiltExampleApplications" -Recurse -ErrorAction Ignore
7468
working-directory: .
7569
- name: Create Prebuilt Applications (Output) Directory
7670
run: md prebuiltExampleApplications
7771
working-directory: .
72+
- name: Get All Dependencies
73+
run: flutter pub get
7874
- name: Build Android Application
79-
run: flutter build apk --split-per-abi --obfuscate --split-debug-info=/symbols
75+
run: flutter build apk --obfuscate --split-debug-info=/symbols
8076
- name: Move Android Application To Output Directory
81-
run: move "example\build\app\outputs\flutter-apk\app-armeabi-v7a-release.apk" "prebuiltExampleApplications\AndroidApplication.apk"
77+
run: move "example\build\app\outputs\flutter-apk\app-release.apk" "prebuiltExampleApplications\AndroidApplication.apk"
8278
working-directory: .
8379
- name: Build Windows Application
8480
run: flutter build windows --obfuscate --split-debug-info=/symbols

.pubignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
prebuiltExampleApplications/

CHANGELOG.md

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,25 @@ Many thanks to my sponsors, no matter how much or how little they donated. Spons
1313

1414
# Changelog
1515

16-
## [7.2.0] - 2023/03/XX
16+
## [8.0.0] - 2023/XX/XX
17+
18+
* Bulk downloading has been rewritten to use a new implementation that generates tile coordinates at the same time as downloading tiles
19+
* `check`ing the number of tiles in a region now uses a significantly faster and more efficient implementation
20+
* Starting a download no longer causes significant memory bloat, which could crash the app on large regions
21+
* Starting a download is now much quicker and closer to constant time, as tile coordinates don't need to be pre-generated
22+
* Cancelling a download no longer causes many `QueueCancelledException`s to be thrown, which could crash the app
23+
* Removed reliance on 'queue' dependency in order to squeeze as much speed as possible out of the new implementation
24+
* Other improvements
25+
* `initialise` now automatically renames databases if their filename ID doesn't match their name hash
26+
* `initialise` can now throw a more useful `FMTCInitialisationException` with improved clarity
27+
* Methods that require a valid store descriptor object to be present now throw `FMTCDamagedStoreException` if it is not present
28+
* Other bug fixes
29+
* `FMTCImageProvider`'s oldest tile deleter & bulk downloading now respects custom root directories
30+
* `FMTCImageProvider` now evicts failed images from Flutter's `ImageCache` to prevent errors
31+
* Added support for custom `HttpClient`s/`BaseClient`s
32+
* Added support for Isar v3.1 (bug fixes & stability improvements)
33+
34+
## [7.2.0] - 2023/03/03
1735

1836
* Stability improvements
1937
* Starting multiple downloads no longer causes `LateInitializationErrors`

CONTRIBUTING.md

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
# Contributing
22

3-
*Please note we have a code of conduct, please follow it in all your interactions with this project.*
3+
## Reporting A Bug
44

5-
When contributing to this repository, please first discuss the change you wish to make via any one of the following:
5+
FMTC is a large, platform-dependent package, and there's only one person running manual tests on it before releases, so there's a decent chance that a bug you've found is actually a bug. Reporting it is always appreciated!
66

7-
- A feature request issue (preferred)
8-
- A ping to '@JaffaKetchup' on the flutter_map Discord server plugin channel (preferred for small changes)
9-
- An email to github@jaffaketchup.dev (last resort)
7+
Before reporting a bug, please:
108

11-
You may then submit a pull request, conforming to the following basic rules:
9+
* Check if there is already an open or closed issue that is similar to yours
10+
* Ensure that your Flutter environment is correctly installed & set-up
11+
* Ensure that this package, 'flutter_map', and any modules are correctly installed & set-up
1212

13-
- Try to ensure code is concise, but well documentated and explained within the code
14-
- Try to keep to a similar coding style as I have used
15-
- You must not change the linting rules
13+
## Contributing Code
1614

17-
Thanks for you contribution, it's greatly appriciated!
15+
Contributors are always welcome, and support is always greatly appreciated! Before opening a Pull Request, however, please open a feature request or bug report to link the PR to.
16+
17+
When submitting code, please:
18+
19+
* Keep code concise and in a similar style to surrounding code
20+
* Document all public APIs in detail and with correct grammar
21+
* Use the included linting rules
22+
* Update the example application to appropriately consume any public API changes
23+
* Avoid incrementing this package's version number or changelog

README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,7 @@ Many thanks for any amount you can spare, it means a lot to me!
2525

2626
You can read more about me and what I do on my [GitHub Sponsors](https://github.com/sponsors/JaffaKetchup) page, where you can donate as well.
2727

28-
[![Sponsor Me Via GitHub Sponsors](GitHubSponsorsImage.jpg)](https://github.com/sponsors/JaffaKetchup)
29-
30-
Alternatively, if you prefer not to use GitHub Sponsors, please feel free to use my [Ko-fi](https://ko-fi.com/jaffaketchup). Note that the PayPal backend will take a small percentage amount of donations made through this method.
28+
[![Sponsor Me Via GitHub Sponsors](https://github.com/JaffaKetchup/flutter_map_tile_caching/blob/main/GitHubSponsorsImage.jpg)](https://github.com/sponsors/JaffaKetchup)
3129

3230
## (Proprietary) Licensing
3331

@@ -43,4 +41,4 @@ However, I am willing to sell alternative (proprietary) licenses on a case-by-ca
4341

4442
I learnt (and am still learning) to code with free, open-source software due to my age and lack of money, and for that reason, I believe in promoting open-source wherever possible to give equal opportunities to everybody, no matter their age or financial position. I'm not sure it's fair for commercial proprietary applications to use software made by people for free out of generosity. On the other hand, I am also trying to make a small amount of money from my projects, by donations or by selling licenses. And I recognise that commercial businesses may want to use my projects for their own proprietary applications.
4543

46-
Therefore, if you would like a license to use this software within a proprietary, I am willing to sell a (preferably yearly or usage based) license for a reasonable price. If this seems like what you want/need, please do not hesitate to get in touch via [fmtc@jaffaketchup.com](mailto:fmtc@jaffaketchup.com).
44+
Therefore, if you would like a license to use this software within a proprietary, I am willing to sell a (preferably yearly or usage based) license for a reasonable price. If this seems like what you want/need, please do not hesitate to get in touch via [fmtc@jaffaketchup.dev](mailto:fmtc@jaffaketchup.dev).

buildAndServeDocs.bat

Lines changed: 0 additions & 6 deletions
This file was deleted.

example/.metadata

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# This file should be version controlled.
55

66
version:
7-
revision: cd41fdd495f6944ecd3506c21e94c6567b073278
7+
revision: f72efea43c3013323d1b95cff571f3c1caa37583
88
channel: stable
99

1010
project_type: app
@@ -13,11 +13,11 @@ project_type: app
1313
migration:
1414
platforms:
1515
- platform: root
16-
create_revision: cd41fdd495f6944ecd3506c21e94c6567b073278
17-
base_revision: cd41fdd495f6944ecd3506c21e94c6567b073278
16+
create_revision: f72efea43c3013323d1b95cff571f3c1caa37583
17+
base_revision: f72efea43c3013323d1b95cff571f3c1caa37583
1818
- platform: windows
19-
create_revision: cd41fdd495f6944ecd3506c21e94c6567b073278
20-
base_revision: cd41fdd495f6944ecd3506c21e94c6567b073278
19+
create_revision: f72efea43c3013323d1b95cff571f3c1caa37583
20+
base_revision: f72efea43c3013323d1b95cff571f3c1caa37583
2121

2222
# User provided section
2323

0 commit comments

Comments
 (0)