Comments (8)
Seems like the github URL specified on the pub page is invalid (https://www.github.com/dart- lang/reflectable/reflectable). It gives me a 404 right now. Also the pubspec.yaml file in reflectable refers to this URL.
True - pub does not support specifying a path in a git dependency. We were not aware of this restriction when we wrote the documentation, and never got around changing it. Sorry about that.
The only way to depend on a non-published version that we are aware of is to make a local git checkout, and have a path-dependency on that:
dependencies:
reflectable:
path: ../reflectable/reflectable
This is of course suboptimal, and we want to restructure the repo, so the reflectable package is at the root.
When I try running pub get with reflectable: "^0.1.4" in my pubspec.yaml, I get this error:
Package reflectable has no versions that match >=0.1.4 <0.2.0 derived from:
myproject depends on version ^0.1.4
I'm using version 1.12.1. These issues are maybe related?
This is confusing - having a "^0.1.4"
dependency should just work
(though we just published 0.1.5!).
I made an empty directory with a pubspec.yaml
with the following:
name: testproject
dependencies:
reflectable: ^0.1.4
And then ran pub get
:
+ analyzer 0.26.1+3
+ args 0.13.2
+ barback 0.15.2+6
+ charcode 1.1.0
+ cli_util 0.0.1+2
+ code_transformers 0.2.9+4
+ collection 1.1.2
+ csslib 0.12.1
+ glob 1.0.5
+ html 0.12.2
+ logging 0.11.1+1
+ package_config 0.1.3
+ path 1.3.6
+ plugin 0.1.0
+ pool 1.1.0
+ reflectable 0.1.5
+ source_maps 0.10.1
+ source_span 1.2.0
+ stack_trace 1.4.2
+ string_scanner 0.1.4
+ utf 0.9.0+2
+ watcher 0.9.7
+ when 0.2.0
+ which 0.1.3
+ yaml 2.1.5
Changed 25 dependencies!
Precompiling dependencies...
Loading source assets...
Loading reflectable/src/transform_import transformers...
Precompiled reflectable.
That is with pub 1.12.1.
Could you try to do something similar?
Thanks
from reflectable.dart.
Sorry I misunderstood the first part of your bug-report.
I thought you were trying to use something like:
dependencies:
reflectable:
git: https://www.github.com/dart-lang/reflectable/reflectable
That is a problem we also have been fighting with and want to solve.
The homepage link in the pubspec.yaml (that is used on the pub.dartlang.org page) should not give problems in pub get
, but it should be fixed of course. A fix is in: https://codereview.chromium.org/1334243002/
The other problem of:
Package reflectable has no versions that match >=0.1.4 <0.2.0 derived from:
myproject depends on version ^0.1.4
Seems unrelated - this should definitely work, could you try doing it in an empty package?
from reflectable.dart.
Package reflectable has no versions that match >=0.1.4 <0.2.0 derived from:
myproject depends on version ^0.1.4
These pub messages are often misleading (there is an older open issue for improving this).
Try pub upgrade -v
, it might provide additional information about where pub fails resolving the dependencies.
from reflectable.dart.
Considering that the link on pub.dartlang.org has been corrected and we haven't received further info on the 'Package reflectable has no versions that match' problem, I'll close this issue. Please create a new issue if similar problems still exist.
from reflectable.dart.
Package reflectable has no versions that match >=0.4.0 <0.5.0 derived from: -myproject depends on version ^0.4.0
Pub 1.11.3
Dart VM version 1.11.3 (windows x64)
from reflectable.dart.
@brown2rl this is just a misleading error message of pub get
. reflectable
0.4.0 requires Dart SDK >= 1.12.
from reflectable.dart.
@zoechi updated dart to latest version & all fixed!
from reflectable.dart.
Very good! ;-)
from reflectable.dart.
Related Issues (20)
- Fails when upgrading
- 【macos】Attempt to `invoke` without class mirrors. HOT 1
- [Question] is it possible build an "Angular Style DI" library using Reflectable? HOT 1
- [question] - Is it possible to have Annotations with Parameters? HOT 2
- [Question] - how to get Constructor arguments? HOT 2
- [Bug?] ERROR: This requires the 'constructor-tearoffs' language feature to be enabled. HOT 12
- [Question] - Listening to Method invocation HOT 6
- [Question] - Stats on Bundle Sizes and Performance Implications/metrics of using Reflectable ? HOT 1
- Cannot reflect ```flutter/material.dart``` URIs for ```Container``` type HOT 12
- This reflector does not match anything HOT 11
- Reflectable is not a know builder HOT 1
- Unsupported operation: location HOT 4
- Reflectable don't find "main" but im using in my library not an application HOT 5
- How to generate code according to filter rules HOT 2
- The build_runner those not generate anything HOT 1
- Annotated parameter and Functions
- Include annotated types that are not imported to `main.dart` HOT 2
- Severe error during build with @reflector and @JsonKey on the same class. HOT 1
- isSubtype exception for classes without parents HOT 2
- Where is initializeReflectable method? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from reflectable.dart.