mapbox / mapbox/supermercado

'burn' is working only in cli mode

Open
#33 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
132
Forks
21
PR merge metrics
No merged PRs in 30d

Description

When I use supermercado burn in cli mode, it works, passing [x,y,z]'s to specified file. When I use it as Python function, it does not work, writing this:
`File "C:\Users\someuser\Anaconda3\envs\somecode\lib\site-packages\supermercado\burntiles.py", line 20, in find_extrema
totalArr = np.array([c for f in features for poly in f['geometry']['coordinates'] for c in poly for poly in f])
File "C:\Users\someuser\Anaconda3\envs\somecode\lib\site-packages\supermercado\burntiles.py", line 20, in
totalArr = np.array([c for f in features for poly in f['geometry']['coordinates'] for c in poly for poly in f])
TypeError: string indices must be integers`

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

Start in supermercado/burntiles.py at find_extrema, line 20, and compare the data passed by the Python function with the working CLI path. Reproduce the shown TypeError and verify the Python function writes the [x,y,z] values to the specified file, matching CLI behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.