question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Property 'readGeometryFromNode' in type 'GMLBase' is not assignable to the same property in base type 'XMLFeature'

See original GitHub issue

Describe the bug Got the following error.

Error: node_modules/ol/format/GMLBase.d.ts:243:15 - error TS2416: Property 'readGeometryFromNode' in type 'GMLBase' is not assignable to the same property in base type 'XMLFeature'.
  Type '(node: Element, opt_options?: ReadOptions) => Geometry | Extent' is not assignable to type '(node: Element, opt_options?: ReadOptions) => Geometry'.
    Type 'Geometry | Extent' is not assignable to type 'Geometry'.
      Type 'number[]' is missing the following properties from type 'Geometry': extent_, extentRevision_, simplifiedGeometryMaxMinSquaredTolerance, simplifiedGeometryRevision, and 51 more.

243     protected readGeometryFromNode(node: Element, opt_options?: import("./Feature.js").ReadOptions | undefined): import("../geom/Geometry.js").default | import("../extent.js").Extent;
              

To Reproduce Steps to reproduce the behavior: Download the following

"depdendencies": {
    "ol": "6.13.0",
},
"devDependencies": {
    "@types/arcgis-rest-api": "^10.4.4",
    "@types/topojson-specification": "^1.0.1",
    "@types/geojson": "^7946.0.4",
}

Additional I’ve tried to fix the version (“^10.4.4”), but didn’t work neither.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
ahocevarcommented, Apr 1, 2022

Thanks for the reproduction case. There was still a // @ts-ignore in the code that kept our tooling from recognising this problem. Fixed with #13533.

0reactions
alasdair-macleodcommented, Apr 1, 2022

Cool. Thanks again 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Property in type is not assignable to the same property in base ...
Three possible solutions: if you don't mind (or actually prefer) the array being read-only, you can declare it as readonly and as const...
Read more >
OpenLayers v7.1.0 API - Class: GMLBase
Abstract base class; normally only used for creating subclasses and not instantiated ... The GeoJSON format does use this property when writing geometries....
Read more >
I've got a TS bug and I think it's because I'm stupid - Reddit
ts(26,5): error TS2416: Property 'debug' in type 'LocalLogger' is not assignable to the same property in base type 'LoggerInterface'. Type '(...
Read more >
Type 'X' is not assignable to type 'Y' in TypeScript | bobbyhadz
To solve the error, we have to make sure the two values have compatible types or use a type assertion. · This means...
Read more >
Visual Studio Code Angular DXReport Error
... TS2416: Property 'removeChilds' in type 'ElementViewModel' is not assignable to the same property in base type 'IElementViewModel'.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found