201 строка
7.5 KiB
YAML
201 строка
7.5 KiB
YAML
# Autogenerated bulkloader.yaml file.
|
|
# You must edit this file before using it. TODO: Remove this line when done.
|
|
# At a minimum address the items marked with TODO:
|
|
# * Fill in connector and connector_options
|
|
# * Review the property_map.
|
|
# - Ensure the 'external_name' matches the name of your CSV column,
|
|
# XML tag, etc.
|
|
# - Check that __key__ property is what you want. Its value will become
|
|
# the key name on import, and on export the value will be the Key
|
|
# object. If you would like automatic key generation on import and
|
|
# omitting the key on export, you can remove the entire __key__
|
|
# property from the property map.
|
|
|
|
# If you have module(s) with your model classes, add them here. Also
|
|
# change the kind properties to model_class.
|
|
python_preamble:
|
|
- import: base64
|
|
- import: re
|
|
- import: google.appengine.ext.bulkload.transform
|
|
- import: google.appengine.ext.bulkload.bulkloader_wizard
|
|
- import: google.appengine.ext.db
|
|
- import: google.appengine.api.datastore
|
|
- import: google.appengine.api.users
|
|
- import: bulkloader_helpers
|
|
|
|
transformers:
|
|
|
|
# - kind: AppUser
|
|
# connector: csv
|
|
# connector_options:
|
|
# # TODO: Add connector options here--these are specific to each connector.
|
|
# property_map:
|
|
# - property: __key__
|
|
# external_name: key
|
|
# export_transform: transform.key_id_or_name_as_string
|
|
|
|
# - property: created
|
|
# external_name: created
|
|
# # Type: Date/Time Stats: 3 properties of this type in this kind.
|
|
# import_transform: transform.import_date_time('%Y-%m-%dT%H:%M:%S')
|
|
# export_transform: transform.export_date_time('%Y-%m-%dT%H:%M:%S')
|
|
|
|
# - property: email
|
|
# external_name: email
|
|
# # Type: Email Stats: 3 properties of this type in this kind.
|
|
# import_transform: db.Email
|
|
|
|
# - property: updated
|
|
# external_name: updated
|
|
# # Type: Date/Time Stats: 3 properties of this type in this kind.
|
|
# import_transform: transform.import_date_time('%Y-%m-%dT%H:%M:%S')
|
|
# export_transform: transform.export_date_time('%Y-%m-%dT%H:%M:%S')
|
|
|
|
|
|
- kind: Feature
|
|
connector: csv
|
|
connector_options:
|
|
skip_import_header_row: true
|
|
column_list: [category,name,summary,bug_url,owner,impl_status_chrome,shipped_milestone,footprint,visibility,prefixed,standardization,spec_link,safari_views,safari_views_link,ff_views,ff_views_link,ie_views,ie_views_link,web_dev_views,comments]
|
|
post_import_function: bulkloader_helpers.finalize
|
|
property_map:
|
|
# - property: __key__
|
|
# external_name: key
|
|
# export_transform: transform.key_id_or_name_as_string
|
|
|
|
- property: bug_url
|
|
external_name: bug_url
|
|
# Type: Link Stats: 3 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(db.Link)
|
|
#post_import_function: fix_link
|
|
|
|
- property: category
|
|
external_name: category
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: comments
|
|
external_name: comments
|
|
# Type: String Stats: 5 properties of this type in this kind.
|
|
#import_transform: transform.none_if_empty(str)
|
|
|
|
- property: created
|
|
external_name: created
|
|
# Type: Date/Time Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.import_date_time('%Y-%m-%dT%H:%M:%S')
|
|
export_transform: transform.export_date_time('%Y-%m-%dT%H:%M:%S')
|
|
|
|
- property: created_by
|
|
external_name: created_by
|
|
# Type: User Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(users.User) # Assumes email address
|
|
|
|
- property: ff_views
|
|
external_name: ff_views
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: ff_views_link
|
|
external_name: ff_views_link
|
|
# Type: Link Stats: 1 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(db.Link)
|
|
|
|
- property: footprint
|
|
external_name: footprint
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: ie_views
|
|
external_name: ie_views
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: ie_views_link
|
|
external_name: ie_views_link
|
|
# Type: Link Stats: 1 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(db.Link)
|
|
|
|
- property: impl_status_chrome
|
|
external_name: impl_status_chrome
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: name
|
|
external_name: name
|
|
# Type: String Stats: 5 properties of this type in this kind.
|
|
|
|
- property: owner
|
|
external_name: owner
|
|
# Type: Email Stats: 4 properties of this type in this kind.
|
|
#import_transform: transform.none_if_empty(db.Email)
|
|
import_transform: bulkloader_helpers.email_to_list()
|
|
#import_transform: transform.split_string(',')
|
|
|
|
- property: prefixed
|
|
external_name: prefixed
|
|
# Type: Boolean Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.regexp_bool('true', re.IGNORECASE)
|
|
|
|
- property: safari_views
|
|
external_name: safari_views
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: shipped_milestone
|
|
external_name: shipped_milestone
|
|
# Type: String Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: spec_link
|
|
external_name: spec_link
|
|
# Type: Link Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(db.Link)
|
|
|
|
- property: standardization
|
|
external_name: standardization
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: summary
|
|
external_name: summary
|
|
#import_transform: bulkloader_helpers.update_summary()
|
|
|
|
- property: updated
|
|
external_name: updated
|
|
# Type: Date/Time Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.import_date_time('%Y-%m-%dT%H:%M:%S')
|
|
export_transform: transform.export_date_time('%Y-%m-%dT%H:%M:%S')
|
|
|
|
- property: updated_by
|
|
external_name: updated_by
|
|
# Type: User Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(users.User) # Assumes email address
|
|
|
|
- property: visibility
|
|
external_name: visibility
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
- property: web_dev_views
|
|
external_name: web_dev_views
|
|
# Type: Integer Stats: 5 properties of this type in this kind.
|
|
import_transform: transform.none_if_empty(int)
|
|
|
|
|
|
# - kind: _AhAdminXsrfToken_
|
|
# connector: # TODO: Choose a connector here: csv, simplexml, etc...
|
|
# connector_options:
|
|
# # TODO: Add connector options here--these are specific to each connector.
|
|
# property_map:
|
|
# - property: __key__
|
|
# external_name: key
|
|
# export_transform: transform.key_id_or_name_as_string
|
|
|
|
# - property: xsrf_token
|
|
# external_name: xsrf_token
|
|
# # Type: String Stats: 1 properties of this type in this kind.
|
|
|
|
#def email_to_list(input_dict, instance, bulkload_state_copy):
|
|
# return instance
|
|
|