Hi everyone!

Thanks to those who attended the meeting last night.

There was a question by Juan that I kind of waffled about. Of course I had
an answer ready the moment I left the venue.

The question is how much information does the bytecode preserve. Does it
include variable names, even for local variables? The answer is of course
yes, as can be proved by the enclosed snippet, running on Batavia.

More on Batavia:

Gary asked me how he could start contributing. The documentation is quite
good for that (always read the docs!), but here's a quick guide:

1) First of all, to install Batavia and get the demo page running as per the
github readme:

https://github.com/pybee/batavia

Play on the sandbox, write some Python and try to get an idea of what works
and what doesn't.

2) Then, you can run the tests for batavia by following the documentation
for first time contributors:

http://batavia.readthedocs.io/en/latest/how-to/contribute-code.html

Notice that some tests say "ok" as they pass, but others say "expected
failure" as they fail. You want to turn one of those "expected failure"
tests into an "ok" passing test by writing the corresponding code.

3) Now you can start reading the implementation. There is still some low
hanging fruit, unimplemented methods in the builtin types, that you can fix
as a first contribution.

An example is in tests/datatypes/test_range.js, where you can see that the
not_implemented list contains a lot of tests. This not_implemented list
contains the name of the tests that are expected to fail. This is why some
tests above yielded an "expected failure" result.

Most of the features those tests check for should be implemented by just
raising the corresponding TypeError in the implementation. In in this case,
the implementation code is in types/Range.js

4) Make a new branch for your fix. You want to be working on your own
branch, not on master.

5) Comment out one of the not_implemented tests as listed on
tests/datatypes/test_range.js, and run the tests again. The test whose name
you commented out should now fail.

6) Implement the code so Batavia has the same behaviour as cPython3.4.

Remember the implementation code is in types/Range.js

The test should now pass. You did it! Make sure to delete the line you
previously commented out on tests/datatypes/test_range.js

7) Now is the time for you to fork Batavia to your own github user (if you
haven't done it yet), and prepare your contribution for submission:

- Make a new remote for your Batavia fork, and push your feature branch to it.
- From that branch on your own Batavia fork, make a pull request against
master branch on the main Batavia repo.
- You will receive either some feedback, or your submission will be accepted.

The Pybee team uses gitter for communications. You can ask questions on the
repo issues, or on gitter: https://gitter.im/pybee/general

Good luck!

Cheers,

Javier
_______________________________________________
melbourne-pug mailing list
melbourne-pug@python.org
https://mail.python.org/mailman/listinfo/melbourne-pug

Reply via email to