Website page views for pages that don’t exist, is it spam or malicious activity?

I have recently bought my first domain name and set up Google Analytics on it, partially for learning and also out of curiosity.

I have noticed that I get multiple hits a day (even though my site isn’t registered on any search engines) but on pages that don’t exist and also with strange queries attached to them.

For example, some of the strange hits I have had page views for are:

/about?dm_device=mobile /contact?dm_device=mobile /categories/54920394 /store/shoes-38932522 

Even though I don’t have any paths for /contact /categories or /store, or many of the other pages that have been attempted to access, on my site.

I have looked at the hostname for these pageviews and those do not match the correct hostname for accessing the site, so my guess is that maybe some other site is using my GAID?

My biggest concern is that maybe these are malicious attacks of some kind?

The reason for me thinking this is that since I’ve noticed these pages being visited in GA, I have been receiving numerous spam phone calls on my mobile (5 or 6 a day), with recorded voicemail messages left not in English so I have no idea what it’s saying.

I have checked that my whois protection is working and on the surface it seems as though my information is protected, so it may just be coincidence about these spam calls.

If anyone can clarify what may be happening here and possibly put my mind at rest, I’d really appreciate it, and apologies if I haven’t asked this in the correct place!

Thanks

Ansible ec2_vpc_igw VPC does not exist

I’m working on a playbook to deploy a VPC with an internet gateway. For some reason, the Ansible module is unable to find the gateway. The documentation on this module is sparse, and the example is incomplete.

Ansible bits:

- name: Create default VPC   ec2_vpc_net:     name: acme_baseline     cidr_block: 10.11.0.0/16     region: us-east-1     state: present     tags:       Owner: "someuser"   register: baseline_vpc  - name: Create internet gateway   ec2_vpc_igw:     vpc_id: "{{ baseline_vpc.vpc.id }}"     region: us-east-1     state: present     tags:       Name: "acme_baseline"       Owner: "someuser"   register: baseline_igw 

Direct AWS CLI has no issues finding the VPC:

# aws ec2 describe-vpcs --vpc-ids vpc-0123546897 --region us-east-1 {     "Vpcs": [         {             "IsDefault": false,             "Tags": [                 {                     "Value": "acme_baseline",                     "Key": "Name"                 },                 {                     "Value": "someuser",                     "Key": "Owner"                 }             ],             "CidrBlockAssociationSet": [                 {                     "CidrBlock": "10.11.0.0/16",                     "CidrBlockState": {                         "State": "associated"                     },                     "AssociationId": "vpc-cidr-assoc-00001444444"                 }             ],             "VpcId": "vpc-0123546897",             "CidrBlock": "10.11.0.0/16",             "State": "available",             "DhcpOptionsId": "dopt-aaaaaaa",             "OwnerId": "000000000000",             "InstanceTenancy": "default"         }     ] } 

Output of the two Ansible blocks (verbose mode x3):

ansible-playbook 2.7.9   config file = None   configured module search path = [u'/root/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']   ansible python module location = /usr/lib/python2.7/site-packages/ansible   executable location = /usr/bin/ansible-playbook   python version = 2.7.5 (default, Apr 11 2018, 07:36:10) [GCC 4.8.5 20150623 (Red Hat 4.8.5-28)]  TASK [aws-baseline : Create default VPC] *************************************************************************************************************************************** task path: /root/foo/roles/aws-baseline/tasks/main.yml:26 <localhost> ESTABLISH LOCAL CONNECTION FOR USER: root <localhost> EXEC /bin/sh -c 'echo ~root && sleep 0' <localhost> EXEC /bin/sh -c '( umask 77 && mkdir -p "` echo /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz `" && echo ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz="` echo /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz `" ) && sleep 0' Using module file /usr/lib/python2.7/site-packages/ansible/modules/cloud/amazon/ec2_vpc_net.py <localhost> PUT /root/.ansible/tmp/ansible-local-14593RSX_GI/tmpMcth9v TO /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz/AnsiballZ_ec2_vpc_net.py <localhost> EXEC /bin/sh -c 'chmod u+x /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz/ /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz/AnsiballZ_ec2_vpc_net.py && sleep 0' <localhost> EXEC /bin/sh -c '/usr/bin/python /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz/AnsiballZ_ec2_vpc_net.py && sleep 0' <localhost> EXEC /bin/sh -c 'rm -f -r /root/.ansible/tmp/ansible-tmp-zzzzzzzzzzzzzzzzzzzzzz/ > /dev/null 2>&1 && sleep 0' ok: [localhost] => {     "changed": false,     "invocation": {         "module_args": {             "aws_access_key": null,             "aws_secret_key": null,             "cidr_block": [                 "10.11.0.0/16"             ],             "dhcp_opts_id": null,             "dns_hostnames": true,             "dns_support": true,             "ec2_url": null,             "multi_ok": false,             "name": "acme_baseline",             "profile": null,             "purge_cidrs": false,             "region": "us-east-1",             "security_token": null,             "state": "present",             "tags": {                 "Name": "acme_baseline",                 "Owner": "someuser"             },             "tenancy": "default",             "validate_certs": true         }     },     "vpc": {         "cidr_block": "10.11.0.0/16",         "cidr_block_association_set": [             {                 "association_id": "vpc-cidr-assoc-00001444444",                 "cidr_block": "10.11.0.0/16",                 "cidr_block_state": {                     "state": "associated"                 }             }         ],         "classic_link_enabled": false,         "dhcp_options_id": "dopt-aaaaaaa",         "id": "vpc-0123546897",         "instance_tenancy": "default",         "is_default": false,         "owner_id": "000000000000",         "state": "available",         "tags": {             "Name": "acme_baseline",             "Owner": "someuser"         }     } }  TASK [aws-baseline : Create internet gateway] ********************************************************************************************************************************** task path: /root/foo/roles/aws-baseline/tasks/main.yml:37 <localhost> ESTABLISH LOCAL CONNECTION FOR USER: root <localhost> EXEC /bin/sh -c 'echo ~root && sleep 0' <localhost> EXEC /bin/sh -c '( umask 77 && mkdir -p "` echo /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx `" && echo ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx="` echo /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx `" ) && sleep 0' Using module file /usr/lib/python2.7/site-packages/ansible/modules/cloud/amazon/ec2_vpc_igw.py <localhost> PUT /root/.ansible/tmp/ansible-local-14593RSX_GI/tmp1Ttirp TO /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx/AnsiballZ_ec2_vpc_igw.py <localhost> EXEC /bin/sh -c 'chmod u+x /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx/ /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx/AnsiballZ_ec2_vpc_igw.py && sleep 0' <localhost> EXEC /bin/sh -c '/usr/bin/python /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx/AnsiballZ_ec2_vpc_igw.py && sleep 0' <localhost> EXEC /bin/sh -c 'rm -f -r /root/.ansible/tmp/ansible-tmp-xxxxxxxxxxxxxxxxxxxxxxxxxxx/ > /dev/null 2>&1 && sleep 0' The full traceback is: WARNING: The below traceback may *not* be related to the actual failure.   File "/tmp/ansible_ec2_vpc_igw_payload_o6xIsP/__main__.py", line 244, in main     result = ensure_igw_present(connection, vpc_id, tags, check_mode=module.check_mode)   File "/tmp/ansible_ec2_vpc_igw_payload_o6xIsP/__main__.py", line 184, in ensure_igw_present     'Unable to create Internet Gateway, error: {0}'.format(e))  fatal: [localhost]: FAILED! => {     "changed": false,     "invocation": {         "module_args": {             "aws_access_key": null,             "aws_secret_key": null,             "ec2_url": null,             "profile": null,             "region": "us-east-1",             "security_token": null,             "state": "present",             "tags": {                 "Name": "acme_baseline",                 "Owner": "someuser"             },             "validate_certs": true,             "vpc_id": "vpc-0123546897"         }     },     "msg": "Unable to create Internet Gateway, error: EC2ResponseError: 400 Bad Request\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Response><Errors><Error><Code>InvalidVpcID.NotFound</Code><Message>The vpc ID 'vpc-0123546897' does not exist</Message></Error></Errors><RequestID>111111111-22222222-33333</RequestID></Response>" }  

Attempt to create a field that does not exist on entity type node

I’m stuck with a broken site that is reporting Attempt to create a field field_myname_ that does not exist on entity type node

It’s my own fault. I created the new field with an inadvertent typo in the fieldname that resulted in the system name being given a trailing underscore.

My OCD kicked in and I needed to get rid of the underscore. So I did a config export, removed all traces of the offending underscore from the yml files, and then did a config import.

