GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add a test case for issue #280 · boostorg/python@f7254f5

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • test
    • fabscript
    • module_init_exception.cpp
    • module_init_exception.py
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎test/fabscript‎

Copy file name to clipboardExpand all lines: test/fabscript
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ for t in [('injected',),
6767
('args',),
6868
('raw_ctor',),
6969
('exception_translator',),
70+
('module_init_exception',),
7071
('test_enum', ['enum_ext']),
7172
('test_cltree', ['cltree']),
7273
('newtest', ['m1', 'm2']),
Collapse file

‎test/module_init_exception.cpp‎

Copy file name to clipboard
+14Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// Copyright (C) 2003 Rational Discovery LLC
2+
// Distributed under the Boost Software License, Version 1.0. (See
3+
// accompanying file LICENSE_1_0.txt or copy at
4+
// http://www.boost.org/LICENSE_1_0.txt)
5+
6+
#include <boost/python/module.hpp>
7+
#include <stdexcept>
8+
9+
using namespace boost::python;
10+
11+
BOOST_PYTHON_MODULE(module_init_exception_ext)
12+
{
13+
throw std::runtime_error("Module init failed");
14+
}
Collapse file

‎test/module_init_exception.py‎

Copy file name to clipboard
+12Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Copyright (C) 2003 Rational Discovery LLC. Distributed under the Boost
2+
# Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy
3+
# at http://www.boost.org/LICENSE_1_0.txt)
4+
5+
print("running...")
6+
7+
try:
8+
import module_init_exception_ext
9+
except RuntimeError as e:
10+
print(e)
11+
12+
print("Done.")

0 commit comments

Comments
0 (0)
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.