Skip to content

beginner's bugs #7

Description

@dimarcom

Hi Maher,

I am trying to run BlockSim and I run into a few bugs... but it's very probably because I don't know what I'm doing...

I set the model to 0 in InputsConfig.py.

I tried to run Main.py, but I got the following error:

File "/Users/dimarcom/Documents/blockchain/par les copains/BlockSim-master/Statistics.py", line 38, in blocks_results
Statistics.staleRate= round(Statistics.staleBlocks/Statistics.totalBlocks * 100, 2)
ZeroDivisionError: division by zero

So I opened statistics.py and changed the following line:

totalBlocks=0 --to--> totalBlocks=10

thinking it would create a chain composed of 10 blocks.

Then I ran again Main.py, and I got:

File "/Users/dimarcom/PycharmProjects/blockchain/venv/lib/python3.9/site-packages/pandas/core/internals/base.py", line 69, in _validate_set_axis
raise ValueError(
ValueError: Length mismatch: Expected axis has 0 elements, new values have 7 elements

... and I have to prepare my classes for next week, so I stopped there ;)

I'll come back to it soon enough I hope.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions