Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 30 additions & 1 deletion docs/versionmigration.md
Original file line number Diff line number Diff line change
Expand Up @@ -464,4 +464,33 @@ def on_event_data_handler(stream: StreamConsumer, data: EventData):
pass

… the rest of your code
```
```

### NumPy types no longer handled transparently

Certain code may generate run-time errors such as:

```
Invalid type <class 'numpy.float64'> passed as parameter value
```

NumPy types such as `numpy.int64` and `numpy.float64` are no longer handled transparently.

Where this occurs, the solution is to cast the type appropriately. For example, review the following example code snippet:

```python
.add_value('num_docks_available', df_i_agg.loc[0, 'num_docks_available']) \
```

This might generate the run-time error:

```
Invalid type <class 'numpy.int64'> passed as parameter value
```

Casting to `int` will prevent the run-time error:

```python
.add_value('num_docks_available', int(df_i_agg.loc[0, 'num_docks_available'])) \
```