question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Brython 3.10.6 python-to-javascript engine bug?

See original GitHub issue

I tried the code in console with Brython 3.10.6

__BRYTHON__.python_to_js(`
class Test:
    def __init__(self):
        pass
`)

It reports error: TypeError: undefined is not an object (evaluating 'module_id.replace')

While it works with Brython 3.10.5.

How to make it work with the new version?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
zwzcommented, Jul 17, 2022

Confirmed.

0reactions
PierreQuentelcommented, Jul 16, 2022

My mistake, sorry: I tested with the current development version, not with release 3.10.6…

I could reproduce the bug with 3.10.6 but it is fixed in the development version. Can you confirm ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Some general questions/suggestions · Issue #1702 · brython ...
Some simple issues/bugs to clarify my point: ... My first idea was to convert the pure-Python module to Javascript using Brython and ...
Read more >
Browsing the Python Browser: Brython!
The Brython interpreter and libraries could then be checked, bundled, and deployed employing your desired JavaScript tools.
Read more >
Tweets with replies by brython (@brython3) / Twitter
Release Brython-3.10.6 · brython-dev/brython. The main features in this release are: the Python-to-Javascript engine now uses the Abstract Syntax Tree ...
Read more >
Frequently asked questions - Brython documentation
JavaScript code generated by Brython must be compliant with the specifications of Python, including the dynamic nature of the search attributes, which leads...
Read more >
Browsing the Python Browser: Brython! - DevPress - CSDN
The standard language for front-end web development is JavaScript. Today's Internet browsers all offer features with robust JavaScript engines, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found