Skip to content

Commit

Permalink
Add example to try out pyodide importing modules (#78)
Browse files Browse the repository at this point in the history
* add example to try out pyodide importing classes

* lints
  • Loading branch information
alanisaac authored Sep 26, 2023
1 parent a7d882c commit 2c71dad
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
12 changes: 12 additions & 0 deletions rules-engine/src/rules_engine/import_test_1.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
"""
TODO: this module was created to test importing via Pyodide.
Once that testing is complete, this module should be deleted.
"""

from . import import_test_2


def try_it_out() -> bool:
foo = import_test_2.Foo()
foo.call_me()
return True
9 changes: 9 additions & 0 deletions rules-engine/src/rules_engine/import_test_2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
"""
TODO: this module was created to test importing via Pyodide.
Once that testing is complete, this module should be deleted.
"""


class Foo:
def call_me(self):
print("I was called!")

0 comments on commit 2c71dad

Please sign in to comment.