Skip to content

Crashes Python on Windows #58

@Darthfett

Description

@Darthfett

Trying to create a very basic game, and getting crashing on Windows 7 32-bit:

    import bacon

    class Game:
        def on_tick(self):
            bacon.clear(0, 0, 0, 1)
            bacon.set_color(128, 128, 128, 1)
            bacon.fill_rect(50, 50, 150, 150)

    bacon.window.width = 512
    bacon.window.height = 512
    bacon.run(Game())
    $ py34 test_bacon.py

Crashes the python interpreter:

    Problem signature:
      Problem Event Name:   APPCRASH
      Application Name: python.exe
      Application Version:  0.0.0.0
      Application Timestamp:    5325ec4b
      Fault Module Name:    Bacon.dll
      Fault Module Version: 0.0.0.0
      Fault Module Timestamp:   5377c264
      Exception Code:   c0000005
      Exception Offset: 000798f3
      OS Version:   6.1.7601.2.1.0.256.4
      Locale ID:    1033
      Additional Information 1: 0a9e
      Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
      Additional Information 3: 0a9e
      Additional Information 4: 0a9e372d3b4ad19135b953a78882e789

Using python 3.4:

    $ py34 -m pip show bacon
    ---
    Name: bacon
    Version: 0.3.1
    Location: c:\python34\lib\site-packages
    Requires:

Please note that I did have to make some a couple to bacon code to be able to get this far:

  1. Line 396 in native.py, removed levels = -1 parameter from call to __import__ . Python 3 no longer supports a negative value for levels, and 0 is the default:
            _pkg_resources = __import__('pkg_resources', globals(), locals(), [])
  1. Line 159 in core.py, changed import commands to relative import from . import commands. Not sure if I need to add bacon to my PYTHONPATH to fix this without changing the code.

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