Unfortunately, this has blown up in my face, and I now have a site that crashes hard on pages containing the entity in question, and nothing seems to be able to fix it.

  • I’ve tried re-importing the original structure.
  • I’ve tried re-importing the structure without the new field at all.
  • I’ve tried entup and updb, and of course clearing the caches after everthing I’ve tried.

Short of killing the whole database and rebuilding from scratch, what else can I do? (yes, I have backups, but there is of course work in progress that I’ll lose if I take that path)

Do nontrivial Lawvere metrics exist on the poset of subgroups of Z?

Consider the poset $ S:= \{G\subseteq\mathbb{Z}\}$ of all subgroups of the group of integers.

Question: Does there exist a Lawvere metric $ d\colon S\times S\to[0,\infty]$ with the properties that

  1. whenever $ G\subseteq G’$ , one has $ d(G,G’)=0$ , and
  2. there exists some $ G,G’$ such that $ 0<d(G,G’)<\infty$ ?

Fastest way to find dataframe indexes of column elements that exist as lists

I asked this question here: https://stackoverflow.com/q/55640147/5202255 and was told to post on this forum. I would like to know whether my solution can be improved or if there is another approach to the problem. Any help is really appreciated!

I have a pandas dataframe in which the column values exist as lists. Each list has several elements and one element can exist in several rows. An example dataframe is:

X = pd.DataFrame([(1,['a','b','c']),(2,['a','b']),(3,['c','d'])],columns=['A','B'])  X =   A          B 0  1  [a, b, c] 1  2  [a, b] 2  3     [c, d] 

I want to find all the rows, i.e. dataframe indexes, corresponding to elements in the lists, and create a dictionary out of it. Disregard column A here, as column B is the one of interest! So element ‘a’ occurs in index 0,1, which gives {‘a’:[0,1]}. The solution for this example dataframe is:

Y = {'a':[0,1],'b':[0,1],'c':[0,2],'d':[2]} 

I have written a code that works fine, and I can get a result. My problem is more to do with the speed of computation. My actual dataframe has about 350,000 rows and the lists in the column ‘B’ can contain up to 1,000 elements. But at present the code is running for several hours! I was wondering whether my solution is very inefficient. Any help with a faster more efficient way will be really appreciated! Here is my solution code:

import itertools import pandas as pd X = pd.DataFrame([(1,['a','b','c']),(2,['a','b']),(3,['c','d'])],columns=['A','B']) B_dict = [] for idx,val in X.iterrows():     B = val['B']     B_dict.append(dict(zip(B,[[idx]]*len(B))))     B_dict = [{k: list(itertools.chain.from_iterable(list(filter(None.__ne__, [d.get(k) for d in B_dict])))) for k in set().union(*B_dict)}]  print ('Result:',B_dict[0]) 

Output

Result: {'d': [2], 'c': [0, 2], 'b': [0, 1], 'a': [0, 1]} 

The code for the final line in the for loop was borrowed from here https://stackoverflow.com/questions/45649141/combine-values-of-same-keys-in-a-list-of-dicts, and https://stackoverflow.com/questions/16096754/remove-none-value-from-a-list-without-removing-the-0-value

Editing a content type using Content Type that doesn’t exist in the Content Type Hub

We deployed some Site Collections using templates that weren’t linked with the Content Types on our Content Type Hub, in fact, we have never really used the ct hub. All our Site collections have a specific set of content types that don’t exist on the Content Type Hub.

Now we are faced with the task of having to update the Content Type descriptions. Is there any way of creating these content types on our Content Type Hub and have them update on the Site Collections?

I have already created/published some new content types to see that things are coming through as expected.

With the intention of making a pull request, what conventions exist for branch naming in a forked repo that relate to an issue in the upstream repo

Often when contributing to a project where I have push rights, I have the following workflow of:

  1. Make an issue on Github
  2. Branch from the develop or master branch, depending whichever is appropriate with the following naming convention: issue/<issue-number>/two-word-description-of-issue
  3. Make changes and push with:

git push --set-upstream origin issue/<issue-number>/two-word-description-of-issue

  1. Then open a pull request

I’m curious if a similar convention exists for when one fork’s a project but now makes an issue on the upstream repository.

Would one carry out the same workflow above referencing the issue-number in the upstream repo, or reference an issue in origin?

I have often seen other repos where it seems the convention is simply prefix the branch with one’s username, i.e. <username>/two-word-description but I would have thought it would be good to reference to a specific issue perhaps?