Skip to content

Upgrade jython from 2.5.2 to 2.7.4-Unavailibility of _thread package #354

Description

@aayushgupta3

Upgrade jython from 2.5.2 to 2.7.4-Unavailibility of _thread package.

The _threading.class used to have
public static Map<Long, PyObject> _threads = (new MapMaker()).weakValues().makeMap();
public static Map<Thread, PyObject> _jthread_to_pythread = (new MapMaker()).weakKeys().weakValues().makeMap();
public static Map<Long, PyObject> _active = _threads;
public static void _register_thread(Thread jthread, PyObject pythread) {
_threads.put(Long.valueOf(jthread.getId()), pythread);
_jthread_to_pythread.put(jthread, pythread);
}
public static void _unregister_thread(Thread jthread) {
_threads.remove(Long.valueOf(jthread.getId()));
}

and was further used.

We had been using this in our python scripts.
Please share the alternatives for the above in the latest version. Couldn't find their alternatives in the documentations.

Looking forward for a quick response.

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions