Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
362c632a
Commit
362c632a
authored
May 13, 2015
by
Diana Huang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Catch BSON errors as well as PyMongo errors when emitting
MongoDB events. TNL-2035
parent
ac8b75ca
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
common/djangoapps/track/backends/mongodb.py
+4
-2
common/test/acceptance/tests/studio/test_studio_split_test.py
+0
-1
No files found.
common/djangoapps/track/backends/mongodb.py
View file @
362c632a
...
...
@@ -7,6 +7,7 @@ import logging
import
pymongo
from
pymongo
import
MongoClient
from
pymongo.errors
import
PyMongoError
from
bson.errors
import
BSONError
from
track.backends
import
BaseBackend
...
...
@@ -89,8 +90,9 @@ class MongoBackend(BaseBackend):
"""Insert the event in to the Mongo collection"""
try
:
self
.
collection
.
insert
(
event
,
manipulate
=
False
)
except
PyMongoError
:
# The event will be lost in case of a connection error.
except
(
PyMongoError
,
BSONError
):
# The event will be lost in case of a connection error or any error
# that occurs when trying to insert the event into Mongo.
# pymongo will re-connect/re-authenticate automatically
# during the next event.
msg
=
'Error inserting to MongoDB event tracker backend'
...
...
common/test/acceptance/tests/studio/test_studio_split_test.py
View file @
362c632a
...
...
@@ -1044,7 +1044,6 @@ class GroupConfigurationsTest(ContainerBase, SplitTestMixin):
rendered_group_names
=
self
.
get_select_options
(
page
=
courseware_page
,
selector
=
".split-test-select"
)
self
.
assertListEqual
(
group_names
,
rendered_group_names
)
@skip
# TODO fix this, see TNL-2035
def
test_split_test_LMS_staff_view
(
self
):
"""
Scenario: Ensure that split test is correctly rendered in LMS staff mode as it is
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment