Skip to content

Move pigeon to dev_dependencies in geocoding_darwin - #315

Open
ericgriffin wants to merge 1 commit into
Baseflow:mainfrom
ericgriffin:move-pigeon-to-dev-dependency
Open

Move pigeon to dev_dependencies in geocoding_darwin#315
ericgriffin wants to merge 1 commit into
Baseflow:mainfrom
ericgriffin:move-pigeon-to-dev-dependency

Conversation

@ericgriffin

Copy link
Copy Markdown

Moves pigeon from dependencies to dev_dependencies in geocoding_darwin, bringing it in line with geocoding_android, which already declares it that way.

pigeon is a build-time code generator and is not used at runtime here:

  • Nothing under lib/ imports package:pigeon. The generated lib/src/geocoding/geocoding.g.dart imports only dart:async, dart:io, dart:typed_data, package:flutter/foundation.dart, package:flutter/services.dart and package:flutter/widgets.dart. Across the whole lib/ tree the only package imports are package:flutter and package:geocoding_platform_interface.
  • The only file that does import it is pigeons/clgeocoder.dart, the input schema, which a dev_dependency covers.

Because it was a regular dependency, pigeon's own constraints propagated to every application depending on geocoding 5.x. Two effects, the second of which reaches apps that never mention pigeon at all:

  1. The direct conflict in [Bug]: Geolocator 5.0.0 introduced restrictions on pigeon usage #304: an app cannot use pigeon 27.x itself.
  2. A transitive analyzer ceiling. Every released pigeon constrains analyzer >=10.0.0 <13.0.0 (26.3.4, 27.0.0 and 27.3.0 alike), so consumers are held below analyzer 13 and cannot upgrade packages that require it, such as riverpod_generator 4.0.6+, drift_dev 2.34.5, mockito 5.8.1 or build_runner 2.16. This is not resolvable downstream: bumping pigeon does not help since every version carries the same range, and a dependency_overrides entry cannot lift a ceiling they all share.

Fixes #304.

Verification

  • flutter pub get and flutter analyze both clean in geocoding_darwin, including pigeons/clgeocoder.dart (pigeon still resolves for it as a dev dependency).
  • dart run pigeon --input pigeons/clgeocoder.dart still runs and regenerates both outputs, confirming code generation is unaffected.

One aside, deliberately left out of this PR: regenerating shows the committed outputs were produced by Pigeon v26.1.2 while ^26.1.2 now resolves to v26.3.4, so geocoding.g.dart and GeocodingLibrary.g.swift currently drift from what the current generator emits. That is pre-existing and unrelated, so I have not included the regenerated files here. Happy to open a separate PR for it if useful.

Similarly, dart format . reformats three pre-existing files (geocoding.g.dart, geocoding_darwin.dart, pigeons/clgeocoder.dart). Those are unrelated to this change and are not included, so this PR stays a two-file diff.

Pre-launch Checklist

  • I made sure the project builds.
  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • This PR only changes one package (or documents why an exception is needed).
  • I updated pubspec.yaml with an appropriate new version according to the pub versioning philosophy, or this PR does not need version changes.
  • I updated CHANGELOG.md with a new ## x.y.z section that matches the version in pubspec.yaml
  • I updated/added relevant documentation (doc comments with ///).
  • I rebased onto main.
  • I added new tests to check the change I am making, or this PR does not need tests.
  • I made sure all existing and new tests are passing.
  • I ran dart format . and committed any changes.
  • I ran flutter analyze and fixed any errors.

pigeon is a build-time code generator. Nothing under lib/ imports
package:pigeon: the generated lib/src/geocoding/geocoding.g.dart imports only
dart:* and package:flutter/*, and the whole lib/ tree references just
package:flutter and package:geocoding_platform_interface. Only
pigeons/clgeocoder.dart, the input schema, imports it, and a dev_dependency
covers that.

Declaring it as a regular dependency propagated pigeon's own constraints to
every consuming application. geocoding_android already declares it under
dev_dependencies; this brings the Darwin package in line.

Fixes Baseflow#304.
Copilot AI lite review requested due to automatic review settings August 17, 2026 05:40

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the geocoding_darwin federated implementation package to treat pigeon as a build-time tool rather than a runtime dependency, preventing pigeon's (and its analyzer) constraints from propagating into consuming applications.

Changes:

  • Bumps geocoding_darwin version to 1.0.3.
  • Moves pigeon: ^26.1.2 from dependencies to dev_dependencies.
  • Adds a 1.0.3 changelog entry describing the dependency-scope change and rationale.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
geocoding_darwin/pubspec.yaml Moves pigeon to dev_dependencies and bumps the package version to 1.0.3.
geocoding_darwin/CHANGELOG.md Documents the 1.0.3 change and why it prevents downstream version-solver conflicts.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

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.

[Bug]: Geolocator 5.0.0 introduced restrictions on pigeon usage

2 participants