mapbox / mapbox/mapbox-java

Feature properties parameter declared as '@NonNull'

Open
#1,112 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
438
Forks
117
PR merge metrics
No merged PRs in 30d

Description

As can be seen here, the properties parameter, which is required in the fromGeometry function, is declared as @NonNull, even though a null value is handled correctly in the function body.

Also all other fromGeometry functions declare their properties parameter as @Nullable.

I would expect this to be the case for said fromGeometry function, too.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open services-geojson/src/main/java/com/mapbox/geojson/Feature.java around the fromGeometry function at line 179 and compare its properties annotation with the other fromGeometry functions. Done means the required function's annotation matches its null handling and the other overloads.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.